From f1d9a50a3be2bfabc6091d51e120ca63ac1ab2d4 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Fri, 15 Feb 2019 12:42:15 -0500 Subject: Set up #19 --- .../.classpath | 8 + .../.gitignore | 1 + .../.project | 34 + .../.settings/org.eclipse.jdt.core.prefs | 7 + .../META-INF/MANIFEST.MF | 28 + .../build.properties | 7 + .../configurations/ecore.vsconfig | 33 + .../configurations/fam.vsconfig | 25 + .../configurations/fileSystem.vsconfig | 25 + .../configurations/yakindu.vsconfig | 25 + .../instanceModels/ecoreInstance.xmi | 6 + .../instanceModels/famInstance.xmi | 4 + .../instanceModels/filesystemInstance.xmi | 3 + .../instanceModels/yakinduInstance.xmi | 3 + .../metamodels/fam.ecore | 68 + .../metamodels/fam.genmodel | 49 + .../metamodels/filesystem.ecore | 32 + .../metamodels/filesystem.genmodel | 26 + .../metamodels/yakindu.ecore | 26 + .../metamodels/yakindu.genmodel | 34 + .../outputs/fam/debug/errors.txt | 195 + .../fam/debug/generated3valued.vql_deactivated | 31733 +++++++++++++++++++ .../outputs/fam/debug/generation.logicproblem | 2059 ++ .../outputs/fam/debug/init.partialmodel | 497 + .../outputs/fam/log.txt | 1 + .../outputs/fam/models/1.gml | 7641 +++++ .../outputs/fam/models/1.png | Bin 0 -> 141462 bytes .../outputs/fam/models/1.xmi | 9 + .../outputs/fam/models/2.gml | 4762 +++ .../outputs/fam/models/2.png | Bin 0 -> 151601 bytes .../outputs/fam/models/2.xmi | 9 + .../outputs/fam/models/3.gml | 2069 ++ .../outputs/fam/models/3.png | Bin 0 -> 157309 bytes .../outputs/fam/models/3.xmi | 9 + .../outputs/fam/models/4.gml | 1184 + .../outputs/fam/models/4.png | Bin 0 -> 162587 bytes .../outputs/fam/models/4.xmi | 9 + .../outputs/fam/models/5.gml | 1203 + .../outputs/fam/models/5.png | Bin 0 -> 168585 bytes .../outputs/fam/models/5.xmi | 9 + .../outputs/fam/statistics.csv | 32 + .../outputs/yakindu/debug/errors.txt | 21 + .../yakindu/debug/generated3valued.vql_deactivated | 1472 + .../outputs/yakindu/debug/generation.logicproblem | 171 + .../outputs/yakindu/debug/init.partialmodel | 106 + .../outputs/yakindu/log.txt | 1 + .../outputs/yakindu/models/1.gml | 479 + .../outputs/yakindu/models/1.png | Bin 0 -> 30880 bytes .../outputs/yakindu/models/1.xmi | 9 + .../outputs/yakindu/models/2.gml | 479 + .../outputs/yakindu/models/2.png | Bin 0 -> 36094 bytes .../outputs/yakindu/models/2.xmi | 9 + .../outputs/yakindu/statistics.csv | 2 + .../plugin.properties | 4 + .../plugin.xml | 26 + .../standalone/test/ecore/queries/Ecore.vql | 29 + .../standalone/test/fam/FAMTerminator.java | 52 + .../dslreasoner/standalone/test/fam/Function.java | 61 + .../standalone/test/fam/FunctionType.java | 241 + .../test/fam/FunctionalArchitectureModel.java | 42 + .../standalone/test/fam/FunctionalData.java | 81 + .../standalone/test/fam/FunctionalElement.java | 109 + .../standalone/test/fam/FunctionalInput.java | 42 + .../standalone/test/fam/FunctionalInterface.java | 73 + .../standalone/test/fam/FunctionalOutput.java | 42 + .../standalone/test/fam/InformationLink.java | 81 + .../standalone/test/fam/famFactory.java | 96 + .../standalone/test/fam/famPackage.java | 1032 + .../test/fam/impl/FAMTerminatorImpl.java | 196 + .../standalone/test/fam/impl/FunctionImpl.java | 191 + .../fam/impl/FunctionalArchitectureModelImpl.java | 152 + .../test/fam/impl/FunctionalDataImpl.java | 267 + .../test/fam/impl/FunctionalElementImpl.java | 318 + .../test/fam/impl/FunctionalInputImpl.java | 165 + .../test/fam/impl/FunctionalInterfaceImpl.java | 243 + .../test/fam/impl/FunctionalOutputImpl.java | 165 + .../test/fam/impl/InformationLinkImpl.java | 285 + .../standalone/test/fam/impl/famFactoryImpl.java | 219 + .../standalone/test/fam/impl/famPackageImpl.java | 574 + .../standalone/test/fam/queries/famPatterns.vql | 103 + .../test/fam/util/famAdapterFactory.java | 271 + .../standalone/test/fam/util/famSwitch.java | 289 + .../standalone/test/filesystem/Dir.java | 42 + .../standalone/test/filesystem/FSObject.java | 52 + .../standalone/test/filesystem/File.java | 17 + .../standalone/test/filesystem/FileSystem.java | 70 + .../standalone/test/filesystem/Model.java | 69 + .../test/filesystem/filesystemFactory.java | 69 + .../test/filesystem/filesystemPackage.java | 511 + .../standalone/test/filesystem/impl/DirImpl.java | 165 + .../test/filesystem/impl/FSObjectImpl.java | 196 + .../standalone/test/filesystem/impl/FileImpl.java | 37 + .../test/filesystem/impl/FileSystemImpl.java | 205 + .../standalone/test/filesystem/impl/ModelImpl.java | 221 + .../filesystem/impl/filesystemFactoryImpl.java | 128 + .../filesystem/impl/filesystemPackageImpl.java | 356 + .../test/filesystem/queries/FileSystem.vql | 24 + .../filesystem/util/filesystemAdapterFactory.java | 192 + .../test/filesystem/util/filesystemSwitch.java | 196 + .../standalone/test/yakindu/Choice.java | 17 + .../standalone/test/yakindu/CompositeElement.java | 42 + .../dslreasoner/standalone/test/yakindu/Entry.java | 17 + .../dslreasoner/standalone/test/yakindu/Exit.java | 17 + .../standalone/test/yakindu/FinalState.java | 17 + .../standalone/test/yakindu/Pseudostate.java | 17 + .../standalone/test/yakindu/Region.java | 42 + .../standalone/test/yakindu/RegularState.java | 17 + .../dslreasoner/standalone/test/yakindu/State.java | 17 + .../standalone/test/yakindu/Statechart.java | 17 + .../standalone/test/yakindu/Synchronization.java | 17 + .../standalone/test/yakindu/Transition.java | 81 + .../standalone/test/yakindu/Vertex.java | 63 + .../standalone/test/yakindu/impl/ChoiceImpl.java | 37 + .../test/yakindu/impl/CompositeElementImpl.java | 152 + .../standalone/test/yakindu/impl/EntryImpl.java | 37 + .../standalone/test/yakindu/impl/ExitImpl.java | 37 + .../test/yakindu/impl/FinalStateImpl.java | 37 + .../test/yakindu/impl/PseudostateImpl.java | 37 + .../standalone/test/yakindu/impl/RegionImpl.java | 152 + .../test/yakindu/impl/RegularStateImpl.java | 37 + .../standalone/test/yakindu/impl/StateImpl.java | 183 + .../test/yakindu/impl/StatechartImpl.java | 37 + .../test/yakindu/impl/SynchronizationImpl.java | 37 + .../test/yakindu/impl/TransitionImpl.java | 284 + .../standalone/test/yakindu/impl/VertexImpl.java | 206 + .../test/yakindu/impl/yakinduFactoryImpl.java | 183 + .../test/yakindu/impl/yakinduPackageImpl.java | 494 + .../yakindu/queries/yakinduMutatedPatterns.vql | 270 + .../test/yakindu/queries/yakinduPatterns.vql | 227 + .../test/yakindu/util/yakinduAdapterFactory.java | 336 + .../test/yakindu/util/yakinduSwitch.java | 378 + .../standalone/test/yakindu/yakinduFactory.java | 114 + .../standalone/test/yakindu/yakinduPackage.java | 1038 + 133 files changed, 67307 insertions(+) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.settings/org.eclipse.jdt.core.prefs create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/ecoreInstance.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.genmodel create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.genmodel create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.properties create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FAMTerminator.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionType.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalArchitectureModel.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalData.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInput.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInterface.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalOutput.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/InformationLink.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famPackage.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FAMTerminatorImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalArchitectureModelImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalDataImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalElementImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInputImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInterfaceImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalOutputImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/InformationLinkImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famFactoryImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famAdapterFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famSwitch.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Dir.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FSObject.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/File.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Model.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemPackage.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/DirImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FSObjectImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/ModelImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemFactoryImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemAdapterFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemSwitch.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath new file mode 100644 index 00000000..d8bd95f6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore new file mode 100644 index 00000000..ae3c1726 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore @@ -0,0 +1 @@ +/bin/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project new file mode 100644 index 00000000..c2212771 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project @@ -0,0 +1,34 @@ + + + ca.mcgill.ecse.dslreasoner.standalone.test + + + + + + org.eclipse.viatra.query.tooling.ui.projectbuilder + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + org.eclipse.viatra.query.projectnature + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.settings/org.eclipse.jdt.core.prefs b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..295926d9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.8 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF new file mode 100644 index 00000000..ca7ad11c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF @@ -0,0 +1,28 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: %pluginName +Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.standalone.test;singleton:=true +Bundle-Version: 1.0.0.qualifier +Bundle-ClassPath: . +Bundle-Vendor: %providerName +Bundle-Localization: plugin +Export-Package: ca.mcgill.ecse.dslreasoner.standalone.test.fam, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.util, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util +Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, + org.eclipse.core.runtime;bundle-version="3.13.0", + org.eclipse.emf.ecore;bundle-version="2.13.0";visibility:=reexport, + org.eclipse.viatra.query.runtime;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", + org.eclipse.xtext.xbase.lib;bundle-version="2.12.0" +Import-Package: org.apache.log4j +Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.standalone.test +Bundle-ActivationPolicy: lazy +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties new file mode 100644 index 00000000..8ae35ddd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties @@ -0,0 +1,7 @@ +bin.includes = META-INF/,\ + plugin.xml,\ + plugin.properties + +jars.compile.order = . +source.. = src/ +output.. = bin/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig new file mode 100644 index 00000000..e5873211 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig @@ -0,0 +1,33 @@ +import epackage "http://www.eclipse.org/emf/2002/Ecore" + +metamodel allSupported { package ecore excluding { + EClassifier.instanceClass,EClassifier.defaultValue,EEnumLiteral.instance,EStructuralFeature.defaultValue, + EJavaClass, EJavaObject, EJavaObject, + EPackage.eFactoryInstance, EFactory, EFactory.ePackage + } +} + +generate { + metamodel = allSupported + //constraints = { ... } + partial-model = { "platform:/resource/Ecore-Plugin/InitialPackage.ecore" } + solver = ViatraSolver + scope = { + #node += 5, + #string += { "A", "B" }, + #int += {0,1,-1} + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 5 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig new file mode 100644 index 00000000..f4f29089 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig @@ -0,0 +1,25 @@ +import epackage "FamMetamodel" +//import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.queries.fam.FamPatterns" + +generate { + metamodel = { package fam } +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} + solver = ViatraSolver + scope = { + #node = 5 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 2 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig new file mode 100644 index 00000000..64775e8d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig @@ -0,0 +1,25 @@ +import epackage "FileSystemMetamodel" +//import viatra "" + +generate { + metamodel = { package filesystem } +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi"} + solver = ViatraSolver + scope = { + #node = 5 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 2 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig new file mode 100644 index 00000000..246337de --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig @@ -0,0 +1,25 @@ +import epackage "YakinduMetamodel" +//import viatra "" + +generate { + metamodel = { package yakindu } +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi"} + solver = ViatraSolver + scope = { + #node = 5 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 2 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/ecoreInstance.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/ecoreInstance.xmi new file mode 100644 index 00000000..867e5049 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/ecoreInstance.xmi @@ -0,0 +1,6 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi new file mode 100644 index 00000000..1ae86782 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi @@ -0,0 +1,4 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi new file mode 100644 index 00000000..06d5d6d1 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi @@ -0,0 +1,3 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi new file mode 100644 index 00000000..e5f1099f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi @@ -0,0 +1,3 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore new file mode 100644 index 00000000..498e9838 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore @@ -0,0 +1,68 @@ + + + +
+ + + + + +
+ + + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.genmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.genmodel new file mode 100644 index 00000000..3d26d5c4 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.genmodel @@ -0,0 +1,49 @@ + + + fam.ecore + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore new file mode 100644 index 00000000..3dd2061b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore @@ -0,0 +1,32 @@ + + + +
+ + + + + +
+ + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.genmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.genmodel new file mode 100644 index 00000000..712533fe --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.genmodel @@ -0,0 +1,26 @@ + + + filesystem.ecore + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore new file mode 100644 index 00000000..0c944db8 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel new file mode 100644 index 00000000..b1f75d76 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel @@ -0,0 +1,34 @@ + + + yakindu.ecore + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt new file mode 100644 index 00000000..94b0f4e3 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt @@ -0,0 +1,195 @@ +Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.xyz.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.xyz.terminatorAndInformation contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Unsupported attribute type: EJavaClass of org.eclipse.emf.ecore.impl.EcorePackageImpl@eddc9bb (name: ecore) (nsURI: http://www.eclipse.org/emf/2002/Ecore, nsPrefix: ecore)::EClassifier.instanceClass + hu.bme.mit.inf.dslreasoner.ecore2logic.EAttributeMapper_RelationsOverTypes.TypeOfRange(EAttributeMapper_RelationsOverTypes.java:237) + hu.bme.mit.inf.dslreasoner.ecore2logic.EAttributeMapper_RelationsOverTypes.transformEAttributes(EAttributeMapper_RelationsOverTypes.java:70) + hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.transformEAttributes(Ecore2Logic.java:140) + hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.transformMetamodel(Ecore2Logic.java:83) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:189) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated new file mode 100644 index 00000000..88497c64 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated @@ -0,0 +1,31733 @@ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +}import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ + private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ + private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type(problem,interpretation,source,target); + } + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz type +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + find mayEquivalent(problem, interpretation, var_Target, var_virtual0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); + var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); + var_Target == var_virtual0; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_This); + // type constraint is enforced by construction + // This is exported + // Target is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); + var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); + var_Target == var_virtual0; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( + problem:LogicProblem, interpretation:PartialInterpretation, + var_This, var_Target) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // This is exported + // Target is exported + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem new file mode 100644 index 00000000..ab657f0b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem @@ -0,0 +1,2059 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel new file mode 100644 index 00000000..985e7346 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel @@ -0,0 +1,497 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt new file mode 100644 index 00000000..69222b92 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt @@ -0,0 +1 @@ +Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml new file mode 100644 index 00000000..c55209f7 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml @@ -0,0 +1,7641 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png new file mode 100644 index 00000000..c1d6f49f Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi new file mode 100644 index 00000000..d9529633 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml new file mode 100644 index 00000000..f6242732 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml @@ -0,0 +1,4762 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png new file mode 100644 index 00000000..e01ca46b Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi new file mode 100644 index 00000000..c6287127 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml new file mode 100644 index 00000000..05f41ccb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml @@ -0,0 +1,2069 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png new file mode 100644 index 00000000..afaa28c2 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi new file mode 100644 index 00000000..ef8e8e65 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml new file mode 100644 index 00000000..d61b14d0 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml @@ -0,0 +1,1184 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png new file mode 100644 index 00000000..72ccb4b6 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi new file mode 100644 index 00000000..1a10e5b6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml new file mode 100644 index 00000000..f071f63e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml @@ -0,0 +1,1203 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png new file mode 100644 index 00000000..bb835587 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi new file mode 100644 index 00000000..1a10e5b6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv new file mode 100644 index 00000000..0c19baf2 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv @@ -0,0 +1,32 @@ +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;441;2068;2486;3217702419;62;29;140;4;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;463;2860;2654;3199911479;74;37;138;5;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;499;2201;2467;3339884626;68;36;141;4;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;452;2821;2223;3526490298;59;27;122;5;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;11;1529;1717;4396467206;87;94;100;54;17;4;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;15;1411;1457;4222415279;54;68;77;36;10;4;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;9;1335;1288;2769089958;64;74;31;12;1;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;4;1180;1189;2923747093;50;58;26;10;1;0;1 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;839;2519;2455;3266543842;68;33;193;5;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;11;2019;1948;3337962573;91;104;53;16;2;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1719;3345;2829;7904668959;235;261;107;497;53;0;6 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;13;1736;1740;2852471270;62;73;37;19;1;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;529;2502;2857;3681787432;68;30;125;4;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;788;2572;2188;3322713636;67;30;148;5;0;4 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;443;2849;2573;4906642931;151;171;75;124;7;0;8 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;19;4315;9042;20459725100;239;247;252;257;261;217;19;6;0;11 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt new file mode 100644 index 00000000..2086fece --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt @@ -0,0 +1,21 @@ +Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is not translated to logic! + hu.bme.mit.inf.dslreasoner.ecore2logic.EClassMapper_AllElementAsObject.TypeofEClass(EClassMapper_AllElementAsObject.java:63) + hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.TypeofEClass(Ecore2Logic.java:96) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation.transform(InstanceModel2PartialInterpretation.java:99) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic.transform(InstanceModel2Logic.java:19) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:192) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is not translated to logic! + hu.bme.mit.inf.dslreasoner.ecore2logic.EClassMapper_AllElementAsObject.TypeofEClass(EClassMapper_AllElementAsObject.java:63) + hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.TypeofEClass(Ecore2Logic.java:96) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation.transform(InstanceModel2PartialInterpretation.java:99) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic.transform(InstanceModel2Logic.java:19) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:192) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated new file mode 100644 index 00000000..6d8fc404 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated @@ -0,0 +1,1472 @@ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem new file mode 100644 index 00000000..b744bf95 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel new file mode 100644 index 00000000..ead2b44e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel @@ -0,0 +1,106 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt new file mode 100644 index 00000000..4d22da6b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt @@ -0,0 +1 @@ +Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml new file mode 100644 index 00000000..4c5b2e7d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml @@ -0,0 +1,479 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png new file mode 100644 index 00000000..d9b7c988 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi new file mode 100644 index 00000000..f6b5a41e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml new file mode 100644 index 00000000..f07ae0db --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml @@ -0,0 +1,479 @@ +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Synchronization class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png new file mode 100644 index 00000000..38dadff8 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi new file mode 100644 index 00000000..bc0e55cc --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv new file mode 100644 index 00000000..ee8829e5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv @@ -0,0 +1,2 @@ +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;335;2777;2544;7194393100;105;140;61;186;9;0;3 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.properties b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.properties new file mode 100644 index 00000000..58c2dbb6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.properties @@ -0,0 +1,4 @@ +# + +pluginName = FAM Model +providerName = www.example.org diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml new file mode 100644 index 00000000..efdbb9b2 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql new file mode 100644 index 00000000..9af35b50 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql @@ -0,0 +1,29 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries + +import epackage "http://www.eclipse.org/emf/2002/Ecore" + +pattern directSupertype(a: EClass, b:EClass) { + EClass.eSuperTypes(a,b); +} + +@Constraint(key={a}, severity="error", message="error") +pattern loopInInheritence(a: EClass) { + find directSupertype+(a,a); +} + +pattern opposite(a:EReference, b: EReference) { + EReference.eOpposite(a,b); +} +@Constraint(key={a}, severity="error", message="error") +pattern oppositeDifferentClass(a:EReference) { + EReference.eOpposite(a,b); + EReference.eContainingClass(a,aContaining); + EReference.eType(b,bTarget); + aContaining != bTarget; +} + +@Constraint(key={a}, severity="error", message="error") +pattern nonSymmetricOpposite(a:EReference, b:EReference) { + find opposite(a,b); + neg find opposite(b,a); +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FAMTerminator.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FAMTerminator.java new file mode 100644 index 00000000..686af44b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FAMTerminator.java @@ -0,0 +1,52 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'FAM Terminator'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData Data}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFAMTerminator() + * @model + * @generated + */ +public interface FAMTerminator extends EObject { + /** + * Returns the value of the 'Data' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator Terminator}'. + * + *

+ * If the meaning of the 'Data' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Data' container reference. + * @see #setData(FunctionalData) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFAMTerminator_Data() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator + * @model opposite="terminator" transient="false" + * @generated + */ + FunctionalData getData(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData Data}' container reference. + * + * + * @param value the new value of the 'Data' container reference. + * @see #getData() + * @generated + */ + void setData(FunctionalData value); + +} // FAMTerminator diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java new file mode 100644 index 00000000..1fed3a2d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java @@ -0,0 +1,61 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.common.util.EList; + +/** + * + * A representation of the model object 'Function'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getSubElements Sub Elements}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getType Type}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunction() + * @model + * @generated + */ +public interface Function extends FunctionalElement { + /** + * Returns the value of the 'Sub Elements' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent Parent}'. + * + *

+ * If the meaning of the 'Sub Elements' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Sub Elements' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunction_SubElements() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent + * @model opposite="parent" containment="true" + * @generated + */ + EList getSubElements(); + + /** + * Returns the value of the 'Type' attribute. + * The literals are from the enumeration {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType}. + * + *

+ * If the meaning of the 'Type' attribute isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Type' attribute. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunction_Type() + * @model required="true" transient="true" changeable="false" volatile="true" derived="true" + * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.xyz.type'" + * @generated + */ + FunctionType getType(); + +} // Function diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionType.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionType.java new file mode 100644 index 00000000..71e3062d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionType.java @@ -0,0 +1,241 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import java.util.Arrays; +import java.util.Collections; +import java.util.List; + +import org.eclipse.emf.common.util.Enumerator; + +/** + * + * A representation of the literals of the enumeration 'Function Type', + * and utility methods for working with them. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionType() + * @model + * @generated + */ +public enum FunctionType implements Enumerator { + /** + * The 'Root' literal object. + * + * + * @see #ROOT_VALUE + * @generated + * @ordered + */ + ROOT(0, "Root", "Root"), + + /** + * The 'Intermediate' literal object. + * + * + * @see #INTERMEDIATE_VALUE + * @generated + * @ordered + */ + INTERMEDIATE(1, "Intermediate", "Intermediate"), + + /** + * The 'Leaf' literal object. + * + * + * @see #LEAF_VALUE + * @generated + * @ordered + */ + LEAF(2, "Leaf", "Leaf"); + + /** + * The 'Root' literal value. + * + *

+ * If the meaning of 'Root' literal object isn't clear, + * there really should be more of a description here... + *

+ * + * @see #ROOT + * @model name="Root" + * @generated + * @ordered + */ + public static final int ROOT_VALUE = 0; + + /** + * The 'Intermediate' literal value. + * + *

+ * If the meaning of 'Intermediate' literal object isn't clear, + * there really should be more of a description here... + *

+ * + * @see #INTERMEDIATE + * @model name="Intermediate" + * @generated + * @ordered + */ + public static final int INTERMEDIATE_VALUE = 1; + + /** + * The 'Leaf' literal value. + * + *

+ * If the meaning of 'Leaf' literal object isn't clear, + * there really should be more of a description here... + *

+ * + * @see #LEAF + * @model name="Leaf" + * @generated + * @ordered + */ + public static final int LEAF_VALUE = 2; + + /** + * An array of all the 'Function Type' enumerators. + * + * + * @generated + */ + private static final FunctionType[] VALUES_ARRAY = + new FunctionType[] { + ROOT, + INTERMEDIATE, + LEAF, + }; + + /** + * A public read-only list of all the 'Function Type' enumerators. + * + * + * @generated + */ + public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); + + /** + * Returns the 'Function Type' literal with the specified literal value. + * + * + * @param literal the literal. + * @return the matching enumerator or null. + * @generated + */ + public static FunctionType get(String literal) { + for (int i = 0; i < VALUES_ARRAY.length; ++i) { + FunctionType result = VALUES_ARRAY[i]; + if (result.toString().equals(literal)) { + return result; + } + } + return null; + } + + /** + * Returns the 'Function Type' literal with the specified name. + * + * + * @param name the name. + * @return the matching enumerator or null. + * @generated + */ + public static FunctionType getByName(String name) { + for (int i = 0; i < VALUES_ARRAY.length; ++i) { + FunctionType result = VALUES_ARRAY[i]; + if (result.getName().equals(name)) { + return result; + } + } + return null; + } + + /** + * Returns the 'Function Type' literal with the specified integer value. + * + * + * @param value the integer value. + * @return the matching enumerator or null. + * @generated + */ + public static FunctionType get(int value) { + switch (value) { + case ROOT_VALUE: return ROOT; + case INTERMEDIATE_VALUE: return INTERMEDIATE; + case LEAF_VALUE: return LEAF; + } + return null; + } + + /** + * + * + * @generated + */ + private final int value; + + /** + * + * + * @generated + */ + private final String name; + + /** + * + * + * @generated + */ + private final String literal; + + /** + * Only this class can construct instances. + * + * + * @generated + */ + private FunctionType(int value, String name, String literal) { + this.value = value; + this.name = name; + this.literal = literal; + } + + /** + * + * + * @generated + */ + public int getValue() { + return value; + } + + /** + * + * + * @generated + */ + public String getName() { + return name; + } + + /** + * + * + * @generated + */ + public String getLiteral() { + return literal; + } + + /** + * Returns the literal value of the enumerator, which is its string representation. + * + * + * @generated + */ + @Override + public String toString() { + return literal; + } + +} //FunctionType diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalArchitectureModel.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalArchitectureModel.java new file mode 100644 index 00000000..d1717a9f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalArchitectureModel.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Functional Architecture Model'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel#getRootElements Root Elements}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalArchitectureModel() + * @model + * @generated + */ +public interface FunctionalArchitectureModel extends EObject { + /** + * Returns the value of the 'Root Elements' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement}. + * + *

+ * If the meaning of the 'Root Elements' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Root Elements' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalArchitectureModel_RootElements() + * @model containment="true" + * @generated + */ + EList getRootElements(); + +} // FunctionalArchitectureModel diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalData.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalData.java new file mode 100644 index 00000000..675318a8 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalData.java @@ -0,0 +1,81 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Functional Data'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator Terminator}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface Interface}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalData() + * @model abstract="true" + * @generated + */ +public interface FunctionalData extends EObject { + /** + * Returns the value of the 'Terminator' containment reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData Data}'. + * + *

+ * If the meaning of the 'Terminator' containment reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Terminator' containment reference. + * @see #setTerminator(FAMTerminator) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalData_Terminator() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData + * @model opposite="data" containment="true" + * @generated + */ + FAMTerminator getTerminator(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator Terminator}' containment reference. + * + * + * @param value the new value of the 'Terminator' containment reference. + * @see #getTerminator() + * @generated + */ + void setTerminator(FAMTerminator value); + + /** + * Returns the value of the 'Interface' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getData Data}'. + * + *

+ * If the meaning of the 'Interface' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Interface' container reference. + * @see #setInterface(FunctionalInterface) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalData_Interface() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getData + * @model opposite="data" transient="false" + * @generated + */ + FunctionalInterface getInterface(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface Interface}' container reference. + * + * + * @param value the new value of the 'Interface' container reference. + * @see #getInterface() + * @generated + */ + void setInterface(FunctionalInterface value); + +} // FunctionalData diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java new file mode 100644 index 00000000..c3ed76d6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java @@ -0,0 +1,109 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Functional Element'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface Interface}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getModel Model}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent Parent}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalElement() + * @model abstract="true" + * @generated + */ +public interface FunctionalElement extends EObject { + /** + * Returns the value of the 'Interface' containment reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement Element}'. + * + *

+ * If the meaning of the 'Interface' containment reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Interface' containment reference. + * @see #setInterface(FunctionalInterface) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalElement_Interface() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement + * @model opposite="element" containment="true" + * @generated + */ + FunctionalInterface getInterface(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface Interface}' containment reference. + * + * + * @param value the new value of the 'Interface' containment reference. + * @see #getInterface() + * @generated + */ + void setInterface(FunctionalInterface value); + + /** + * Returns the value of the 'Model' reference. + * + *

+ * If the meaning of the 'Model' reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Model' reference. + * @see #setModel(FunctionalArchitectureModel) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalElement_Model() + * @model required="true" transient="true" volatile="true" derived="true" + * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.xyz.model'" + * @generated + */ + FunctionalArchitectureModel getModel(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getModel Model}' reference. + * + * + * @param value the new value of the 'Model' reference. + * @see #getModel() + * @generated + */ + void setModel(FunctionalArchitectureModel value); + + /** + * Returns the value of the 'Parent' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getSubElements Sub Elements}'. + * + *

+ * If the meaning of the 'Parent' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Parent' container reference. + * @see #setParent(Function) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalElement_Parent() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getSubElements + * @model opposite="subElements" transient="false" + * @generated + */ + Function getParent(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent Parent}' container reference. + * + * + * @param value the new value of the 'Parent' container reference. + * @see #getParent() + * @generated + */ + void setParent(Function value); + +} // FunctionalElement diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInput.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInput.java new file mode 100644 index 00000000..de629b29 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInput.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.common.util.EList; + +/** + * + * A representation of the model object 'Functional Input'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput#getIncomingLinks Incoming Links}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalInput() + * @model + * @generated + */ +public interface FunctionalInput extends FunctionalData { + /** + * Returns the value of the 'Incoming Links' reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo To}'. + * + *

+ * If the meaning of the 'Incoming Links' reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Incoming Links' reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalInput_IncomingLinks() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo + * @model opposite="to" + * @generated + */ + EList getIncomingLinks(); + +} // FunctionalInput diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInterface.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInterface.java new file mode 100644 index 00000000..732f3cc6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalInterface.java @@ -0,0 +1,73 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Functional Interface'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getData Data}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement Element}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalInterface() + * @model + * @generated + */ +public interface FunctionalInterface extends EObject { + /** + * Returns the value of the 'Data' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface Interface}'. + * + *

+ * If the meaning of the 'Data' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Data' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalInterface_Data() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface + * @model opposite="interface" containment="true" + * @generated + */ + EList getData(); + + /** + * Returns the value of the 'Element' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface Interface}'. + * + *

+ * If the meaning of the 'Element' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Element' container reference. + * @see #setElement(FunctionalElement) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalInterface_Element() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface + * @model opposite="interface" transient="false" + * @generated + */ + FunctionalElement getElement(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement Element}' container reference. + * + * + * @param value the new value of the 'Element' container reference. + * @see #getElement() + * @generated + */ + void setElement(FunctionalElement value); + +} // FunctionalInterface diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalOutput.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalOutput.java new file mode 100644 index 00000000..51194777 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalOutput.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.common.util.EList; + +/** + * + * A representation of the model object 'Functional Output'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput#getOutgoingLinks Outgoing Links}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalOutput() + * @model + * @generated + */ +public interface FunctionalOutput extends FunctionalData { + /** + * Returns the value of the 'Outgoing Links' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom From}'. + * + *

+ * If the meaning of the 'Outgoing Links' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Outgoing Links' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalOutput_OutgoingLinks() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom + * @model opposite="from" containment="true" + * @generated + */ + EList getOutgoingLinks(); + +} // FunctionalOutput diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/InformationLink.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/InformationLink.java new file mode 100644 index 00000000..26946d01 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/InformationLink.java @@ -0,0 +1,81 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Information Link'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom From}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo To}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getInformationLink() + * @model + * @generated + */ +public interface InformationLink extends EObject { + /** + * Returns the value of the 'From' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput#getOutgoingLinks Outgoing Links}'. + * + *

+ * If the meaning of the 'From' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'From' container reference. + * @see #setFrom(FunctionalOutput) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getInformationLink_From() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput#getOutgoingLinks + * @model opposite="outgoingLinks" transient="false" + * @generated + */ + FunctionalOutput getFrom(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom From}' container reference. + * + * + * @param value the new value of the 'From' container reference. + * @see #getFrom() + * @generated + */ + void setFrom(FunctionalOutput value); + + /** + * Returns the value of the 'To' reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput#getIncomingLinks Incoming Links}'. + * + *

+ * If the meaning of the 'To' reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'To' reference. + * @see #setTo(FunctionalInput) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getInformationLink_To() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput#getIncomingLinks + * @model opposite="IncomingLinks" required="true" + * @generated + */ + FunctionalInput getTo(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo To}' reference. + * + * + * @param value the new value of the 'To' reference. + * @see #getTo() + * @generated + */ + void setTo(FunctionalInput value); + +} // InformationLink diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famFactory.java new file mode 100644 index 00000000..cdab0041 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famFactory.java @@ -0,0 +1,96 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EFactory; + +/** + * + * The Factory for the model. + * It provides a create method for each non-abstract class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage + * @generated + */ +public interface famFactory extends EFactory { + /** + * The singleton instance of the factory. + * + * + * @generated + */ + famFactory eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.init(); + + /** + * Returns a new object of class 'Functional Architecture Model'. + * + * + * @return a new object of class 'Functional Architecture Model'. + * @generated + */ + FunctionalArchitectureModel createFunctionalArchitectureModel(); + + /** + * Returns a new object of class 'Function'. + * + * + * @return a new object of class 'Function'. + * @generated + */ + Function createFunction(); + + /** + * Returns a new object of class 'FAM Terminator'. + * + * + * @return a new object of class 'FAM Terminator'. + * @generated + */ + FAMTerminator createFAMTerminator(); + + /** + * Returns a new object of class 'Information Link'. + * + * + * @return a new object of class 'Information Link'. + * @generated + */ + InformationLink createInformationLink(); + + /** + * Returns a new object of class 'Functional Interface'. + * + * + * @return a new object of class 'Functional Interface'. + * @generated + */ + FunctionalInterface createFunctionalInterface(); + + /** + * Returns a new object of class 'Functional Input'. + * + * + * @return a new object of class 'Functional Input'. + * @generated + */ + FunctionalInput createFunctionalInput(); + + /** + * Returns a new object of class 'Functional Output'. + * + * + * @return a new object of class 'Functional Output'. + * @generated + */ + FunctionalOutput createFunctionalOutput(); + + /** + * Returns the package supported by this factory. + * + * + * @return the package supported by this factory. + * @generated + */ + famPackage getfamPackage(); + +} //famFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famPackage.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famPackage.java new file mode 100644 index 00000000..9b876f8b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/famPackage.java @@ -0,0 +1,1032 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EEnum; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * + * The Package for the model. + * It contains accessors for the meta objects to represent + *
    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famFactory + * @model kind="package" + * annotation="http://www.eclipse.org/emf/2002/Ecore settingDelegates='org.eclipse.viatra.query.querybasedfeature'" + * @generated + */ +public interface famPackage extends EPackage { + /** + * The package name. + * + * + * @generated + */ + String eNAME = "fam"; + + /** + * The package namespace URI. + * + * + * @generated + */ + String eNS_URI = "FamMetamodel"; + + /** + * The package namespace name. + * + * + * @generated + */ + String eNS_PREFIX = "fam"; + + /** + * The singleton instance of the package. + * + * + * @generated + */ + famPackage eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl.init(); + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl Functional Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalElement() + * @generated + */ + int FUNCTIONAL_ELEMENT = 0; + + /** + * The feature id for the 'Interface' containment reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ELEMENT__INTERFACE = 0; + + /** + * The feature id for the 'Model' reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ELEMENT__MODEL = 1; + + /** + * The feature id for the 'Parent' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ELEMENT__PARENT = 2; + + /** + * The number of structural features of the 'Functional Element' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ELEMENT_FEATURE_COUNT = 3; + + /** + * The number of operations of the 'Functional Element' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalArchitectureModelImpl Functional Architecture Model}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalArchitectureModelImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalArchitectureModel() + * @generated + */ + int FUNCTIONAL_ARCHITECTURE_MODEL = 1; + + /** + * The feature id for the 'Root Elements' containment reference list. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS = 0; + + /** + * The number of structural features of the 'Functional Architecture Model' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ARCHITECTURE_MODEL_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'Functional Architecture Model' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_ARCHITECTURE_MODEL_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl Function}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunction() + * @generated + */ + int FUNCTION = 2; + + /** + * The feature id for the 'Interface' containment reference. + * + * + * @generated + * @ordered + */ + int FUNCTION__INTERFACE = FUNCTIONAL_ELEMENT__INTERFACE; + + /** + * The feature id for the 'Model' reference. + * + * + * @generated + * @ordered + */ + int FUNCTION__MODEL = FUNCTIONAL_ELEMENT__MODEL; + + /** + * The feature id for the 'Parent' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTION__PARENT = FUNCTIONAL_ELEMENT__PARENT; + + /** + * The feature id for the 'Sub Elements' containment reference list. + * + * + * @generated + * @ordered + */ + int FUNCTION__SUB_ELEMENTS = FUNCTIONAL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the 'Type' attribute. + * + * + * @generated + * @ordered + */ + int FUNCTION__TYPE = FUNCTIONAL_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of structural features of the 'Function' class. + * + * + * @generated + * @ordered + */ + int FUNCTION_FEATURE_COUNT = FUNCTIONAL_ELEMENT_FEATURE_COUNT + 2; + + /** + * The number of operations of the 'Function' class. + * + * + * @generated + * @ordered + */ + int FUNCTION_OPERATION_COUNT = FUNCTIONAL_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FAMTerminatorImpl FAM Terminator}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FAMTerminatorImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFAMTerminator() + * @generated + */ + int FAM_TERMINATOR = 3; + + /** + * The feature id for the 'Data' container reference. + * + * + * @generated + * @ordered + */ + int FAM_TERMINATOR__DATA = 0; + + /** + * The number of structural features of the 'FAM Terminator' class. + * + * + * @generated + * @ordered + */ + int FAM_TERMINATOR_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'FAM Terminator' class. + * + * + * @generated + * @ordered + */ + int FAM_TERMINATOR_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl Information Link}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getInformationLink() + * @generated + */ + int INFORMATION_LINK = 4; + + /** + * The feature id for the 'From' container reference. + * + * + * @generated + * @ordered + */ + int INFORMATION_LINK__FROM = 0; + + /** + * The feature id for the 'To' reference. + * + * + * @generated + * @ordered + */ + int INFORMATION_LINK__TO = 1; + + /** + * The number of structural features of the 'Information Link' class. + * + * + * @generated + * @ordered + */ + int INFORMATION_LINK_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Information Link' class. + * + * + * @generated + * @ordered + */ + int INFORMATION_LINK_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl Functional Interface}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalInterface() + * @generated + */ + int FUNCTIONAL_INTERFACE = 5; + + /** + * The feature id for the 'Data' containment reference list. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INTERFACE__DATA = 0; + + /** + * The feature id for the 'Element' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INTERFACE__ELEMENT = 1; + + /** + * The number of structural features of the 'Functional Interface' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INTERFACE_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Functional Interface' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INTERFACE_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl Functional Data}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalData() + * @generated + */ + int FUNCTIONAL_DATA = 8; + + /** + * The feature id for the 'Terminator' containment reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_DATA__TERMINATOR = 0; + + /** + * The feature id for the 'Interface' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_DATA__INTERFACE = 1; + + /** + * The number of structural features of the 'Functional Data' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_DATA_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Functional Data' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_DATA_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInputImpl Functional Input}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInputImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalInput() + * @generated + */ + int FUNCTIONAL_INPUT = 6; + + /** + * The feature id for the 'Terminator' containment reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT__TERMINATOR = FUNCTIONAL_DATA__TERMINATOR; + + /** + * The feature id for the 'Interface' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT__INTERFACE = FUNCTIONAL_DATA__INTERFACE; + + /** + * The feature id for the 'Incoming Links' reference list. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT__INCOMING_LINKS = FUNCTIONAL_DATA_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'Functional Input' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT_FEATURE_COUNT = FUNCTIONAL_DATA_FEATURE_COUNT + 1; + + /** + * The number of operations of the 'Functional Input' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT_OPERATION_COUNT = FUNCTIONAL_DATA_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalOutputImpl Functional Output}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalOutputImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalOutput() + * @generated + */ + int FUNCTIONAL_OUTPUT = 7; + + /** + * The feature id for the 'Terminator' containment reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT__TERMINATOR = FUNCTIONAL_DATA__TERMINATOR; + + /** + * The feature id for the 'Interface' container reference. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT__INTERFACE = FUNCTIONAL_DATA__INTERFACE; + + /** + * The feature id for the 'Outgoing Links' containment reference list. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT__OUTGOING_LINKS = FUNCTIONAL_DATA_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'Functional Output' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT_FEATURE_COUNT = FUNCTIONAL_DATA_FEATURE_COUNT + 1; + + /** + * The number of operations of the 'Functional Output' class. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT_OPERATION_COUNT = FUNCTIONAL_DATA_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType Function Type}' enum. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionType() + * @generated + */ + int FUNCTION_TYPE = 9; + + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement Functional Element}'. + * + * + * @return the meta object for class 'Functional Element'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement + * @generated + */ + EClass getFunctionalElement(); + + /** + * Returns the meta object for the containment reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface Interface}'. + * + * + * @return the meta object for the containment reference 'Interface'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getInterface() + * @see #getFunctionalElement() + * @generated + */ + EReference getFunctionalElement_Interface(); + + /** + * Returns the meta object for the reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getModel Model}'. + * + * + * @return the meta object for the reference 'Model'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getModel() + * @see #getFunctionalElement() + * @generated + */ + EReference getFunctionalElement_Model(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent Parent}'. + * + * + * @return the meta object for the container reference 'Parent'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement#getParent() + * @see #getFunctionalElement() + * @generated + */ + EReference getFunctionalElement_Parent(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel Functional Architecture Model}'. + * + * + * @return the meta object for class 'Functional Architecture Model'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel + * @generated + */ + EClass getFunctionalArchitectureModel(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel#getRootElements Root Elements}'. + * + * + * @return the meta object for the containment reference list 'Root Elements'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel#getRootElements() + * @see #getFunctionalArchitectureModel() + * @generated + */ + EReference getFunctionalArchitectureModel_RootElements(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function Function}'. + * + * + * @return the meta object for class 'Function'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function + * @generated + */ + EClass getFunction(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getSubElements Sub Elements}'. + * + * + * @return the meta object for the containment reference list 'Sub Elements'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getSubElements() + * @see #getFunction() + * @generated + */ + EReference getFunction_SubElements(); + + /** + * Returns the meta object for the attribute '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getType Type}'. + * + * + * @return the meta object for the attribute 'Type'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function#getType() + * @see #getFunction() + * @generated + */ + EAttribute getFunction_Type(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator FAM Terminator}'. + * + * + * @return the meta object for class 'FAM Terminator'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator + * @generated + */ + EClass getFAMTerminator(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData Data}'. + * + * + * @return the meta object for the container reference 'Data'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator#getData() + * @see #getFAMTerminator() + * @generated + */ + EReference getFAMTerminator_Data(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink Information Link}'. + * + * + * @return the meta object for class 'Information Link'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink + * @generated + */ + EClass getInformationLink(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom From}'. + * + * + * @return the meta object for the container reference 'From'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getFrom() + * @see #getInformationLink() + * @generated + */ + EReference getInformationLink_From(); + + /** + * Returns the meta object for the reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo To}'. + * + * + * @return the meta object for the reference 'To'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink#getTo() + * @see #getInformationLink() + * @generated + */ + EReference getInformationLink_To(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface Functional Interface}'. + * + * + * @return the meta object for class 'Functional Interface'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface + * @generated + */ + EClass getFunctionalInterface(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getData Data}'. + * + * + * @return the meta object for the containment reference list 'Data'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getData() + * @see #getFunctionalInterface() + * @generated + */ + EReference getFunctionalInterface_Data(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement Element}'. + * + * + * @return the meta object for the container reference 'Element'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface#getElement() + * @see #getFunctionalInterface() + * @generated + */ + EReference getFunctionalInterface_Element(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput Functional Input}'. + * + * + * @return the meta object for class 'Functional Input'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput + * @generated + */ + EClass getFunctionalInput(); + + /** + * Returns the meta object for the reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput#getIncomingLinks Incoming Links}'. + * + * + * @return the meta object for the reference list 'Incoming Links'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput#getIncomingLinks() + * @see #getFunctionalInput() + * @generated + */ + EReference getFunctionalInput_IncomingLinks(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput Functional Output}'. + * + * + * @return the meta object for class 'Functional Output'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput + * @generated + */ + EClass getFunctionalOutput(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput#getOutgoingLinks Outgoing Links}'. + * + * + * @return the meta object for the containment reference list 'Outgoing Links'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput#getOutgoingLinks() + * @see #getFunctionalOutput() + * @generated + */ + EReference getFunctionalOutput_OutgoingLinks(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData Functional Data}'. + * + * + * @return the meta object for class 'Functional Data'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData + * @generated + */ + EClass getFunctionalData(); + + /** + * Returns the meta object for the containment reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator Terminator}'. + * + * + * @return the meta object for the containment reference 'Terminator'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getTerminator() + * @see #getFunctionalData() + * @generated + */ + EReference getFunctionalData_Terminator(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface Interface}'. + * + * + * @return the meta object for the container reference 'Interface'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData#getInterface() + * @see #getFunctionalData() + * @generated + */ + EReference getFunctionalData_Interface(); + + /** + * Returns the meta object for enum '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType Function Type}'. + * + * + * @return the meta object for enum 'Function Type'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + * @generated + */ + EEnum getFunctionType(); + + /** + * Returns the factory that creates the instances of the model. + * + * + * @return the factory that creates the instances of the model. + * @generated + */ + famFactory getfamFactory(); + + /** + * + * Defines literals for the meta objects that represent + *
    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl Functional Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalElement() + * @generated + */ + EClass FUNCTIONAL_ELEMENT = eINSTANCE.getFunctionalElement(); + + /** + * The meta object literal for the 'Interface' containment reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_ELEMENT__INTERFACE = eINSTANCE.getFunctionalElement_Interface(); + + /** + * The meta object literal for the 'Model' reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_ELEMENT__MODEL = eINSTANCE.getFunctionalElement_Model(); + + /** + * The meta object literal for the 'Parent' container reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_ELEMENT__PARENT = eINSTANCE.getFunctionalElement_Parent(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalArchitectureModelImpl Functional Architecture Model}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalArchitectureModelImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalArchitectureModel() + * @generated + */ + EClass FUNCTIONAL_ARCHITECTURE_MODEL = eINSTANCE.getFunctionalArchitectureModel(); + + /** + * The meta object literal for the 'Root Elements' containment reference list feature. + * + * + * @generated + */ + EReference FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS = eINSTANCE.getFunctionalArchitectureModel_RootElements(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl Function}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunction() + * @generated + */ + EClass FUNCTION = eINSTANCE.getFunction(); + + /** + * The meta object literal for the 'Sub Elements' containment reference list feature. + * + * + * @generated + */ + EReference FUNCTION__SUB_ELEMENTS = eINSTANCE.getFunction_SubElements(); + + /** + * The meta object literal for the 'Type' attribute feature. + * + * + * @generated + */ + EAttribute FUNCTION__TYPE = eINSTANCE.getFunction_Type(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FAMTerminatorImpl FAM Terminator}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FAMTerminatorImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFAMTerminator() + * @generated + */ + EClass FAM_TERMINATOR = eINSTANCE.getFAMTerminator(); + + /** + * The meta object literal for the 'Data' container reference feature. + * + * + * @generated + */ + EReference FAM_TERMINATOR__DATA = eINSTANCE.getFAMTerminator_Data(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl Information Link}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getInformationLink() + * @generated + */ + EClass INFORMATION_LINK = eINSTANCE.getInformationLink(); + + /** + * The meta object literal for the 'From' container reference feature. + * + * + * @generated + */ + EReference INFORMATION_LINK__FROM = eINSTANCE.getInformationLink_From(); + + /** + * The meta object literal for the 'To' reference feature. + * + * + * @generated + */ + EReference INFORMATION_LINK__TO = eINSTANCE.getInformationLink_To(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl Functional Interface}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalInterface() + * @generated + */ + EClass FUNCTIONAL_INTERFACE = eINSTANCE.getFunctionalInterface(); + + /** + * The meta object literal for the 'Data' containment reference list feature. + * + * + * @generated + */ + EReference FUNCTIONAL_INTERFACE__DATA = eINSTANCE.getFunctionalInterface_Data(); + + /** + * The meta object literal for the 'Element' container reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_INTERFACE__ELEMENT = eINSTANCE.getFunctionalInterface_Element(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInputImpl Functional Input}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInputImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalInput() + * @generated + */ + EClass FUNCTIONAL_INPUT = eINSTANCE.getFunctionalInput(); + + /** + * The meta object literal for the 'Incoming Links' reference list feature. + * + * + * @generated + */ + EReference FUNCTIONAL_INPUT__INCOMING_LINKS = eINSTANCE.getFunctionalInput_IncomingLinks(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalOutputImpl Functional Output}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalOutputImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalOutput() + * @generated + */ + EClass FUNCTIONAL_OUTPUT = eINSTANCE.getFunctionalOutput(); + + /** + * The meta object literal for the 'Outgoing Links' containment reference list feature. + * + * + * @generated + */ + EReference FUNCTIONAL_OUTPUT__OUTGOING_LINKS = eINSTANCE.getFunctionalOutput_OutgoingLinks(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl Functional Data}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionalData() + * @generated + */ + EClass FUNCTIONAL_DATA = eINSTANCE.getFunctionalData(); + + /** + * The meta object literal for the 'Terminator' containment reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_DATA__TERMINATOR = eINSTANCE.getFunctionalData_Terminator(); + + /** + * The meta object literal for the 'Interface' container reference feature. + * + * + * @generated + */ + EReference FUNCTIONAL_DATA__INTERFACE = eINSTANCE.getFunctionalData_Interface(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType Function Type}' enum. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famPackageImpl#getFunctionType() + * @generated + */ + EEnum FUNCTION_TYPE = eINSTANCE.getFunctionType(); + + } + +} //famPackage diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FAMTerminatorImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FAMTerminatorImpl.java new file mode 100644 index 00000000..6eba60f6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FAMTerminatorImpl.java @@ -0,0 +1,196 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'FAM Terminator'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FAMTerminatorImpl#getData Data}
  • + *
+ * + * @generated + */ +public class FAMTerminatorImpl extends MinimalEObjectImpl.Container implements FAMTerminator { + /** + * + * + * @generated + */ + protected FAMTerminatorImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FAM_TERMINATOR; + } + + /** + * + * + * @generated + */ + public FunctionalData getData() { + if (eContainerFeatureID() != famPackage.FAM_TERMINATOR__DATA) return null; + return (FunctionalData)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetData(FunctionalData newData, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newData, famPackage.FAM_TERMINATOR__DATA, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setData(FunctionalData newData) { + if (newData != eInternalContainer() || (eContainerFeatureID() != famPackage.FAM_TERMINATOR__DATA && newData != null)) { + if (EcoreUtil.isAncestor(this, newData)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newData != null) + msgs = ((InternalEObject)newData).eInverseAdd(this, famPackage.FUNCTIONAL_DATA__TERMINATOR, FunctionalData.class, msgs); + msgs = basicSetData(newData, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FAM_TERMINATOR__DATA, newData, newData)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetData((FunctionalData)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + return basicSetData(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case famPackage.FAM_TERMINATOR__DATA: + return eInternalContainer().eInverseRemove(this, famPackage.FUNCTIONAL_DATA__TERMINATOR, FunctionalData.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + return getData(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + setData((FunctionalData)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + setData((FunctionalData)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FAM_TERMINATOR__DATA: + return getData() != null; + } + return super.eIsSet(featureID); + } + +} //FAMTerminatorImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionImpl.java new file mode 100644 index 00000000..ec3e884e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionImpl.java @@ -0,0 +1,191 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Function'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl#getSubElements Sub Elements}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl#getType Type}
  • + *
+ * + * @generated + */ +public class FunctionImpl extends FunctionalElementImpl implements Function { + /** + * The cached value of the '{@link #getSubElements() Sub Elements}' containment reference list. + * + * + * @see #getSubElements() + * @generated + * @ordered + */ + protected EList subElements; + + /** + * The cached setting delegate for the '{@link #getType() Type}' attribute. + * + * + * @see #getType() + * @generated + * @ordered + */ + protected EStructuralFeature.Internal.SettingDelegate TYPE__ESETTING_DELEGATE = ((EStructuralFeature.Internal)famPackage.Literals.FUNCTION__TYPE).getSettingDelegate(); + + /** + * + * + * @generated + */ + protected FunctionImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTION; + } + + /** + * + * + * @generated + */ + public EList getSubElements() { + if (subElements == null) { + subElements = new EObjectContainmentWithInverseEList(FunctionalElement.class, this, famPackage.FUNCTION__SUB_ELEMENTS, famPackage.FUNCTIONAL_ELEMENT__PARENT); + } + return subElements; + } + + /** + * + * + * @generated + */ + public FunctionType getType() { + return (FunctionType)TYPE__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + return ((InternalEList)(InternalEList)getSubElements()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + return ((InternalEList)getSubElements()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + return getSubElements(); + case famPackage.FUNCTION__TYPE: + return getType(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + getSubElements().clear(); + getSubElements().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + getSubElements().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTION__SUB_ELEMENTS: + return subElements != null && !subElements.isEmpty(); + case famPackage.FUNCTION__TYPE: + return TYPE__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); + } + return super.eIsSet(featureID); + } + +} //FunctionImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalArchitectureModelImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalArchitectureModelImpl.java new file mode 100644 index 00000000..1b45df44 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalArchitectureModelImpl.java @@ -0,0 +1,152 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Functional Architecture Model'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalArchitectureModelImpl#getRootElements Root Elements}
  • + *
+ * + * @generated + */ +public class FunctionalArchitectureModelImpl extends MinimalEObjectImpl.Container implements FunctionalArchitectureModel { + /** + * The cached value of the '{@link #getRootElements() Root Elements}' containment reference list. + * + * + * @see #getRootElements() + * @generated + * @ordered + */ + protected EList rootElements; + + /** + * + * + * @generated + */ + protected FunctionalArchitectureModelImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_ARCHITECTURE_MODEL; + } + + /** + * + * + * @generated + */ + public EList getRootElements() { + if (rootElements == null) { + rootElements = new EObjectContainmentEList(FunctionalElement.class, this, famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS); + } + return rootElements; + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS: + return ((InternalEList)getRootElements()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS: + return getRootElements(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS: + getRootElements().clear(); + getRootElements().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS: + getRootElements().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS: + return rootElements != null && !rootElements.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //FunctionalArchitectureModelImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalDataImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalDataImpl.java new file mode 100644 index 00000000..069d53d4 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalDataImpl.java @@ -0,0 +1,267 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'Functional Data'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl#getTerminator Terminator}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalDataImpl#getInterface Interface}
  • + *
+ * + * @generated + */ +public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container implements FunctionalData { + /** + * The cached value of the '{@link #getTerminator() Terminator}' containment reference. + * + * + * @see #getTerminator() + * @generated + * @ordered + */ + protected FAMTerminator terminator; + + /** + * + * + * @generated + */ + protected FunctionalDataImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_DATA; + } + + /** + * + * + * @generated + */ + public FAMTerminator getTerminator() { + return terminator; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetTerminator(FAMTerminator newTerminator, NotificationChain msgs) { + FAMTerminator oldTerminator = terminator; + terminator = newTerminator; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_DATA__TERMINATOR, oldTerminator, newTerminator); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setTerminator(FAMTerminator newTerminator) { + if (newTerminator != terminator) { + NotificationChain msgs = null; + if (terminator != null) + msgs = ((InternalEObject)terminator).eInverseRemove(this, famPackage.FAM_TERMINATOR__DATA, FAMTerminator.class, msgs); + if (newTerminator != null) + msgs = ((InternalEObject)newTerminator).eInverseAdd(this, famPackage.FAM_TERMINATOR__DATA, FAMTerminator.class, msgs); + msgs = basicSetTerminator(newTerminator, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_DATA__TERMINATOR, newTerminator, newTerminator)); + } + + /** + * + * + * @generated + */ + public FunctionalInterface getInterface() { + if (eContainerFeatureID() != famPackage.FUNCTIONAL_DATA__INTERFACE) return null; + return (FunctionalInterface)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetInterface(FunctionalInterface newInterface, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newInterface, famPackage.FUNCTIONAL_DATA__INTERFACE, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setInterface(FunctionalInterface newInterface) { + if (newInterface != eInternalContainer() || (eContainerFeatureID() != famPackage.FUNCTIONAL_DATA__INTERFACE && newInterface != null)) { + if (EcoreUtil.isAncestor(this, newInterface)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newInterface != null) + msgs = ((InternalEObject)newInterface).eInverseAdd(this, famPackage.FUNCTIONAL_INTERFACE__DATA, FunctionalInterface.class, msgs); + msgs = basicSetInterface(newInterface, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_DATA__INTERFACE, newInterface, newInterface)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + if (terminator != null) + msgs = ((InternalEObject)terminator).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - famPackage.FUNCTIONAL_DATA__TERMINATOR, null, msgs); + return basicSetTerminator((FAMTerminator)otherEnd, msgs); + case famPackage.FUNCTIONAL_DATA__INTERFACE: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetInterface((FunctionalInterface)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + return basicSetTerminator(null, msgs); + case famPackage.FUNCTIONAL_DATA__INTERFACE: + return basicSetInterface(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case famPackage.FUNCTIONAL_DATA__INTERFACE: + return eInternalContainer().eInverseRemove(this, famPackage.FUNCTIONAL_INTERFACE__DATA, FunctionalInterface.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + return getTerminator(); + case famPackage.FUNCTIONAL_DATA__INTERFACE: + return getInterface(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + setTerminator((FAMTerminator)newValue); + return; + case famPackage.FUNCTIONAL_DATA__INTERFACE: + setInterface((FunctionalInterface)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + setTerminator((FAMTerminator)null); + return; + case famPackage.FUNCTIONAL_DATA__INTERFACE: + setInterface((FunctionalInterface)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_DATA__TERMINATOR: + return terminator != null; + case famPackage.FUNCTIONAL_DATA__INTERFACE: + return getInterface() != null; + } + return super.eIsSet(featureID); + } + +} //FunctionalDataImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalElementImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalElementImpl.java new file mode 100644 index 00000000..318a8706 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalElementImpl.java @@ -0,0 +1,318 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'Functional Element'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl#getInterface Interface}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl#getModel Model}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl#getParent Parent}
  • + *
+ * + * @generated + */ +public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container implements FunctionalElement { + /** + * The cached value of the '{@link #getInterface() Interface}' containment reference. + * + * + * @see #getInterface() + * @generated + * @ordered + */ + protected FunctionalInterface interface_; + + /** + * The cached setting delegate for the '{@link #getModel() Model}' reference. + * + * + * @see #getModel() + * @generated + * @ordered + */ + protected EStructuralFeature.Internal.SettingDelegate MODEL__ESETTING_DELEGATE = ((EStructuralFeature.Internal)famPackage.Literals.FUNCTIONAL_ELEMENT__MODEL).getSettingDelegate(); + + /** + * + * + * @generated + */ + protected FunctionalElementImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_ELEMENT; + } + + /** + * + * + * @generated + */ + public FunctionalInterface getInterface() { + return interface_; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetInterface(FunctionalInterface newInterface, NotificationChain msgs) { + FunctionalInterface oldInterface = interface_; + interface_ = newInterface; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_ELEMENT__INTERFACE, oldInterface, newInterface); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setInterface(FunctionalInterface newInterface) { + if (newInterface != interface_) { + NotificationChain msgs = null; + if (interface_ != null) + msgs = ((InternalEObject)interface_).eInverseRemove(this, famPackage.FUNCTIONAL_INTERFACE__ELEMENT, FunctionalInterface.class, msgs); + if (newInterface != null) + msgs = ((InternalEObject)newInterface).eInverseAdd(this, famPackage.FUNCTIONAL_INTERFACE__ELEMENT, FunctionalInterface.class, msgs); + msgs = basicSetInterface(newInterface, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_ELEMENT__INTERFACE, newInterface, newInterface)); + } + + /** + * + * + * @generated + */ + public FunctionalArchitectureModel getModel() { + return (FunctionalArchitectureModel)MODEL__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false); + } + + /** + * + * + * @generated + */ + public FunctionalArchitectureModel basicGetModel() { + return (FunctionalArchitectureModel)MODEL__ESETTING_DELEGATE.dynamicGet(this, null, 0, false, false); + } + + /** + * + * + * @generated + */ + public void setModel(FunctionalArchitectureModel newModel) { + MODEL__ESETTING_DELEGATE.dynamicSet(this, null, 0, newModel); + } + + /** + * + * + * @generated + */ + public Function getParent() { + if (eContainerFeatureID() != famPackage.FUNCTIONAL_ELEMENT__PARENT) return null; + return (Function)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetParent(Function newParent, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newParent, famPackage.FUNCTIONAL_ELEMENT__PARENT, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setParent(Function newParent) { + if (newParent != eInternalContainer() || (eContainerFeatureID() != famPackage.FUNCTIONAL_ELEMENT__PARENT && newParent != null)) { + if (EcoreUtil.isAncestor(this, newParent)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newParent != null) + msgs = ((InternalEObject)newParent).eInverseAdd(this, famPackage.FUNCTION__SUB_ELEMENTS, Function.class, msgs); + msgs = basicSetParent(newParent, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_ELEMENT__PARENT, newParent, newParent)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + if (interface_ != null) + msgs = ((InternalEObject)interface_).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - famPackage.FUNCTIONAL_ELEMENT__INTERFACE, null, msgs); + return basicSetInterface((FunctionalInterface)otherEnd, msgs); + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetParent((Function)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + return basicSetInterface(null, msgs); + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + return basicSetParent(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + return eInternalContainer().eInverseRemove(this, famPackage.FUNCTION__SUB_ELEMENTS, Function.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + return getInterface(); + case famPackage.FUNCTIONAL_ELEMENT__MODEL: + if (resolve) return getModel(); + return basicGetModel(); + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + return getParent(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + setInterface((FunctionalInterface)newValue); + return; + case famPackage.FUNCTIONAL_ELEMENT__MODEL: + setModel((FunctionalArchitectureModel)newValue); + return; + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + setParent((Function)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + setInterface((FunctionalInterface)null); + return; + case famPackage.FUNCTIONAL_ELEMENT__MODEL: + setModel((FunctionalArchitectureModel)null); + return; + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + setParent((Function)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_ELEMENT__INTERFACE: + return interface_ != null; + case famPackage.FUNCTIONAL_ELEMENT__MODEL: + return MODEL__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); + case famPackage.FUNCTIONAL_ELEMENT__PARENT: + return getParent() != null; + } + return super.eIsSet(featureID); + } + +} //FunctionalElementImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInputImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInputImpl.java new file mode 100644 index 00000000..b62e9742 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInputImpl.java @@ -0,0 +1,165 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Functional Input'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInputImpl#getIncomingLinks Incoming Links}
  • + *
+ * + * @generated + */ +public class FunctionalInputImpl extends FunctionalDataImpl implements FunctionalInput { + /** + * The cached value of the '{@link #getIncomingLinks() Incoming Links}' reference list. + * + * + * @see #getIncomingLinks() + * @generated + * @ordered + */ + protected EList incomingLinks; + + /** + * + * + * @generated + */ + protected FunctionalInputImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_INPUT; + } + + /** + * + * + * @generated + */ + public EList getIncomingLinks() { + if (incomingLinks == null) { + incomingLinks = new EObjectWithInverseResolvingEList(InformationLink.class, this, famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS, famPackage.INFORMATION_LINK__TO); + } + return incomingLinks; + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + return ((InternalEList)(InternalEList)getIncomingLinks()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + return ((InternalEList)getIncomingLinks()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + return getIncomingLinks(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + getIncomingLinks().clear(); + getIncomingLinks().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + getIncomingLinks().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS: + return incomingLinks != null && !incomingLinks.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //FunctionalInputImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInterfaceImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInterfaceImpl.java new file mode 100644 index 00000000..b9417a23 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalInterfaceImpl.java @@ -0,0 +1,243 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Functional Interface'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl#getData Data}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalInterfaceImpl#getElement Element}
  • + *
+ * + * @generated + */ +public class FunctionalInterfaceImpl extends MinimalEObjectImpl.Container implements FunctionalInterface { + /** + * The cached value of the '{@link #getData() Data}' containment reference list. + * + * + * @see #getData() + * @generated + * @ordered + */ + protected EList data; + + /** + * + * + * @generated + */ + protected FunctionalInterfaceImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_INTERFACE; + } + + /** + * + * + * @generated + */ + public EList getData() { + if (data == null) { + data = new EObjectContainmentWithInverseEList(FunctionalData.class, this, famPackage.FUNCTIONAL_INTERFACE__DATA, famPackage.FUNCTIONAL_DATA__INTERFACE); + } + return data; + } + + /** + * + * + * @generated + */ + public FunctionalElement getElement() { + if (eContainerFeatureID() != famPackage.FUNCTIONAL_INTERFACE__ELEMENT) return null; + return (FunctionalElement)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetElement(FunctionalElement newElement, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newElement, famPackage.FUNCTIONAL_INTERFACE__ELEMENT, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setElement(FunctionalElement newElement) { + if (newElement != eInternalContainer() || (eContainerFeatureID() != famPackage.FUNCTIONAL_INTERFACE__ELEMENT && newElement != null)) { + if (EcoreUtil.isAncestor(this, newElement)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newElement != null) + msgs = ((InternalEObject)newElement).eInverseAdd(this, famPackage.FUNCTIONAL_ELEMENT__INTERFACE, FunctionalElement.class, msgs); + msgs = basicSetElement(newElement, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.FUNCTIONAL_INTERFACE__ELEMENT, newElement, newElement)); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + return ((InternalEList)(InternalEList)getData()).basicAdd(otherEnd, msgs); + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetElement((FunctionalElement)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + return ((InternalEList)getData()).basicRemove(otherEnd, msgs); + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + return basicSetElement(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + return eInternalContainer().eInverseRemove(this, famPackage.FUNCTIONAL_ELEMENT__INTERFACE, FunctionalElement.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + return getData(); + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + return getElement(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + getData().clear(); + getData().addAll((Collection)newValue); + return; + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + setElement((FunctionalElement)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + getData().clear(); + return; + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + setElement((FunctionalElement)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_INTERFACE__DATA: + return data != null && !data.isEmpty(); + case famPackage.FUNCTIONAL_INTERFACE__ELEMENT: + return getElement() != null; + } + return super.eIsSet(featureID); + } + +} //FunctionalInterfaceImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalOutputImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalOutputImpl.java new file mode 100644 index 00000000..30bde348 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/FunctionalOutputImpl.java @@ -0,0 +1,165 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Functional Output'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalOutputImpl#getOutgoingLinks Outgoing Links}
  • + *
+ * + * @generated + */ +public class FunctionalOutputImpl extends FunctionalDataImpl implements FunctionalOutput { + /** + * The cached value of the '{@link #getOutgoingLinks() Outgoing Links}' containment reference list. + * + * + * @see #getOutgoingLinks() + * @generated + * @ordered + */ + protected EList outgoingLinks; + + /** + * + * + * @generated + */ + protected FunctionalOutputImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.FUNCTIONAL_OUTPUT; + } + + /** + * + * + * @generated + */ + public EList getOutgoingLinks() { + if (outgoingLinks == null) { + outgoingLinks = new EObjectContainmentWithInverseEList(InformationLink.class, this, famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS, famPackage.INFORMATION_LINK__FROM); + } + return outgoingLinks; + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + return ((InternalEList)(InternalEList)getOutgoingLinks()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + return ((InternalEList)getOutgoingLinks()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + return getOutgoingLinks(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + getOutgoingLinks().clear(); + getOutgoingLinks().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + getOutgoingLinks().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS: + return outgoingLinks != null && !outgoingLinks.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //FunctionalOutputImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/InformationLinkImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/InformationLinkImpl.java new file mode 100644 index 00000000..b87f4201 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/InformationLinkImpl.java @@ -0,0 +1,285 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'Information Link'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl#getFrom From}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.InformationLinkImpl#getTo To}
  • + *
+ * + * @generated + */ +public class InformationLinkImpl extends MinimalEObjectImpl.Container implements InformationLink { + /** + * The cached value of the '{@link #getTo() To}' reference. + * + * + * @see #getTo() + * @generated + * @ordered + */ + protected FunctionalInput to; + + /** + * + * + * @generated + */ + protected InformationLinkImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return famPackage.Literals.INFORMATION_LINK; + } + + /** + * + * + * @generated + */ + public FunctionalOutput getFrom() { + if (eContainerFeatureID() != famPackage.INFORMATION_LINK__FROM) return null; + return (FunctionalOutput)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetFrom(FunctionalOutput newFrom, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newFrom, famPackage.INFORMATION_LINK__FROM, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setFrom(FunctionalOutput newFrom) { + if (newFrom != eInternalContainer() || (eContainerFeatureID() != famPackage.INFORMATION_LINK__FROM && newFrom != null)) { + if (EcoreUtil.isAncestor(this, newFrom)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newFrom != null) + msgs = ((InternalEObject)newFrom).eInverseAdd(this, famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS, FunctionalOutput.class, msgs); + msgs = basicSetFrom(newFrom, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.INFORMATION_LINK__FROM, newFrom, newFrom)); + } + + /** + * + * + * @generated + */ + public FunctionalInput getTo() { + if (to != null && to.eIsProxy()) { + InternalEObject oldTo = (InternalEObject)to; + to = (FunctionalInput)eResolveProxy(oldTo); + if (to != oldTo) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, famPackage.INFORMATION_LINK__TO, oldTo, to)); + } + } + return to; + } + + /** + * + * + * @generated + */ + public FunctionalInput basicGetTo() { + return to; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetTo(FunctionalInput newTo, NotificationChain msgs) { + FunctionalInput oldTo = to; + to = newTo; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, famPackage.INFORMATION_LINK__TO, oldTo, newTo); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setTo(FunctionalInput newTo) { + if (newTo != to) { + NotificationChain msgs = null; + if (to != null) + msgs = ((InternalEObject)to).eInverseRemove(this, famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS, FunctionalInput.class, msgs); + if (newTo != null) + msgs = ((InternalEObject)newTo).eInverseAdd(this, famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS, FunctionalInput.class, msgs); + msgs = basicSetTo(newTo, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, famPackage.INFORMATION_LINK__TO, newTo, newTo)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetFrom((FunctionalOutput)otherEnd, msgs); + case famPackage.INFORMATION_LINK__TO: + if (to != null) + msgs = ((InternalEObject)to).eInverseRemove(this, famPackage.FUNCTIONAL_INPUT__INCOMING_LINKS, FunctionalInput.class, msgs); + return basicSetTo((FunctionalInput)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + return basicSetFrom(null, msgs); + case famPackage.INFORMATION_LINK__TO: + return basicSetTo(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case famPackage.INFORMATION_LINK__FROM: + return eInternalContainer().eInverseRemove(this, famPackage.FUNCTIONAL_OUTPUT__OUTGOING_LINKS, FunctionalOutput.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + return getFrom(); + case famPackage.INFORMATION_LINK__TO: + if (resolve) return getTo(); + return basicGetTo(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + setFrom((FunctionalOutput)newValue); + return; + case famPackage.INFORMATION_LINK__TO: + setTo((FunctionalInput)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + setFrom((FunctionalOutput)null); + return; + case famPackage.INFORMATION_LINK__TO: + setTo((FunctionalInput)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case famPackage.INFORMATION_LINK__FROM: + return getFrom() != null; + case famPackage.INFORMATION_LINK__TO: + return to != null; + } + return super.eIsSet(featureID); + } + +} //InformationLinkImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famFactoryImpl.java new file mode 100644 index 00000000..5c2a9c51 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famFactoryImpl.java @@ -0,0 +1,219 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.impl.EFactoryImpl; +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famFactory; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +/** + * + * An implementation of the model Factory. + * + * @generated + */ +public class famFactoryImpl extends EFactoryImpl implements famFactory { + /** + * Creates the default factory implementation. + * + * + * @generated + */ + public static famFactory init() { + try { + famFactory thefamFactory = (famFactory)EPackage.Registry.INSTANCE.getEFactory(famPackage.eNS_URI); + if (thefamFactory != null) { + return thefamFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new famFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * + * + * @generated + */ + public famFactoryImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL: return createFunctionalArchitectureModel(); + case famPackage.FUNCTION: return createFunction(); + case famPackage.FAM_TERMINATOR: return createFAMTerminator(); + case famPackage.INFORMATION_LINK: return createInformationLink(); + case famPackage.FUNCTIONAL_INTERFACE: return createFunctionalInterface(); + case famPackage.FUNCTIONAL_INPUT: return createFunctionalInput(); + case famPackage.FUNCTIONAL_OUTPUT: return createFunctionalOutput(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + @Override + public Object createFromString(EDataType eDataType, String initialValue) { + switch (eDataType.getClassifierID()) { + case famPackage.FUNCTION_TYPE: + return createFunctionTypeFromString(eDataType, initialValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + @Override + public String convertToString(EDataType eDataType, Object instanceValue) { + switch (eDataType.getClassifierID()) { + case famPackage.FUNCTION_TYPE: + return convertFunctionTypeToString(eDataType, instanceValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + public FunctionalArchitectureModel createFunctionalArchitectureModel() { + FunctionalArchitectureModelImpl functionalArchitectureModel = new FunctionalArchitectureModelImpl(); + return functionalArchitectureModel; + } + + /** + * + * + * @generated + */ + public Function createFunction() { + FunctionImpl function = new FunctionImpl(); + return function; + } + + /** + * + * + * @generated + */ + public FAMTerminator createFAMTerminator() { + FAMTerminatorImpl famTerminator = new FAMTerminatorImpl(); + return famTerminator; + } + + /** + * + * + * @generated + */ + public InformationLink createInformationLink() { + InformationLinkImpl informationLink = new InformationLinkImpl(); + return informationLink; + } + + /** + * + * + * @generated + */ + public FunctionalInterface createFunctionalInterface() { + FunctionalInterfaceImpl functionalInterface = new FunctionalInterfaceImpl(); + return functionalInterface; + } + + /** + * + * + * @generated + */ + public FunctionalInput createFunctionalInput() { + FunctionalInputImpl functionalInput = new FunctionalInputImpl(); + return functionalInput; + } + + /** + * + * + * @generated + */ + public FunctionalOutput createFunctionalOutput() { + FunctionalOutputImpl functionalOutput = new FunctionalOutputImpl(); + return functionalOutput; + } + + /** + * + * + * @generated + */ + public FunctionType createFunctionTypeFromString(EDataType eDataType, String initialValue) { + FunctionType result = FunctionType.get(initialValue); + if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); + return result; + } + + /** + * + * + * @generated + */ + public String convertFunctionTypeToString(EDataType eDataType, Object instanceValue) { + return instanceValue == null ? null : instanceValue.toString(); + } + + /** + * + * + * @generated + */ + public famPackage getfamPackage() { + return (famPackage)getEPackage(); + } + + /** + * + * + * @deprecated + * @generated + */ + @Deprecated + public static famPackage getPackage() { + return famPackage.eINSTANCE; + } + +} //famFactoryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java new file mode 100644 index 00000000..74efeeeb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java @@ -0,0 +1,574 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famFactory; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EEnum; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +/** + * + * An implementation of the model Package. + * + * @generated + */ +public class famPackageImpl extends EPackageImpl implements famPackage { + /** + * + * + * @generated + */ + private EClass functionalElementEClass = null; + + /** + * + * + * @generated + */ + private EClass functionalArchitectureModelEClass = null; + + /** + * + * + * @generated + */ + private EClass functionEClass = null; + + /** + * + * + * @generated + */ + private EClass famTerminatorEClass = null; + + /** + * + * + * @generated + */ + private EClass informationLinkEClass = null; + + /** + * + * + * @generated + */ + private EClass functionalInterfaceEClass = null; + + /** + * + * + * @generated + */ + private EClass functionalInputEClass = null; + + /** + * + * + * @generated + */ + private EClass functionalOutputEClass = null; + + /** + * + * + * @generated + */ + private EClass functionalDataEClass = null; + + /** + * + * + * @generated + */ + private EEnum functionTypeEEnum = null; + + /** + * Creates an instance of the model Package, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + *

Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * + * + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#eNS_URI + * @see #init() + * @generated + */ + private famPackageImpl() { + super(eNS_URI, famFactory.eINSTANCE); + } + + /** + * + * + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. + * + *

This method is used to initialize {@link famPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * + * + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static famPackage init() { + if (isInited) return (famPackage)EPackage.Registry.INSTANCE.getEPackage(famPackage.eNS_URI); + + // Obtain or create and register package + famPackageImpl thefamPackage = (famPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof famPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new famPackageImpl()); + + isInited = true; + + // Create package meta-data objects + thefamPackage.createPackageContents(); + + // Initialize created meta-data + thefamPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + thefamPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(famPackage.eNS_URI, thefamPackage); + return thefamPackage; + } + + /** + * + * + * @generated + */ + public EClass getFunctionalElement() { + return functionalElementEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalElement_Interface() { + return (EReference)functionalElementEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getFunctionalElement_Model() { + return (EReference)functionalElementEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EReference getFunctionalElement_Parent() { + return (EReference)functionalElementEClass.getEStructuralFeatures().get(2); + } + + /** + * + * + * @generated + */ + public EClass getFunctionalArchitectureModel() { + return functionalArchitectureModelEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalArchitectureModel_RootElements() { + return (EReference)functionalArchitectureModelEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getFunction() { + return functionEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunction_SubElements() { + return (EReference)functionEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EAttribute getFunction_Type() { + return (EAttribute)functionEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getFAMTerminator() { + return famTerminatorEClass; + } + + /** + * + * + * @generated + */ + public EReference getFAMTerminator_Data() { + return (EReference)famTerminatorEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getInformationLink() { + return informationLinkEClass; + } + + /** + * + * + * @generated + */ + public EReference getInformationLink_From() { + return (EReference)informationLinkEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getInformationLink_To() { + return (EReference)informationLinkEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getFunctionalInterface() { + return functionalInterfaceEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalInterface_Data() { + return (EReference)functionalInterfaceEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getFunctionalInterface_Element() { + return (EReference)functionalInterfaceEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getFunctionalInput() { + return functionalInputEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalInput_IncomingLinks() { + return (EReference)functionalInputEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getFunctionalOutput() { + return functionalOutputEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalOutput_OutgoingLinks() { + return (EReference)functionalOutputEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getFunctionalData() { + return functionalDataEClass; + } + + /** + * + * + * @generated + */ + public EReference getFunctionalData_Terminator() { + return (EReference)functionalDataEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getFunctionalData_Interface() { + return (EReference)functionalDataEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EEnum getFunctionType() { + return functionTypeEEnum; + } + + /** + * + * + * @generated + */ + public famFactory getfamFactory() { + return (famFactory)getEFactoryInstance(); + } + + /** + * + * + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + functionalElementEClass = createEClass(FUNCTIONAL_ELEMENT); + createEReference(functionalElementEClass, FUNCTIONAL_ELEMENT__INTERFACE); + createEReference(functionalElementEClass, FUNCTIONAL_ELEMENT__MODEL); + createEReference(functionalElementEClass, FUNCTIONAL_ELEMENT__PARENT); + + functionalArchitectureModelEClass = createEClass(FUNCTIONAL_ARCHITECTURE_MODEL); + createEReference(functionalArchitectureModelEClass, FUNCTIONAL_ARCHITECTURE_MODEL__ROOT_ELEMENTS); + + functionEClass = createEClass(FUNCTION); + createEReference(functionEClass, FUNCTION__SUB_ELEMENTS); + createEAttribute(functionEClass, FUNCTION__TYPE); + + famTerminatorEClass = createEClass(FAM_TERMINATOR); + createEReference(famTerminatorEClass, FAM_TERMINATOR__DATA); + + informationLinkEClass = createEClass(INFORMATION_LINK); + createEReference(informationLinkEClass, INFORMATION_LINK__FROM); + createEReference(informationLinkEClass, INFORMATION_LINK__TO); + + functionalInterfaceEClass = createEClass(FUNCTIONAL_INTERFACE); + createEReference(functionalInterfaceEClass, FUNCTIONAL_INTERFACE__DATA); + createEReference(functionalInterfaceEClass, FUNCTIONAL_INTERFACE__ELEMENT); + + functionalInputEClass = createEClass(FUNCTIONAL_INPUT); + createEReference(functionalInputEClass, FUNCTIONAL_INPUT__INCOMING_LINKS); + + functionalOutputEClass = createEClass(FUNCTIONAL_OUTPUT); + createEReference(functionalOutputEClass, FUNCTIONAL_OUTPUT__OUTGOING_LINKS); + + functionalDataEClass = createEClass(FUNCTIONAL_DATA); + createEReference(functionalDataEClass, FUNCTIONAL_DATA__TERMINATOR); + createEReference(functionalDataEClass, FUNCTIONAL_DATA__INTERFACE); + + // Create enums + functionTypeEEnum = createEEnum(FUNCTION_TYPE); + } + + /** + * + * + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + functionEClass.getESuperTypes().add(this.getFunctionalElement()); + functionalInputEClass.getESuperTypes().add(this.getFunctionalData()); + functionalOutputEClass.getESuperTypes().add(this.getFunctionalData()); + + // Initialize classes, features, and operations; add parameters + initEClass(functionalElementEClass, FunctionalElement.class, "FunctionalElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalElement_Interface(), this.getFunctionalInterface(), this.getFunctionalInterface_Element(), "interface", null, 0, 1, FunctionalElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalElement_Model(), this.getFunctionalArchitectureModel(), null, "model", null, 1, 1, FunctionalElement.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalElement_Parent(), this.getFunction(), this.getFunction_SubElements(), "parent", null, 0, 1, FunctionalElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionalArchitectureModelEClass, FunctionalArchitectureModel.class, "FunctionalArchitectureModel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalArchitectureModel_RootElements(), this.getFunctionalElement(), null, "rootElements", null, 0, -1, FunctionalArchitectureModel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionEClass, Function.class, "Function", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunction_SubElements(), this.getFunctionalElement(), this.getFunctionalElement_Parent(), "subElements", null, 0, -1, Function.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEAttribute(getFunction_Type(), this.getFunctionType(), "type", null, 1, 1, Function.class, IS_TRANSIENT, IS_VOLATILE, !IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + + initEClass(famTerminatorEClass, FAMTerminator.class, "FAMTerminator", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFAMTerminator_Data(), this.getFunctionalData(), this.getFunctionalData_Terminator(), "data", null, 0, 1, FAMTerminator.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(informationLinkEClass, InformationLink.class, "InformationLink", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getInformationLink_From(), this.getFunctionalOutput(), this.getFunctionalOutput_OutgoingLinks(), "from", null, 0, 1, InformationLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getInformationLink_To(), this.getFunctionalInput(), this.getFunctionalInput_IncomingLinks(), "to", null, 1, 1, InformationLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionalInterfaceEClass, FunctionalInterface.class, "FunctionalInterface", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalInterface_Data(), this.getFunctionalData(), this.getFunctionalData_Interface(), "data", null, 0, -1, FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalInterface_Element(), this.getFunctionalElement(), this.getFunctionalElement_Interface(), "element", null, 0, 1, FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionalInputEClass, FunctionalInput.class, "FunctionalInput", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalInput_IncomingLinks(), this.getInformationLink(), this.getInformationLink_To(), "IncomingLinks", null, 0, -1, FunctionalInput.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionalOutputEClass, FunctionalOutput.class, "FunctionalOutput", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalOutput_OutgoingLinks(), this.getInformationLink(), this.getInformationLink_From(), "outgoingLinks", null, 0, -1, FunctionalOutput.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(functionalDataEClass, FunctionalData.class, "FunctionalData", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalData_Terminator(), this.getFAMTerminator(), this.getFAMTerminator_Data(), "terminator", null, 0, 1, FunctionalData.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalData_Interface(), this.getFunctionalInterface(), this.getFunctionalInterface_Data(), "interface", null, 0, 1, FunctionalData.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + // Initialize enums and add enum literals + initEEnum(functionTypeEEnum, FunctionType.class, "FunctionType"); + addEEnumLiteral(functionTypeEEnum, FunctionType.ROOT); + addEEnumLiteral(functionTypeEEnum, FunctionType.INTERMEDIATE); + addEEnumLiteral(functionTypeEEnum, FunctionType.LEAF); + + // Create resource + createResource(eNS_URI); + + // Create annotations + // http://www.eclipse.org/emf/2002/Ecore + createEcoreAnnotations(); + // org.eclipse.viatra.query.querybasedfeature + createOrgAnnotations(); + } + + /** + * Initializes the annotations for http://www.eclipse.org/emf/2002/Ecore. + * + * + * @generated + */ + protected void createEcoreAnnotations() { + String source = "http://www.eclipse.org/emf/2002/Ecore"; + addAnnotation + (this, + source, + new String[] { + "settingDelegates", "org.eclipse.viatra.query.querybasedfeature" + }); + } + + /** + * Initializes the annotations for org.eclipse.viatra.query.querybasedfeature. + * + * + * @generated + */ + protected void createOrgAnnotations() { + String source = "org.eclipse.viatra.query.querybasedfeature"; + addAnnotation + (getFunctionalElement_Model(), + source, + new String[] { + "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.xyz.model" + }); + addAnnotation + (getFunction_Type(), + source, + new String[] { + "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.xyz.type" + }); + } + +} //famPackageImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql new file mode 100644 index 00000000..02d34dcd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql @@ -0,0 +1,103 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries + +import "FamMetamodel" + +@Constraint(message="terminatorAndInformation", severity="error", key={T}) +pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { + FunctionalOutput.outgoingLinks(Out,I); + FunctionalOutput.terminator(Out,T); +} or { + InformationLink.to(I,In); + FunctionalInput.terminator(In,T); +} + +@QueryBasedFeature +pattern type(This : Function, Target : FunctionType) = { + find rootElements(_Model, This); + Target == FunctionType::Root; +} or { + neg find parent(_Child, This); + neg find rootElements(_Model, This); + Target == FunctionType::Leaf; +} or { + find parent(This, _Par); + find parent(_Child, This); + Target == FunctionType::Intermediate; +} + +pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { + FunctionalArchitectureModel.rootElements(Model, Root); +} + +pattern parent(Func : Function, Par : Function) = { + Function.parent(Func, Par); +} + +@QueryBasedFeature +pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { + FunctionalElement(This); + FunctionalArchitectureModel(Target); +} + +/* +@Constraint(message="noRoot", severity="error", key={fam}) +pattern noRoot(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasRoot(_); +} +@Constraint(message="noIntermediate", severity="error", key={fam}) +pattern noInt(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasInt(_); +} +@Constraint(message="noLeaf", severity="error", key={fam}) +pattern noLeaf(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasLeaf(_); +} +*/ + +/* +@QueryBasedFeature +pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { + find parent+(This, Parent); + find rootElements(Target, Parent); +} or { + find rootElements(Target, This); +} + +pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { + FunctionalInterface.data(FI, FD); +} + +@QueryBasedFeature +pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.outputs(This, Output); + InformationLink.from(Target, Output); +} + +@QueryBasedFeature +pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.inputs(This, Input); + InformationLink.to(Target, Input); +} + +@QueryBasedFeature +pattern connects(This : FunctionalElement, Target : FunctionalElement) = { + FunctionalElement.outgoingLinks(This,Link); + FunctionalElement.incomingLinks(Target,Link); +}*/ + +/*pattern frequency(a: Function, b : EInt) { + Function.minimumFrequency(a,b); +}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famAdapterFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famAdapterFactory.java new file mode 100644 index 00000000..b5a4e37b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famAdapterFactory.java @@ -0,0 +1,271 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.util; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; +import org.eclipse.emf.ecore.EObject; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +/** + * + * The Adapter Factory for the model. + * It provides an adapter createXXX method for each class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage + * @generated + */ +public class famAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * + * + * @generated + */ + protected static famPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * + * + * @generated + */ + public famAdapterFactory() { + if (modelPackage == null) { + modelPackage = famPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * + * This implementation returns true if the object is either the model's package or is an instance object of the model. + * + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the createXXX methods. + * + * + * @generated + */ + protected famSwitch modelSwitch = + new famSwitch() { + @Override + public Adapter caseFunctionalElement(FunctionalElement object) { + return createFunctionalElementAdapter(); + } + @Override + public Adapter caseFunctionalArchitectureModel(FunctionalArchitectureModel object) { + return createFunctionalArchitectureModelAdapter(); + } + @Override + public Adapter caseFunction(Function object) { + return createFunctionAdapter(); + } + @Override + public Adapter caseFAMTerminator(FAMTerminator object) { + return createFAMTerminatorAdapter(); + } + @Override + public Adapter caseInformationLink(InformationLink object) { + return createInformationLinkAdapter(); + } + @Override + public Adapter caseFunctionalInterface(FunctionalInterface object) { + return createFunctionalInterfaceAdapter(); + } + @Override + public Adapter caseFunctionalInput(FunctionalInput object) { + return createFunctionalInputAdapter(); + } + @Override + public Adapter caseFunctionalOutput(FunctionalOutput object) { + return createFunctionalOutputAdapter(); + } + @Override + public Adapter caseFunctionalData(FunctionalData object) { + return createFunctionalDataAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the target. + * + * + * @param target the object to adapt. + * @return the adapter for the target. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement Functional Element}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement + * @generated + */ + public Adapter createFunctionalElementAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel Functional Architecture Model}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel + * @generated + */ + public Adapter createFunctionalArchitectureModelAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function Function}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function + * @generated + */ + public Adapter createFunctionAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator FAM Terminator}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator + * @generated + */ + public Adapter createFAMTerminatorAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink Information Link}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink + * @generated + */ + public Adapter createInformationLinkAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface Functional Interface}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface + * @generated + */ + public Adapter createFunctionalInterfaceAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput Functional Input}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput + * @generated + */ + public Adapter createFunctionalInputAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput Functional Output}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput + * @generated + */ + public Adapter createFunctionalOutputAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData Functional Data}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData + * @generated + */ + public Adapter createFunctionalDataAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * + * This default implementation returns null. + * + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //famAdapterFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famSwitch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famSwitch.java new file mode 100644 index 00000000..979bd3e9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/util/famSwitch.java @@ -0,0 +1,289 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.util; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.util.Switch; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalArchitectureModel; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalData; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalInterface; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionalOutput; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage; + +/** + * + * The Switch for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the caseXXX method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage + * @generated + */ +public class famSwitch extends Switch { + /** + * The cached model package + * + * + * @generated + */ + protected static famPackage modelPackage; + + /** + * Creates an instance of the switch. + * + * + * @generated + */ + public famSwitch() { + if (modelPackage == null) { + modelPackage = famPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * + * + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. + * + * + * @return the first non-null result returned by a caseXXX call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case famPackage.FUNCTIONAL_ELEMENT: { + FunctionalElement functionalElement = (FunctionalElement)theEObject; + T result = caseFunctionalElement(functionalElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTIONAL_ARCHITECTURE_MODEL: { + FunctionalArchitectureModel functionalArchitectureModel = (FunctionalArchitectureModel)theEObject; + T result = caseFunctionalArchitectureModel(functionalArchitectureModel); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTION: { + Function function = (Function)theEObject; + T result = caseFunction(function); + if (result == null) result = caseFunctionalElement(function); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FAM_TERMINATOR: { + FAMTerminator famTerminator = (FAMTerminator)theEObject; + T result = caseFAMTerminator(famTerminator); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.INFORMATION_LINK: { + InformationLink informationLink = (InformationLink)theEObject; + T result = caseInformationLink(informationLink); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTIONAL_INTERFACE: { + FunctionalInterface functionalInterface = (FunctionalInterface)theEObject; + T result = caseFunctionalInterface(functionalInterface); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTIONAL_INPUT: { + FunctionalInput functionalInput = (FunctionalInput)theEObject; + T result = caseFunctionalInput(functionalInput); + if (result == null) result = caseFunctionalData(functionalInput); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTIONAL_OUTPUT: { + FunctionalOutput functionalOutput = (FunctionalOutput)theEObject; + T result = caseFunctionalOutput(functionalOutput); + if (result == null) result = caseFunctionalData(functionalOutput); + if (result == null) result = defaultCase(theEObject); + return result; + } + case famPackage.FUNCTIONAL_DATA: { + FunctionalData functionalData = (FunctionalData)theEObject; + T result = caseFunctionalData(functionalData); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Element'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Element'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalElement(FunctionalElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Architecture Model'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Architecture Model'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalArchitectureModel(FunctionalArchitectureModel object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Function'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Function'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunction(Function object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'FAM Terminator'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'FAM Terminator'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFAMTerminator(FAMTerminator object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Information Link'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Information Link'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseInformationLink(InformationLink object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Interface'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Interface'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalInterface(FunctionalInterface object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Input'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Input'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalInput(FunctionalInput object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Output'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Output'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalOutput(FunctionalOutput object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Functional Data'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Functional Data'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFunctionalData(FunctionalData object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'EObject'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'EObject'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //famSwitch diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Dir.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Dir.java new file mode 100644 index 00000000..03290097 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Dir.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.common.util.EList; + +/** + * + * A representation of the model object 'Dir'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir#getContents Contents}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getDir() + * @model + * @generated + */ +public interface Dir extends FSObject { + /** + * Returns the value of the 'Contents' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent Parent}'. + * + *

+ * If the meaning of the 'Contents' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Contents' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getDir_Contents() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent + * @model opposite="parent" containment="true" + * @generated + */ + EList getContents(); + +} // Dir diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FSObject.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FSObject.java new file mode 100644 index 00000000..87e4e4df --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FSObject.java @@ -0,0 +1,52 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'FS Object'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent Parent}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFSObject() + * @model abstract="true" + * @generated + */ +public interface FSObject extends EObject { + /** + * Returns the value of the 'Parent' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir#getContents Contents}'. + * + *

+ * If the meaning of the 'Parent' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Parent' container reference. + * @see #setParent(Dir) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFSObject_Parent() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir#getContents + * @model opposite="contents" transient="false" + * @generated + */ + Dir getParent(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent Parent}' container reference. + * + * + * @param value the new value of the 'Parent' container reference. + * @see #getParent() + * @generated + */ + void setParent(Dir value); + +} // FSObject diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/File.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/File.java new file mode 100644 index 00000000..f829076c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/File.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + + +/** + * + * A representation of the model object 'File'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFile() + * @model + * @generated + */ +public interface File extends FSObject { +} // File diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java new file mode 100644 index 00000000..c1c75043 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java @@ -0,0 +1,70 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'File System'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getRoot Root}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getLive Live}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFileSystem() + * @model + * @generated + */ +public interface FileSystem extends EObject { + /** + * Returns the value of the 'Root' containment reference. + * + *

+ * If the meaning of the 'Root' containment reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Root' containment reference. + * @see #setRoot(Dir) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFileSystem_Root() + * @model containment="true" required="true" + * @generated + */ + Dir getRoot(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getRoot Root}' containment reference. + * + * + * @param value the new value of the 'Root' containment reference. + * @see #getRoot() + * @generated + */ + void setRoot(Dir value); + + /** + * Returns the value of the 'Live' reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject}. + * + *

+ * If the meaning of the 'Live' reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Live' reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFileSystem_Live() + * @model transient="true" changeable="false" volatile="true" derived="true" + * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live'" + * @generated + */ + EList getLive(); + +} // FileSystem diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Model.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Model.java new file mode 100644 index 00000000..e75bd41a --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/Model.java @@ -0,0 +1,69 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Model'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getFilesystems Filesystems}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getOtherFSObjects Other FS Objects}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getModel() + * @model + * @generated + */ +public interface Model extends EObject { + /** + * Returns the value of the 'Filesystems' containment reference. + * + *

+ * If the meaning of the 'Filesystems' containment reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Filesystems' containment reference. + * @see #setFilesystems(FileSystem) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getModel_Filesystems() + * @model containment="true" required="true" + * @generated + */ + FileSystem getFilesystems(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getFilesystems Filesystems}' containment reference. + * + * + * @param value the new value of the 'Filesystems' containment reference. + * @see #getFilesystems() + * @generated + */ + void setFilesystems(FileSystem value); + + /** + * Returns the value of the 'Other FS Objects' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject}. + * + *

+ * If the meaning of the 'Other FS Objects' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Other FS Objects' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getModel_OtherFSObjects() + * @model containment="true" + * @generated + */ + EList getOtherFSObjects(); + +} // Model diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemFactory.java new file mode 100644 index 00000000..401becfb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemFactory.java @@ -0,0 +1,69 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.ecore.EFactory; + +/** + * + * The Factory for the model. + * It provides a create method for each non-abstract class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage + * @generated + */ +public interface filesystemFactory extends EFactory { + /** + * The singleton instance of the factory. + * + * + * @generated + */ + filesystemFactory eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.init(); + + /** + * Returns a new object of class 'File System'. + * + * + * @return a new object of class 'File System'. + * @generated + */ + FileSystem createFileSystem(); + + /** + * Returns a new object of class 'Dir'. + * + * + * @return a new object of class 'Dir'. + * @generated + */ + Dir createDir(); + + /** + * Returns a new object of class 'File'. + * + * + * @return a new object of class 'File'. + * @generated + */ + File createFile(); + + /** + * Returns a new object of class 'Model'. + * + * + * @return a new object of class 'Model'. + * @generated + */ + Model createModel(); + + /** + * Returns the package supported by this factory. + * + * + * @return the package supported by this factory. + * @generated + */ + filesystemPackage getfilesystemPackage(); + +} //filesystemFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemPackage.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemPackage.java new file mode 100644 index 00000000..08133f96 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/filesystemPackage.java @@ -0,0 +1,511 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * + * The Package for the model. + * It contains accessors for the meta objects to represent + *
    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemFactory + * @model kind="package" + * annotation="http://www.eclipse.org/emf/2002/Ecore settingDelegates='org.eclipse.viatra.query.querybasedfeature'" + * @generated + */ +public interface filesystemPackage extends EPackage { + /** + * The package name. + * + * + * @generated + */ + String eNAME = "filesystem"; + + /** + * The package namespace URI. + * + * + * @generated + */ + String eNS_URI = "FileSystemMetamodel"; + + /** + * The package namespace name. + * + * + * @generated + */ + String eNS_PREFIX = "filesystem"; + + /** + * The singleton instance of the package. + * + * + * @generated + */ + filesystemPackage eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl.init(); + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl File System}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFileSystem() + * @generated + */ + int FILE_SYSTEM = 0; + + /** + * The feature id for the 'Root' containment reference. + * + * + * @generated + * @ordered + */ + int FILE_SYSTEM__ROOT = 0; + + /** + * The feature id for the 'Live' reference list. + * + * + * @generated + * @ordered + */ + int FILE_SYSTEM__LIVE = 1; + + /** + * The number of structural features of the 'File System' class. + * + * + * @generated + * @ordered + */ + int FILE_SYSTEM_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'File System' class. + * + * + * @generated + * @ordered + */ + int FILE_SYSTEM_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FSObjectImpl FS Object}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FSObjectImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFSObject() + * @generated + */ + int FS_OBJECT = 1; + + /** + * The feature id for the 'Parent' container reference. + * + * + * @generated + * @ordered + */ + int FS_OBJECT__PARENT = 0; + + /** + * The number of structural features of the 'FS Object' class. + * + * + * @generated + * @ordered + */ + int FS_OBJECT_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'FS Object' class. + * + * + * @generated + * @ordered + */ + int FS_OBJECT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.DirImpl Dir}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.DirImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getDir() + * @generated + */ + int DIR = 2; + + /** + * The feature id for the 'Parent' container reference. + * + * + * @generated + * @ordered + */ + int DIR__PARENT = FS_OBJECT__PARENT; + + /** + * The feature id for the 'Contents' containment reference list. + * + * + * @generated + * @ordered + */ + int DIR__CONTENTS = FS_OBJECT_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'Dir' class. + * + * + * @generated + * @ordered + */ + int DIR_FEATURE_COUNT = FS_OBJECT_FEATURE_COUNT + 1; + + /** + * The number of operations of the 'Dir' class. + * + * + * @generated + * @ordered + */ + int DIR_OPERATION_COUNT = FS_OBJECT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileImpl File}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFile() + * @generated + */ + int FILE = 3; + + /** + * The feature id for the 'Parent' container reference. + * + * + * @generated + * @ordered + */ + int FILE__PARENT = FS_OBJECT__PARENT; + + /** + * The number of structural features of the 'File' class. + * + * + * @generated + * @ordered + */ + int FILE_FEATURE_COUNT = FS_OBJECT_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'File' class. + * + * + * @generated + * @ordered + */ + int FILE_OPERATION_COUNT = FS_OBJECT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl Model}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getModel() + * @generated + */ + int MODEL = 4; + + /** + * The feature id for the 'Filesystems' containment reference. + * + * + * @generated + * @ordered + */ + int MODEL__FILESYSTEMS = 0; + + /** + * The feature id for the 'Other FS Objects' containment reference list. + * + * + * @generated + * @ordered + */ + int MODEL__OTHER_FS_OBJECTS = 1; + + /** + * The number of structural features of the 'Model' class. + * + * + * @generated + * @ordered + */ + int MODEL_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Model' class. + * + * + * @generated + * @ordered + */ + int MODEL_OPERATION_COUNT = 0; + + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem File System}'. + * + * + * @return the meta object for class 'File System'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem + * @generated + */ + EClass getFileSystem(); + + /** + * Returns the meta object for the containment reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getRoot Root}'. + * + * + * @return the meta object for the containment reference 'Root'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getRoot() + * @see #getFileSystem() + * @generated + */ + EReference getFileSystem_Root(); + + /** + * Returns the meta object for the reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getLive Live}'. + * + * + * @return the meta object for the reference list 'Live'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem#getLive() + * @see #getFileSystem() + * @generated + */ + EReference getFileSystem_Live(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject FS Object}'. + * + * + * @return the meta object for class 'FS Object'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject + * @generated + */ + EClass getFSObject(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent Parent}'. + * + * + * @return the meta object for the container reference 'Parent'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject#getParent() + * @see #getFSObject() + * @generated + */ + EReference getFSObject_Parent(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir Dir}'. + * + * + * @return the meta object for class 'Dir'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir + * @generated + */ + EClass getDir(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir#getContents Contents}'. + * + * + * @return the meta object for the containment reference list 'Contents'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir#getContents() + * @see #getDir() + * @generated + */ + EReference getDir_Contents(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File File}'. + * + * + * @return the meta object for class 'File'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File + * @generated + */ + EClass getFile(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model Model}'. + * + * + * @return the meta object for class 'Model'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model + * @generated + */ + EClass getModel(); + + /** + * Returns the meta object for the containment reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getFilesystems Filesystems}'. + * + * + * @return the meta object for the containment reference 'Filesystems'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getFilesystems() + * @see #getModel() + * @generated + */ + EReference getModel_Filesystems(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getOtherFSObjects Other FS Objects}'. + * + * + * @return the meta object for the containment reference list 'Other FS Objects'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model#getOtherFSObjects() + * @see #getModel() + * @generated + */ + EReference getModel_OtherFSObjects(); + + /** + * Returns the factory that creates the instances of the model. + * + * + * @return the factory that creates the instances of the model. + * @generated + */ + filesystemFactory getfilesystemFactory(); + + /** + * + * Defines literals for the meta objects that represent + *
    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl File System}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFileSystem() + * @generated + */ + EClass FILE_SYSTEM = eINSTANCE.getFileSystem(); + + /** + * The meta object literal for the 'Root' containment reference feature. + * + * + * @generated + */ + EReference FILE_SYSTEM__ROOT = eINSTANCE.getFileSystem_Root(); + + /** + * The meta object literal for the 'Live' reference list feature. + * + * + * @generated + */ + EReference FILE_SYSTEM__LIVE = eINSTANCE.getFileSystem_Live(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FSObjectImpl FS Object}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FSObjectImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFSObject() + * @generated + */ + EClass FS_OBJECT = eINSTANCE.getFSObject(); + + /** + * The meta object literal for the 'Parent' container reference feature. + * + * + * @generated + */ + EReference FS_OBJECT__PARENT = eINSTANCE.getFSObject_Parent(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.DirImpl Dir}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.DirImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getDir() + * @generated + */ + EClass DIR = eINSTANCE.getDir(); + + /** + * The meta object literal for the 'Contents' containment reference list feature. + * + * + * @generated + */ + EReference DIR__CONTENTS = eINSTANCE.getDir_Contents(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileImpl File}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getFile() + * @generated + */ + EClass FILE = eINSTANCE.getFile(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl Model}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemPackageImpl#getModel() + * @generated + */ + EClass MODEL = eINSTANCE.getModel(); + + /** + * The meta object literal for the 'Filesystems' containment reference feature. + * + * + * @generated + */ + EReference MODEL__FILESYSTEMS = eINSTANCE.getModel_Filesystems(); + + /** + * The meta object literal for the 'Other FS Objects' containment reference list feature. + * + * + * @generated + */ + EReference MODEL__OTHER_FS_OBJECTS = eINSTANCE.getModel_OtherFSObjects(); + + } + +} //filesystemPackage diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/DirImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/DirImpl.java new file mode 100644 index 00000000..2e2fbcba --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/DirImpl.java @@ -0,0 +1,165 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Dir'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.DirImpl#getContents Contents}
  • + *
+ * + * @generated + */ +public class DirImpl extends FSObjectImpl implements Dir { + /** + * The cached value of the '{@link #getContents() Contents}' containment reference list. + * + * + * @see #getContents() + * @generated + * @ordered + */ + protected EList contents; + + /** + * + * + * @generated + */ + protected DirImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return filesystemPackage.Literals.DIR; + } + + /** + * + * + * @generated + */ + public EList getContents() { + if (contents == null) { + contents = new EObjectContainmentWithInverseEList(FSObject.class, this, filesystemPackage.DIR__CONTENTS, filesystemPackage.FS_OBJECT__PARENT); + } + return contents; + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + return ((InternalEList)(InternalEList)getContents()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + return ((InternalEList)getContents()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + return getContents(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + getContents().clear(); + getContents().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + getContents().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case filesystemPackage.DIR__CONTENTS: + return contents != null && !contents.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //DirImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FSObjectImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FSObjectImpl.java new file mode 100644 index 00000000..25ea1fbb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FSObjectImpl.java @@ -0,0 +1,196 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'FS Object'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FSObjectImpl#getParent Parent}
  • + *
+ * + * @generated + */ +public abstract class FSObjectImpl extends MinimalEObjectImpl.Container implements FSObject { + /** + * + * + * @generated + */ + protected FSObjectImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return filesystemPackage.Literals.FS_OBJECT; + } + + /** + * + * + * @generated + */ + public Dir getParent() { + if (eContainerFeatureID() != filesystemPackage.FS_OBJECT__PARENT) return null; + return (Dir)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetParent(Dir newParent, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newParent, filesystemPackage.FS_OBJECT__PARENT, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setParent(Dir newParent) { + if (newParent != eInternalContainer() || (eContainerFeatureID() != filesystemPackage.FS_OBJECT__PARENT && newParent != null)) { + if (EcoreUtil.isAncestor(this, newParent)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newParent != null) + msgs = ((InternalEObject)newParent).eInverseAdd(this, filesystemPackage.DIR__CONTENTS, Dir.class, msgs); + msgs = basicSetParent(newParent, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, filesystemPackage.FS_OBJECT__PARENT, newParent, newParent)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetParent((Dir)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + return basicSetParent(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case filesystemPackage.FS_OBJECT__PARENT: + return eInternalContainer().eInverseRemove(this, filesystemPackage.DIR__CONTENTS, Dir.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + return getParent(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + setParent((Dir)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + setParent((Dir)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case filesystemPackage.FS_OBJECT__PARENT: + return getParent() != null; + } + return super.eIsSet(featureID); + } + +} //FSObjectImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileImpl.java new file mode 100644 index 00000000..29eb47fd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'File'. + * + * + * @generated + */ +public class FileImpl extends FSObjectImpl implements File { + /** + * + * + * @generated + */ + protected FileImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return filesystemPackage.Literals.FILE; + } + +} //FileImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java new file mode 100644 index 00000000..8bbc6a74 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java @@ -0,0 +1,205 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +/** + * + * An implementation of the model object 'File System'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl#getRoot Root}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl#getLive Live}
  • + *
+ * + * @generated + */ +public class FileSystemImpl extends MinimalEObjectImpl.Container implements FileSystem { + /** + * The cached value of the '{@link #getRoot() Root}' containment reference. + * + * + * @see #getRoot() + * @generated + * @ordered + */ + protected Dir root; + + /** + * The cached setting delegate for the '{@link #getLive() Live}' reference list. + * + * + * @see #getLive() + * @generated + * @ordered + */ + protected EStructuralFeature.Internal.SettingDelegate LIVE__ESETTING_DELEGATE = ((EStructuralFeature.Internal)filesystemPackage.Literals.FILE_SYSTEM__LIVE).getSettingDelegate(); + + /** + * + * + * @generated + */ + protected FileSystemImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return filesystemPackage.Literals.FILE_SYSTEM; + } + + /** + * + * + * @generated + */ + public Dir getRoot() { + return root; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetRoot(Dir newRoot, NotificationChain msgs) { + Dir oldRoot = root; + root = newRoot; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, filesystemPackage.FILE_SYSTEM__ROOT, oldRoot, newRoot); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setRoot(Dir newRoot) { + if (newRoot != root) { + NotificationChain msgs = null; + if (root != null) + msgs = ((InternalEObject)root).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - filesystemPackage.FILE_SYSTEM__ROOT, null, msgs); + if (newRoot != null) + msgs = ((InternalEObject)newRoot).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - filesystemPackage.FILE_SYSTEM__ROOT, null, msgs); + msgs = basicSetRoot(newRoot, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, filesystemPackage.FILE_SYSTEM__ROOT, newRoot, newRoot)); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + public EList getLive() { + return (EList)LIVE__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.FILE_SYSTEM__ROOT: + return basicSetRoot(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case filesystemPackage.FILE_SYSTEM__ROOT: + return getRoot(); + case filesystemPackage.FILE_SYSTEM__LIVE: + return getLive(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case filesystemPackage.FILE_SYSTEM__ROOT: + setRoot((Dir)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case filesystemPackage.FILE_SYSTEM__ROOT: + setRoot((Dir)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case filesystemPackage.FILE_SYSTEM__ROOT: + return root != null; + case filesystemPackage.FILE_SYSTEM__LIVE: + return LIVE__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); + } + return super.eIsSet(featureID); + } + +} //FileSystemImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/ModelImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/ModelImpl.java new file mode 100644 index 00000000..a21f5b6e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/ModelImpl.java @@ -0,0 +1,221 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Model'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl#getFilesystems Filesystems}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.ModelImpl#getOtherFSObjects Other FS Objects}
  • + *
+ * + * @generated + */ +public class ModelImpl extends MinimalEObjectImpl.Container implements Model { + /** + * The cached value of the '{@link #getFilesystems() Filesystems}' containment reference. + * + * + * @see #getFilesystems() + * @generated + * @ordered + */ + protected FileSystem filesystems; + + /** + * The cached value of the '{@link #getOtherFSObjects() Other FS Objects}' containment reference list. + * + * + * @see #getOtherFSObjects() + * @generated + * @ordered + */ + protected EList otherFSObjects; + + /** + * + * + * @generated + */ + protected ModelImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return filesystemPackage.Literals.MODEL; + } + + /** + * + * + * @generated + */ + public FileSystem getFilesystems() { + return filesystems; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetFilesystems(FileSystem newFilesystems, NotificationChain msgs) { + FileSystem oldFilesystems = filesystems; + filesystems = newFilesystems; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, filesystemPackage.MODEL__FILESYSTEMS, oldFilesystems, newFilesystems); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setFilesystems(FileSystem newFilesystems) { + if (newFilesystems != filesystems) { + NotificationChain msgs = null; + if (filesystems != null) + msgs = ((InternalEObject)filesystems).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - filesystemPackage.MODEL__FILESYSTEMS, null, msgs); + if (newFilesystems != null) + msgs = ((InternalEObject)newFilesystems).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - filesystemPackage.MODEL__FILESYSTEMS, null, msgs); + msgs = basicSetFilesystems(newFilesystems, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, filesystemPackage.MODEL__FILESYSTEMS, newFilesystems, newFilesystems)); + } + + /** + * + * + * @generated + */ + public EList getOtherFSObjects() { + if (otherFSObjects == null) { + otherFSObjects = new EObjectContainmentEList(FSObject.class, this, filesystemPackage.MODEL__OTHER_FS_OBJECTS); + } + return otherFSObjects; + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case filesystemPackage.MODEL__FILESYSTEMS: + return basicSetFilesystems(null, msgs); + case filesystemPackage.MODEL__OTHER_FS_OBJECTS: + return ((InternalEList)getOtherFSObjects()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case filesystemPackage.MODEL__FILESYSTEMS: + return getFilesystems(); + case filesystemPackage.MODEL__OTHER_FS_OBJECTS: + return getOtherFSObjects(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case filesystemPackage.MODEL__FILESYSTEMS: + setFilesystems((FileSystem)newValue); + return; + case filesystemPackage.MODEL__OTHER_FS_OBJECTS: + getOtherFSObjects().clear(); + getOtherFSObjects().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case filesystemPackage.MODEL__FILESYSTEMS: + setFilesystems((FileSystem)null); + return; + case filesystemPackage.MODEL__OTHER_FS_OBJECTS: + getOtherFSObjects().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case filesystemPackage.MODEL__FILESYSTEMS: + return filesystems != null; + case filesystemPackage.MODEL__OTHER_FS_OBJECTS: + return otherFSObjects != null && !otherFSObjects.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //ModelImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemFactoryImpl.java new file mode 100644 index 00000000..a3526e36 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemFactoryImpl.java @@ -0,0 +1,128 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.*; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +/** + * + * An implementation of the model Factory. + * + * @generated + */ +public class filesystemFactoryImpl extends EFactoryImpl implements filesystemFactory { + /** + * Creates the default factory implementation. + * + * + * @generated + */ + public static filesystemFactory init() { + try { + filesystemFactory thefilesystemFactory = (filesystemFactory)EPackage.Registry.INSTANCE.getEFactory(filesystemPackage.eNS_URI); + if (thefilesystemFactory != null) { + return thefilesystemFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new filesystemFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * + * + * @generated + */ + public filesystemFactoryImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case filesystemPackage.FILE_SYSTEM: return createFileSystem(); + case filesystemPackage.DIR: return createDir(); + case filesystemPackage.FILE: return createFile(); + case filesystemPackage.MODEL: return createModel(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + public FileSystem createFileSystem() { + FileSystemImpl fileSystem = new FileSystemImpl(); + return fileSystem; + } + + /** + * + * + * @generated + */ + public Dir createDir() { + DirImpl dir = new DirImpl(); + return dir; + } + + /** + * + * + * @generated + */ + public File createFile() { + FileImpl file = new FileImpl(); + return file; + } + + /** + * + * + * @generated + */ + public Model createModel() { + ModelImpl model = new ModelImpl(); + return model; + } + + /** + * + * + * @generated + */ + public filesystemPackage getfilesystemPackage() { + return (filesystemPackage)getEPackage(); + } + + /** + * + * + * @deprecated + * @generated + */ + @Deprecated + public static filesystemPackage getPackage() { + return filesystemPackage.eINSTANCE; + } + +} //filesystemFactoryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java new file mode 100644 index 00000000..5c6dd21e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java @@ -0,0 +1,356 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemFactory; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +/** + * + * An implementation of the model Package. + * + * @generated + */ +public class filesystemPackageImpl extends EPackageImpl implements filesystemPackage { + /** + * + * + * @generated + */ + private EClass fileSystemEClass = null; + + /** + * + * + * @generated + */ + private EClass fsObjectEClass = null; + + /** + * + * + * @generated + */ + private EClass dirEClass = null; + + /** + * + * + * @generated + */ + private EClass fileEClass = null; + + /** + * + * + * @generated + */ + private EClass modelEClass = null; + + /** + * Creates an instance of the model Package, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + *

Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * + * + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#eNS_URI + * @see #init() + * @generated + */ + private filesystemPackageImpl() { + super(eNS_URI, filesystemFactory.eINSTANCE); + } + + /** + * + * + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. + * + *

This method is used to initialize {@link filesystemPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * + * + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static filesystemPackage init() { + if (isInited) return (filesystemPackage)EPackage.Registry.INSTANCE.getEPackage(filesystemPackage.eNS_URI); + + // Obtain or create and register package + filesystemPackageImpl thefilesystemPackage = (filesystemPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof filesystemPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new filesystemPackageImpl()); + + isInited = true; + + // Create package meta-data objects + thefilesystemPackage.createPackageContents(); + + // Initialize created meta-data + thefilesystemPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + thefilesystemPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(filesystemPackage.eNS_URI, thefilesystemPackage); + return thefilesystemPackage; + } + + /** + * + * + * @generated + */ + public EClass getFileSystem() { + return fileSystemEClass; + } + + /** + * + * + * @generated + */ + public EReference getFileSystem_Root() { + return (EReference)fileSystemEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getFileSystem_Live() { + return (EReference)fileSystemEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getFSObject() { + return fsObjectEClass; + } + + /** + * + * + * @generated + */ + public EReference getFSObject_Parent() { + return (EReference)fsObjectEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getDir() { + return dirEClass; + } + + /** + * + * + * @generated + */ + public EReference getDir_Contents() { + return (EReference)dirEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getFile() { + return fileEClass; + } + + /** + * + * + * @generated + */ + public EClass getModel() { + return modelEClass; + } + + /** + * + * + * @generated + */ + public EReference getModel_Filesystems() { + return (EReference)modelEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getModel_OtherFSObjects() { + return (EReference)modelEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public filesystemFactory getfilesystemFactory() { + return (filesystemFactory)getEFactoryInstance(); + } + + /** + * + * + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + fileSystemEClass = createEClass(FILE_SYSTEM); + createEReference(fileSystemEClass, FILE_SYSTEM__ROOT); + createEReference(fileSystemEClass, FILE_SYSTEM__LIVE); + + fsObjectEClass = createEClass(FS_OBJECT); + createEReference(fsObjectEClass, FS_OBJECT__PARENT); + + dirEClass = createEClass(DIR); + createEReference(dirEClass, DIR__CONTENTS); + + fileEClass = createEClass(FILE); + + modelEClass = createEClass(MODEL); + createEReference(modelEClass, MODEL__FILESYSTEMS); + createEReference(modelEClass, MODEL__OTHER_FS_OBJECTS); + } + + /** + * + * + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + dirEClass.getESuperTypes().add(this.getFSObject()); + fileEClass.getESuperTypes().add(this.getFSObject()); + + // Initialize classes, features, and operations; add parameters + initEClass(fileSystemEClass, FileSystem.class, "FileSystem", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFileSystem_Root(), this.getDir(), null, "root", null, 1, 1, FileSystem.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFileSystem_Live(), this.getFSObject(), null, "live", null, 0, -1, FileSystem.class, IS_TRANSIENT, IS_VOLATILE, !IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + + initEClass(fsObjectEClass, FSObject.class, "FSObject", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFSObject_Parent(), this.getDir(), this.getDir_Contents(), "parent", null, 0, 1, FSObject.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(dirEClass, Dir.class, "Dir", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getDir_Contents(), this.getFSObject(), this.getFSObject_Parent(), "contents", null, 0, -1, Dir.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(fileEClass, File.class, "File", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(modelEClass, Model.class, "Model", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getModel_Filesystems(), this.getFileSystem(), null, "filesystems", null, 1, 1, Model.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getModel_OtherFSObjects(), this.getFSObject(), null, "otherFSObjects", null, 0, -1, Model.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + // Create resource + createResource(eNS_URI); + + // Create annotations + // http://www.eclipse.org/emf/2002/Ecore + createEcoreAnnotations(); + // org.eclipse.viatra.query.querybasedfeature + createOrgAnnotations(); + } + + /** + * Initializes the annotations for http://www.eclipse.org/emf/2002/Ecore. + * + * + * @generated + */ + protected void createEcoreAnnotations() { + String source = "http://www.eclipse.org/emf/2002/Ecore"; + addAnnotation + (this, + source, + new String[] { + "settingDelegates", "org.eclipse.viatra.query.querybasedfeature" + }); + } + + /** + * Initializes the annotations for org.eclipse.viatra.query.querybasedfeature. + * + * + * @generated + */ + protected void createOrgAnnotations() { + String source = "org.eclipse.viatra.query.querybasedfeature"; + addAnnotation + (getFileSystem_Live(), + source, + new String[] { + "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live" + }); + } + +} //filesystemPackageImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql new file mode 100644 index 00000000..269a4242 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql @@ -0,0 +1,24 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries + +import epackage "FileSystemMetamodel" + +pattern patternContent(o1: FSObject, o2: FSObject) { + Dir.contents(o1,o2); +} + +@QueryBasedFeature +pattern live(this: FileSystem, l: FSObject) { + FileSystem.root(this,l); +} or { + FileSystem.root(this,root); + find patternContent+(root,l); +} + +@Constraint(key={child}, severity="error", message="error") +pattern contentInNotLive(parent : Dir, child: FSObject) { + Dir.contents(parent,child); + neg find live(_,parent); +} or { + Dir.contents(parent,child); + neg find live(_,child); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemAdapterFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemAdapterFactory.java new file mode 100644 index 00000000..d9aed046 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemAdapterFactory.java @@ -0,0 +1,192 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.*; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * The Adapter Factory for the model. + * It provides an adapter createXXX method for each class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage + * @generated + */ +public class filesystemAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * + * + * @generated + */ + protected static filesystemPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * + * + * @generated + */ + public filesystemAdapterFactory() { + if (modelPackage == null) { + modelPackage = filesystemPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * + * This implementation returns true if the object is either the model's package or is an instance object of the model. + * + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the createXXX methods. + * + * + * @generated + */ + protected filesystemSwitch modelSwitch = + new filesystemSwitch() { + @Override + public Adapter caseFileSystem(FileSystem object) { + return createFileSystemAdapter(); + } + @Override + public Adapter caseFSObject(FSObject object) { + return createFSObjectAdapter(); + } + @Override + public Adapter caseDir(Dir object) { + return createDirAdapter(); + } + @Override + public Adapter caseFile(File object) { + return createFileAdapter(); + } + @Override + public Adapter caseModel(Model object) { + return createModelAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the target. + * + * + * @param target the object to adapt. + * @return the adapter for the target. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem File System}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FileSystem + * @generated + */ + public Adapter createFileSystemAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject FS Object}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.FSObject + * @generated + */ + public Adapter createFSObjectAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir Dir}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir + * @generated + */ + public Adapter createDirAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File File}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File + * @generated + */ + public Adapter createFileAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model Model}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Model + * @generated + */ + public Adapter createModelAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * + * This default implementation returns null. + * + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //filesystemAdapterFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemSwitch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemSwitch.java new file mode 100644 index 00000000..33f4c7a4 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/util/filesystemSwitch.java @@ -0,0 +1,196 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.*; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +/** + * + * The Switch for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the caseXXX method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage + * @generated + */ +public class filesystemSwitch extends Switch { + /** + * The cached model package + * + * + * @generated + */ + protected static filesystemPackage modelPackage; + + /** + * Creates an instance of the switch. + * + * + * @generated + */ + public filesystemSwitch() { + if (modelPackage == null) { + modelPackage = filesystemPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * + * + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. + * + * + * @return the first non-null result returned by a caseXXX call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case filesystemPackage.FILE_SYSTEM: { + FileSystem fileSystem = (FileSystem)theEObject; + T result = caseFileSystem(fileSystem); + if (result == null) result = defaultCase(theEObject); + return result; + } + case filesystemPackage.FS_OBJECT: { + FSObject fsObject = (FSObject)theEObject; + T result = caseFSObject(fsObject); + if (result == null) result = defaultCase(theEObject); + return result; + } + case filesystemPackage.DIR: { + Dir dir = (Dir)theEObject; + T result = caseDir(dir); + if (result == null) result = caseFSObject(dir); + if (result == null) result = defaultCase(theEObject); + return result; + } + case filesystemPackage.FILE: { + File file = (File)theEObject; + T result = caseFile(file); + if (result == null) result = caseFSObject(file); + if (result == null) result = defaultCase(theEObject); + return result; + } + case filesystemPackage.MODEL: { + Model model = (Model)theEObject; + T result = caseModel(model); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of 'File System'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'File System'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFileSystem(FileSystem object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'FS Object'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'FS Object'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFSObject(FSObject object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Dir'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Dir'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseDir(Dir object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'File'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'File'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFile(File object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Model'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Model'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseModel(Model object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'EObject'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'EObject'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //filesystemSwitch diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java new file mode 100644 index 00000000..cc4049c4 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Choice'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getChoice() + * @model + * @generated + */ +public interface Choice extends Pseudostate { +} // Choice diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java new file mode 100644 index 00000000..037b1b3c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Composite Element'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions Regions}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getCompositeElement() + * @model abstract="true" + * @generated + */ +public interface CompositeElement extends EObject { + /** + * Returns the value of the 'Regions' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region}. + * + *

+ * If the meaning of the 'Regions' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Regions' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getCompositeElement_Regions() + * @model containment="true" + * @generated + */ + EList getRegions(); + +} // CompositeElement diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java new file mode 100644 index 00000000..da40c481 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Entry'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getEntry() + * @model + * @generated + */ +public interface Entry extends Pseudostate { +} // Entry diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java new file mode 100644 index 00000000..9f8e12d3 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Exit'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getExit() + * @model + * @generated + */ +public interface Exit extends Pseudostate { +} // Exit diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java new file mode 100644 index 00000000..33703d36 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Final State'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getFinalState() + * @model + * @generated + */ +public interface FinalState extends RegularState { +} // FinalState diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java new file mode 100644 index 00000000..e6a003f9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Pseudostate'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getPseudostate() + * @model abstract="true" + * @generated + */ +public interface Pseudostate extends Vertex { +} // Pseudostate diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java new file mode 100644 index 00000000..f4c3f114 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java @@ -0,0 +1,42 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Region'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices Vertices}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegion() + * @model + * @generated + */ +public interface Region extends EObject { + /** + * Returns the value of the 'Vertices' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex}. + * + *

+ * If the meaning of the 'Vertices' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Vertices' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegion_Vertices() + * @model containment="true" ordered="false" + * @generated + */ + EList getVertices(); + +} // Region diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java new file mode 100644 index 00000000..7db584e5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Regular State'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegularState() + * @model abstract="true" + * @generated + */ +public interface RegularState extends Vertex { +} // RegularState diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java new file mode 100644 index 00000000..3c65be40 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'State'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getState() + * @model + * @generated + */ +public interface State extends RegularState, CompositeElement { +} // State diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java new file mode 100644 index 00000000..33a1dd7a --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Statechart'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getStatechart() + * @model + * @generated + */ +public interface Statechart extends CompositeElement { +} // Statechart diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java new file mode 100644 index 00000000..f1294200 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java @@ -0,0 +1,17 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + + +/** + * + * A representation of the model object 'Synchronization'. + * + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getSynchronization() + * @model + * @generated + */ +public interface Synchronization extends Pseudostate { +} // Synchronization diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java new file mode 100644 index 00000000..543cc73b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java @@ -0,0 +1,81 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Transition'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition() + * @model + * @generated + */ +public interface Transition extends EObject { + /** + * Returns the value of the 'Target' reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions Incoming Transitions}'. + * + *

+ * If the meaning of the 'Target' reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Target' reference. + * @see #setTarget(Vertex) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition_Target() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions + * @model opposite="incomingTransitions" required="true" ordered="false" + * @generated + */ + Vertex getTarget(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}' reference. + * + * + * @param value the new value of the 'Target' reference. + * @see #getTarget() + * @generated + */ + void setTarget(Vertex value); + + /** + * Returns the value of the 'Source' container reference. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}'. + * + *

+ * If the meaning of the 'Source' container reference isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Source' container reference. + * @see #setSource(Vertex) + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition_Source() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions + * @model opposite="outgoingTransitions" transient="false" ordered="false" + * @generated + */ + Vertex getSource(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}' container reference. + * + * + * @param value the new value of the 'Source' container reference. + * @see #getSource() + * @generated + */ + void setSource(Vertex value); + +} // Transition diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java new file mode 100644 index 00000000..6005a550 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java @@ -0,0 +1,63 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * A representation of the model object 'Vertex'. + * + * + *

+ * The following features are supported: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions Incoming Transitions}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex() + * @model abstract="true" + * @generated + */ +public interface Vertex extends EObject { + /** + * Returns the value of the 'Incoming Transitions' reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}'. + * + *

+ * If the meaning of the 'Incoming Transitions' reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Incoming Transitions' reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex_IncomingTransitions() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget + * @model opposite="target" ordered="false" + * @generated + */ + EList getIncomingTransitions(); + + /** + * Returns the value of the 'Outgoing Transitions' containment reference list. + * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition}. + * It is bidirectional and its opposite is '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}'. + * + *

+ * If the meaning of the 'Outgoing Transitions' containment reference list isn't clear, + * there really should be more of a description here... + *

+ * + * @return the value of the 'Outgoing Transitions' containment reference list. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex_OutgoingTransitions() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource + * @model opposite="source" containment="true" ordered="false" + * @generated + */ + EList getOutgoingTransitions(); + +} // Vertex diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java new file mode 100644 index 00000000..8fc4883b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Choice'. + * + * + * @generated + */ +public class ChoiceImpl extends PseudostateImpl implements Choice { + /** + * + * + * @generated + */ + protected ChoiceImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.CHOICE; + } + +} //ChoiceImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java new file mode 100644 index 00000000..0218f9c7 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java @@ -0,0 +1,152 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Composite Element'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl#getRegions Regions}
  • + *
+ * + * @generated + */ +public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container implements CompositeElement { + /** + * The cached value of the '{@link #getRegions() Regions}' containment reference list. + * + * + * @see #getRegions() + * @generated + * @ordered + */ + protected EList regions; + + /** + * + * + * @generated + */ + protected CompositeElementImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.COMPOSITE_ELEMENT; + } + + /** + * + * + * @generated + */ + public EList getRegions() { + if (regions == null) { + regions = new EObjectContainmentEList(Region.class, this, yakinduPackage.COMPOSITE_ELEMENT__REGIONS); + } + return regions; + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + return ((InternalEList)getRegions()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + return getRegions(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + getRegions().clear(); + getRegions().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + getRegions().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + return regions != null && !regions.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //CompositeElementImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java new file mode 100644 index 00000000..d0334475 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Entry'. + * + * + * @generated + */ +public class EntryImpl extends PseudostateImpl implements Entry { + /** + * + * + * @generated + */ + protected EntryImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.ENTRY; + } + +} //EntryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java new file mode 100644 index 00000000..d1448776 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Exit'. + * + * + * @generated + */ +public class ExitImpl extends PseudostateImpl implements Exit { + /** + * + * + * @generated + */ + protected ExitImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.EXIT; + } + +} //ExitImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java new file mode 100644 index 00000000..716c096e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Final State'. + * + * + * @generated + */ +public class FinalStateImpl extends RegularStateImpl implements FinalState { + /** + * + * + * @generated + */ + protected FinalStateImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.FINAL_STATE; + } + +} //FinalStateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java new file mode 100644 index 00000000..b9fc27f3 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Pseudostate'. + * + * + * @generated + */ +public abstract class PseudostateImpl extends VertexImpl implements Pseudostate { + /** + * + * + * @generated + */ + protected PseudostateImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.PSEUDOSTATE; + } + +} //PseudostateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java new file mode 100644 index 00000000..fa873aeb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java @@ -0,0 +1,152 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Region'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl#getVertices Vertices}
  • + *
+ * + * @generated + */ +public class RegionImpl extends MinimalEObjectImpl.Container implements Region { + /** + * The cached value of the '{@link #getVertices() Vertices}' containment reference list. + * + * + * @see #getVertices() + * @generated + * @ordered + */ + protected EList vertices; + + /** + * + * + * @generated + */ + protected RegionImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.REGION; + } + + /** + * + * + * @generated + */ + public EList getVertices() { + if (vertices == null) { + vertices = new EObjectContainmentEList(Vertex.class, this, yakinduPackage.REGION__VERTICES); + } + return vertices; + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.REGION__VERTICES: + return ((InternalEList)getVertices()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case yakinduPackage.REGION__VERTICES: + return getVertices(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case yakinduPackage.REGION__VERTICES: + getVertices().clear(); + getVertices().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case yakinduPackage.REGION__VERTICES: + getVertices().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case yakinduPackage.REGION__VERTICES: + return vertices != null && !vertices.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //RegionImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java new file mode 100644 index 00000000..bbe21a14 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Regular State'. + * + * + * @generated + */ +public abstract class RegularStateImpl extends VertexImpl implements RegularState { + /** + * + * + * @generated + */ + protected RegularStateImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.REGULAR_STATE; + } + +} //RegularStateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java new file mode 100644 index 00000000..66ab2a8f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java @@ -0,0 +1,183 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.util.EObjectContainmentEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'State'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl#getRegions Regions}
  • + *
+ * + * @generated + */ +public class StateImpl extends RegularStateImpl implements State { + /** + * The cached value of the '{@link #getRegions() Regions}' containment reference list. + * + * + * @see #getRegions() + * @generated + * @ordered + */ + protected EList regions; + + /** + * + * + * @generated + */ + protected StateImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.STATE; + } + + /** + * + * + * @generated + */ + public EList getRegions() { + if (regions == null) { + regions = new EObjectContainmentEList(Region.class, this, yakinduPackage.STATE__REGIONS); + } + return regions; + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.STATE__REGIONS: + return ((InternalEList)getRegions()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case yakinduPackage.STATE__REGIONS: + return getRegions(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case yakinduPackage.STATE__REGIONS: + getRegions().clear(); + getRegions().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case yakinduPackage.STATE__REGIONS: + getRegions().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case yakinduPackage.STATE__REGIONS: + return regions != null && !regions.isEmpty(); + } + return super.eIsSet(featureID); + } + + /** + * + * + * @generated + */ + @Override + public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { + if (baseClass == CompositeElement.class) { + switch (derivedFeatureID) { + case yakinduPackage.STATE__REGIONS: return yakinduPackage.COMPOSITE_ELEMENT__REGIONS; + default: return -1; + } + } + return super.eBaseStructuralFeatureID(derivedFeatureID, baseClass); + } + + /** + * + * + * @generated + */ + @Override + public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { + if (baseClass == CompositeElement.class) { + switch (baseFeatureID) { + case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: return yakinduPackage.STATE__REGIONS; + default: return -1; + } + } + return super.eDerivedStructuralFeatureID(baseFeatureID, baseClass); + } + +} //StateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java new file mode 100644 index 00000000..056820ca --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Statechart'. + * + * + * @generated + */ +public class StatechartImpl extends CompositeElementImpl implements Statechart { + /** + * + * + * @generated + */ + protected StatechartImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.STATECHART; + } + +} //StatechartImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java new file mode 100644 index 00000000..28ef69ea --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java @@ -0,0 +1,37 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * + * An implementation of the model object 'Synchronization'. + * + * + * @generated + */ +public class SynchronizationImpl extends PseudostateImpl implements Synchronization { + /** + * + * + * @generated + */ + protected SynchronizationImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.SYNCHRONIZATION; + } + +} //SynchronizationImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java new file mode 100644 index 00000000..ea1677ee --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java @@ -0,0 +1,284 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.ENotificationImpl; +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EcoreUtil; + +/** + * + * An implementation of the model object 'Transition'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl#getTarget Target}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl#getSource Source}
  • + *
+ * + * @generated + */ +public class TransitionImpl extends MinimalEObjectImpl.Container implements Transition { + /** + * The cached value of the '{@link #getTarget() Target}' reference. + * + * + * @see #getTarget() + * @generated + * @ordered + */ + protected Vertex target; + + /** + * + * + * @generated + */ + protected TransitionImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.TRANSITION; + } + + /** + * + * + * @generated + */ + public Vertex getTarget() { + if (target != null && target.eIsProxy()) { + InternalEObject oldTarget = (InternalEObject)target; + target = (Vertex)eResolveProxy(oldTarget); + if (target != oldTarget) { + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.RESOLVE, yakinduPackage.TRANSITION__TARGET, oldTarget, target)); + } + } + return target; + } + + /** + * + * + * @generated + */ + public Vertex basicGetTarget() { + return target; + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetTarget(Vertex newTarget, NotificationChain msgs) { + Vertex oldTarget = target; + target = newTarget; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__TARGET, oldTarget, newTarget); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; + } + + /** + * + * + * @generated + */ + public void setTarget(Vertex newTarget) { + if (newTarget != target) { + NotificationChain msgs = null; + if (target != null) + msgs = ((InternalEObject)target).eInverseRemove(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + if (newTarget != null) + msgs = ((InternalEObject)newTarget).eInverseAdd(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + msgs = basicSetTarget(newTarget, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__TARGET, newTarget, newTarget)); + } + + /** + * + * + * @generated + */ + public Vertex getSource() { + if (eContainerFeatureID() != yakinduPackage.TRANSITION__SOURCE) return null; + return (Vertex)eInternalContainer(); + } + + /** + * + * + * @generated + */ + public NotificationChain basicSetSource(Vertex newSource, NotificationChain msgs) { + msgs = eBasicSetContainer((InternalEObject)newSource, yakinduPackage.TRANSITION__SOURCE, msgs); + return msgs; + } + + /** + * + * + * @generated + */ + public void setSource(Vertex newSource) { + if (newSource != eInternalContainer() || (eContainerFeatureID() != yakinduPackage.TRANSITION__SOURCE && newSource != null)) { + if (EcoreUtil.isAncestor(this, newSource)) + throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); + NotificationChain msgs = null; + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + if (newSource != null) + msgs = ((InternalEObject)newSource).eInverseAdd(this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); + msgs = basicSetSource(newSource, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__SOURCE, newSource, newSource)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + if (target != null) + msgs = ((InternalEObject)target).eInverseRemove(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + return basicSetTarget((Vertex)otherEnd, msgs); + case yakinduPackage.TRANSITION__SOURCE: + if (eInternalContainer() != null) + msgs = eBasicRemoveFromContainer(msgs); + return basicSetSource((Vertex)otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + return basicSetTarget(null, msgs); + case yakinduPackage.TRANSITION__SOURCE: + return basicSetSource(null, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { + switch (eContainerFeatureID()) { + case yakinduPackage.TRANSITION__SOURCE: + return eInternalContainer().eInverseRemove(this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); + } + return super.eBasicRemoveFromContainerFeature(msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + if (resolve) return getTarget(); + return basicGetTarget(); + case yakinduPackage.TRANSITION__SOURCE: + return getSource(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + setTarget((Vertex)newValue); + return; + case yakinduPackage.TRANSITION__SOURCE: + setSource((Vertex)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + setTarget((Vertex)null); + return; + case yakinduPackage.TRANSITION__SOURCE: + setSource((Vertex)null); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case yakinduPackage.TRANSITION__TARGET: + return target != null; + case yakinduPackage.TRANSITION__SOURCE: + return getSource() != null; + } + return super.eIsSet(featureID); + } + +} //TransitionImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java new file mode 100644 index 00000000..6f5b9ed3 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java @@ -0,0 +1,206 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import java.util.Collection; + +import org.eclipse.emf.common.notify.NotificationChain; + +import org.eclipse.emf.common.util.EList; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.InternalEObject; + +import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; + +import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList; +import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; +import org.eclipse.emf.ecore.util.InternalEList; + +/** + * + * An implementation of the model object 'Vertex'. + * + *

+ * The following features are implemented: + *

+ *
    + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl#getIncomingTransitions Incoming Transitions}
  • + *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl#getOutgoingTransitions Outgoing Transitions}
  • + *
+ * + * @generated + */ +public abstract class VertexImpl extends MinimalEObjectImpl.Container implements Vertex { + /** + * The cached value of the '{@link #getIncomingTransitions() Incoming Transitions}' reference list. + * + * + * @see #getIncomingTransitions() + * @generated + * @ordered + */ + protected EList incomingTransitions; + + /** + * The cached value of the '{@link #getOutgoingTransitions() Outgoing Transitions}' containment reference list. + * + * + * @see #getOutgoingTransitions() + * @generated + * @ordered + */ + protected EList outgoingTransitions; + + /** + * + * + * @generated + */ + protected VertexImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + protected EClass eStaticClass() { + return yakinduPackage.Literals.VERTEX; + } + + /** + * + * + * @generated + */ + public EList getIncomingTransitions() { + if (incomingTransitions == null) { + incomingTransitions = new EObjectWithInverseResolvingEList(Transition.class, this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, yakinduPackage.TRANSITION__TARGET); + } + return incomingTransitions; + } + + /** + * + * + * @generated + */ + public EList getOutgoingTransitions() { + if (outgoingTransitions == null) { + outgoingTransitions = new EObjectContainmentWithInverseEList(Transition.class, this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, yakinduPackage.TRANSITION__SOURCE); + } + return outgoingTransitions; + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + return ((InternalEList)(InternalEList)getIncomingTransitions()).basicAdd(otherEnd, msgs); + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + return ((InternalEList)(InternalEList)getOutgoingTransitions()).basicAdd(otherEnd, msgs); + } + return super.eInverseAdd(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + return ((InternalEList)getIncomingTransitions()).basicRemove(otherEnd, msgs); + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + return ((InternalEList)getOutgoingTransitions()).basicRemove(otherEnd, msgs); + } + return super.eInverseRemove(otherEnd, featureID, msgs); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + return getIncomingTransitions(); + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + return getOutgoingTransitions(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @SuppressWarnings("unchecked") + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + getIncomingTransitions().clear(); + getIncomingTransitions().addAll((Collection)newValue); + return; + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + getOutgoingTransitions().clear(); + getOutgoingTransitions().addAll((Collection)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + getIncomingTransitions().clear(); + return; + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + getOutgoingTransitions().clear(); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + return incomingTransitions != null && !incomingTransitions.isEmpty(); + case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + return outgoingTransitions != null && !outgoingTransitions.isEmpty(); + } + return super.eIsSet(featureID); + } + +} //VertexImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java new file mode 100644 index 00000000..5d004565 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java @@ -0,0 +1,183 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +/** + * + * An implementation of the model Factory. + * + * @generated + */ +public class yakinduFactoryImpl extends EFactoryImpl implements yakinduFactory { + /** + * Creates the default factory implementation. + * + * + * @generated + */ + public static yakinduFactory init() { + try { + yakinduFactory theyakinduFactory = (yakinduFactory)EPackage.Registry.INSTANCE.getEFactory(yakinduPackage.eNS_URI); + if (theyakinduFactory != null) { + return theyakinduFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new yakinduFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * + * + * @generated + */ + public yakinduFactoryImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case yakinduPackage.REGION: return createRegion(); + case yakinduPackage.TRANSITION: return createTransition(); + case yakinduPackage.STATECHART: return createStatechart(); + case yakinduPackage.ENTRY: return createEntry(); + case yakinduPackage.SYNCHRONIZATION: return createSynchronization(); + case yakinduPackage.STATE: return createState(); + case yakinduPackage.CHOICE: return createChoice(); + case yakinduPackage.EXIT: return createExit(); + case yakinduPackage.FINAL_STATE: return createFinalState(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + public Region createRegion() { + RegionImpl region = new RegionImpl(); + return region; + } + + /** + * + * + * @generated + */ + public Transition createTransition() { + TransitionImpl transition = new TransitionImpl(); + return transition; + } + + /** + * + * + * @generated + */ + public Statechart createStatechart() { + StatechartImpl statechart = new StatechartImpl(); + return statechart; + } + + /** + * + * + * @generated + */ + public Entry createEntry() { + EntryImpl entry = new EntryImpl(); + return entry; + } + + /** + * + * + * @generated + */ + public Synchronization createSynchronization() { + SynchronizationImpl synchronization = new SynchronizationImpl(); + return synchronization; + } + + /** + * + * + * @generated + */ + public State createState() { + StateImpl state = new StateImpl(); + return state; + } + + /** + * + * + * @generated + */ + public Choice createChoice() { + ChoiceImpl choice = new ChoiceImpl(); + return choice; + } + + /** + * + * + * @generated + */ + public Exit createExit() { + ExitImpl exit = new ExitImpl(); + return exit; + } + + /** + * + * + * @generated + */ + public FinalState createFinalState() { + FinalStateImpl finalState = new FinalStateImpl(); + return finalState; + } + + /** + * + * + * @generated + */ + public yakinduPackage getyakinduPackage() { + return (yakinduPackage)getEPackage(); + } + + /** + * + * + * @deprecated + * @generated + */ + @Deprecated + public static yakinduPackage getPackage() { + return yakinduPackage.eINSTANCE; + } + +} //yakinduFactoryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java new file mode 100644 index 00000000..2213e07f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java @@ -0,0 +1,494 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduFactory; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +/** + * + * An implementation of the model Package. + * + * @generated + */ +public class yakinduPackageImpl extends EPackageImpl implements yakinduPackage { + /** + * + * + * @generated + */ + private EClass pseudostateEClass = null; + + /** + * + * + * @generated + */ + private EClass vertexEClass = null; + + /** + * + * + * @generated + */ + private EClass regionEClass = null; + + /** + * + * + * @generated + */ + private EClass transitionEClass = null; + + /** + * + * + * @generated + */ + private EClass statechartEClass = null; + + /** + * + * + * @generated + */ + private EClass entryEClass = null; + + /** + * + * + * @generated + */ + private EClass synchronizationEClass = null; + + /** + * + * + * @generated + */ + private EClass stateEClass = null; + + /** + * + * + * @generated + */ + private EClass regularStateEClass = null; + + /** + * + * + * @generated + */ + private EClass compositeElementEClass = null; + + /** + * + * + * @generated + */ + private EClass choiceEClass = null; + + /** + * + * + * @generated + */ + private EClass exitEClass = null; + + /** + * + * + * @generated + */ + private EClass finalStateEClass = null; + + /** + * Creates an instance of the model Package, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + *

Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * + * + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#eNS_URI + * @see #init() + * @generated + */ + private yakinduPackageImpl() { + super(eNS_URI, yakinduFactory.eINSTANCE); + } + + /** + * + * + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. + * + *

This method is used to initialize {@link yakinduPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * + * + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static yakinduPackage init() { + if (isInited) return (yakinduPackage)EPackage.Registry.INSTANCE.getEPackage(yakinduPackage.eNS_URI); + + // Obtain or create and register package + yakinduPackageImpl theyakinduPackage = (yakinduPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof yakinduPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new yakinduPackageImpl()); + + isInited = true; + + // Create package meta-data objects + theyakinduPackage.createPackageContents(); + + // Initialize created meta-data + theyakinduPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theyakinduPackage.freeze(); + + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(yakinduPackage.eNS_URI, theyakinduPackage); + return theyakinduPackage; + } + + /** + * + * + * @generated + */ + public EClass getPseudostate() { + return pseudostateEClass; + } + + /** + * + * + * @generated + */ + public EClass getVertex() { + return vertexEClass; + } + + /** + * + * + * @generated + */ + public EReference getVertex_IncomingTransitions() { + return (EReference)vertexEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getVertex_OutgoingTransitions() { + return (EReference)vertexEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getRegion() { + return regionEClass; + } + + /** + * + * + * @generated + */ + public EReference getRegion_Vertices() { + return (EReference)regionEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getTransition() { + return transitionEClass; + } + + /** + * + * + * @generated + */ + public EReference getTransition_Target() { + return (EReference)transitionEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getTransition_Source() { + return (EReference)transitionEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getStatechart() { + return statechartEClass; + } + + /** + * + * + * @generated + */ + public EClass getEntry() { + return entryEClass; + } + + /** + * + * + * @generated + */ + public EClass getSynchronization() { + return synchronizationEClass; + } + + /** + * + * + * @generated + */ + public EClass getState() { + return stateEClass; + } + + /** + * + * + * @generated + */ + public EClass getRegularState() { + return regularStateEClass; + } + + /** + * + * + * @generated + */ + public EClass getCompositeElement() { + return compositeElementEClass; + } + + /** + * + * + * @generated + */ + public EReference getCompositeElement_Regions() { + return (EReference)compositeElementEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getChoice() { + return choiceEClass; + } + + /** + * + * + * @generated + */ + public EClass getExit() { + return exitEClass; + } + + /** + * + * + * @generated + */ + public EClass getFinalState() { + return finalStateEClass; + } + + /** + * + * + * @generated + */ + public yakinduFactory getyakinduFactory() { + return (yakinduFactory)getEFactoryInstance(); + } + + /** + * + * + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + pseudostateEClass = createEClass(PSEUDOSTATE); + + vertexEClass = createEClass(VERTEX); + createEReference(vertexEClass, VERTEX__INCOMING_TRANSITIONS); + createEReference(vertexEClass, VERTEX__OUTGOING_TRANSITIONS); + + regionEClass = createEClass(REGION); + createEReference(regionEClass, REGION__VERTICES); + + transitionEClass = createEClass(TRANSITION); + createEReference(transitionEClass, TRANSITION__TARGET); + createEReference(transitionEClass, TRANSITION__SOURCE); + + statechartEClass = createEClass(STATECHART); + + entryEClass = createEClass(ENTRY); + + synchronizationEClass = createEClass(SYNCHRONIZATION); + + stateEClass = createEClass(STATE); + + regularStateEClass = createEClass(REGULAR_STATE); + + compositeElementEClass = createEClass(COMPOSITE_ELEMENT); + createEReference(compositeElementEClass, COMPOSITE_ELEMENT__REGIONS); + + choiceEClass = createEClass(CHOICE); + + exitEClass = createEClass(EXIT); + + finalStateEClass = createEClass(FINAL_STATE); + } + + /** + * + * + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + pseudostateEClass.getESuperTypes().add(this.getVertex()); + statechartEClass.getESuperTypes().add(this.getCompositeElement()); + entryEClass.getESuperTypes().add(this.getPseudostate()); + synchronizationEClass.getESuperTypes().add(this.getPseudostate()); + stateEClass.getESuperTypes().add(this.getRegularState()); + stateEClass.getESuperTypes().add(this.getCompositeElement()); + regularStateEClass.getESuperTypes().add(this.getVertex()); + choiceEClass.getESuperTypes().add(this.getPseudostate()); + exitEClass.getESuperTypes().add(this.getPseudostate()); + finalStateEClass.getESuperTypes().add(this.getRegularState()); + + // Initialize classes, features, and operations; add parameters + initEClass(pseudostateEClass, Pseudostate.class, "Pseudostate", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(vertexEClass, Vertex.class, "Vertex", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getVertex_IncomingTransitions(), this.getTransition(), this.getTransition_Target(), "incomingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getVertex_OutgoingTransitions(), this.getTransition(), this.getTransition_Source(), "outgoingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(regionEClass, Region.class, "Region", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getRegion_Vertices(), this.getVertex(), null, "vertices", null, 0, -1, Region.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(transitionEClass, Transition.class, "Transition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getTransition_Target(), this.getVertex(), this.getVertex_IncomingTransitions(), "target", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getTransition_Source(), this.getVertex(), this.getVertex_OutgoingTransitions(), "source", null, 0, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(statechartEClass, Statechart.class, "Statechart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(entryEClass, Entry.class, "Entry", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(synchronizationEClass, Synchronization.class, "Synchronization", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(stateEClass, State.class, "State", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(regularStateEClass, RegularState.class, "RegularState", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(compositeElementEClass, CompositeElement.class, "CompositeElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getCompositeElement_Regions(), this.getRegion(), null, "regions", null, 0, -1, CompositeElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(choiceEClass, Choice.class, "Choice", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(exitEClass, Exit.class, "Exit", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(finalStateEClass, FinalState.class, "FinalState", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + // Create resource + createResource(eNS_URI); + } + +} //yakinduPackageImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql new file mode 100644 index 00000000..2e498670 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql @@ -0,0 +1,270 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries + +import epackage "YakinduMetamodel" + +///////// +// Entry +///////// + +pattern entryInRegion_M0(r1 : Region, e1 : Entry) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M1(r1 : Region, e1) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M2(r1 : Region, e1: Entry) { + // For positive constraint + Region(r1);Entry(e1); +} + + +//@Constraint(severity="error", message="error", key = {r1}) +pattern noEntryInRegion_M0(r1 : Region) { + neg find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M1(r1 : Region) { + neg find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M2(r1 : Region) { + neg find entryInRegion_M2(r1, _); +} +pattern noEntryInRegion_M3(r1 : Region) { + find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M4(r1 : Region) { + find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M5(r1 : Region) { + find entryInRegion_M2(r1, _); +} + +//@Constraint(severity="error", message="error", key = {r}) +pattern multipleEntryInRegion_M0(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M1(r : Region) { + find entryInRegion_M1(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M2(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M3(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M1(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M4(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M2(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M5(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); +} + + +pattern transition_M0(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t, trg); +} +pattern transition_M1(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Vertex(trg); +} +pattern transition_M2(t : Transition, src : Vertex, trg : Vertex) { + Vertex(src); + Transition.target(t, trg); +} +pattern transition_M3(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t_x, src); + Transition.target(t, trg); +} +pattern transition_M4(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t_x, trg); +} + +//@Constraint(severity="error", message="error", key = {e}) +pattern incomingToEntry_M0(t : Transition, e : Entry) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_1(t : Transition, e) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_2(t : Transition, e : Entry) { + find transition_M1(t, _, e); +} +pattern incomingToEntry_3(t : Transition, e : Entry) { + find transition_M2(t, _, e); +} +pattern incomingToEntry_4(t : Transition, e : Entry) { + find transition_M3(t, _, e); +} +pattern incomingToEntry_5(t : Transition, e : Entry) { + find transition_M4(t, _, e); +} + +pattern noOutgoingTransitionFromEntry_M0(e : Entry) { + neg find transition_M0(_, e, _); +} + +pattern noOutgoingTransitionFromEntry_M1(e) { + Vertex(e); + neg find transition_M0(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M2(e : Entry) { + neg find transition_M1(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M3(e : Entry) { + neg find transition_M2(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M4(e : Entry) { + neg find transition_M3(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M5(e : Entry) { + neg find transition_M4(_, e, _); +} + + +//@Constraint(severity="error", message="error", key = {e}) +pattern multipleTransitionFromEntry_M0(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M1(e, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M2(e : Entry, t1 : Transition, t2: Transition) { + Transition(t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M3(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Transition(t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M4(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); +} + +///////// +// Exit +///////// + +//@Constraint(severity="error", message="error", key = {e}) +pattern outgoingFromExit_M0(t : Transition, e : Exit) { + Exit.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M1(t : Transition, e) { + Vertex.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M2(t : Transition, e : Exit) { + Transition(t); + Exit(e); +} + +///////// +// Final +///////// + +//@Constraint(severity="error", message="error", key = {f}) +pattern outgoingFromFinal_M0(t : Transition, f : FinalState) { + FinalState.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M1(t : Transition, f) { + Vertex.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M2(t : Transition, f : FinalState) { + Transition(t); + FinalState(f); +} + +///////// +// State vs Region +///////// + +//@Constraint(severity="error", message="error", key = {region}) +pattern noStateInRegion_M0(region: Region) { + neg find StateInRegion_M0(region,_); +} +pattern noStateInRegion_M1(region: Region) { + neg find StateInRegion_M1(region,_); +} +pattern noStateInRegion_M2(region: Region) { + neg find StateInRegion_M2(region,_); +} +pattern noStateInRegion_M3(region: Region) { + find StateInRegion_M0(region,_); +} + +pattern StateInRegion_M0(region: Region, state: State) { + Region.vertices(region,state); +} +pattern StateInRegion_M1(region: Region, state) { + Region.vertices(region,state); +} +pattern StateInRegion_M2(region: Region, state:State) { + Region(region);State(state); +} + +///////// +// Choice +///////// + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoOutgoing_M0(c : Choice) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M1(c:Vertex) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M2(c : Choice) { + neg find transition_M1(_, c, _); +} +pattern choiceHasNoOutgoing_M3(c : Choice) { + neg find transition_M2(_, c, _); +} +pattern choiceHasNoOutgoing_M4(c : Choice) { + neg find transition_M3(_, c, _); +} +pattern choiceHasNoOutgoing_M5(c : Choice) { + neg find transition_M4(_, c, _); +} +pattern choiceHasNoOutgoing_M6(c : Choice) { + find transition_M0(_, c, _); +} + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoIncoming_M0(c: Choice) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M1(c:Vertex) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M2(c: Choice) { + neg find transition_M1(_, _, c); +} +pattern choiceHasNoIncoming_M3(c: Choice) { + neg find transition_M2(_, _, c); +} +pattern choiceHasNoIncoming_M4(c: Choice) { + neg find transition_M3(_, _, c); +} +pattern choiceHasNoIncoming_M5(c: Choice) { + neg find transition_M4(_, _, c); +} +pattern choiceHasNoIncoming_M6(c: Choice) { + find transition_M0(_, _, c); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql new file mode 100644 index 00000000..597b1691 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql @@ -0,0 +1,227 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries + +import epackage "YakinduMetamodel" + +///////// +// Entry +///////// + +pattern entryInRegion(r1 : Region, e1 : Entry) { + Region.vertices(r1, e1); +} + +@Constraint(severity="error", message="error", key = {r1}) +pattern noEntryInRegion(r1 : Region) { + neg find entryInRegion(r1, _); +} + +@Constraint(severity="error", message="error", key = {r}) +pattern multipleEntryInRegion(r : Region) { + find entryInRegion(r, e1); + find entryInRegion(r, e2); + e1 != e2; +} + +pattern transition(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t, trg); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern incomingToEntry(t : Transition, e : Entry) { + find transition(t, _, e); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern noOutgoingTransitionFromEntry(e : Entry) { + neg find transition(_, e, _); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} + +///////// +// Exit +///////// + +@Constraint(severity="error", message="error", key = {e}) +pattern outgoingFromExit(t : Transition, e : Exit) { + Exit.outgoingTransitions(e,t); +} + +///////// +// Final +///////// + +@Constraint(severity="error", message="error", key = {f}) +pattern outgoingFromFinal(t : Transition, f : FinalState) { + FinalState.outgoingTransitions(f,t); +} + +///////// +// State vs Region +///////// + +@Constraint(severity="error", message="error", key = {region}) +pattern noStateInRegion(region: Region) { + neg find StateInRegion(region,_); +} +pattern StateInRegion(region: Region, state: State) { + Region.vertices(region,state); +} + +///////// +// Choice +///////// + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoOutgoing(c : Choice) { + neg find transition(_, c, _); +} + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoIncoming(c: Choice) { + neg find transition(_, _, c); +} + +///////// +// Synchronization +///////// + +@Constraint(severity="error", message="error", key = {s}) +pattern synchHasNoOutgoing(s : Synchronization) { + neg find transition(_, s, _); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern synchHasNoIncoming(s : Synchronization) { + neg find transition(_, _, s); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) { + find transition(t1, v1, s); + find transition(t2, v2, s); + t1!=t2; + Region.vertices(r, v1); + Region.vertices(r, v2); +} or { + find transition(t1, s, v1); + find transition(t2, s, v2); + t1!=t2; + Region.vertices(r, v1); + Region.vertices(r, v2); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern notSynchronizingStates(s : Synchronization) { + neg find hasMultipleOutgoingTrainsition(s); + neg find hasMultipleIncomingTrainsition(s); +} + +pattern hasMultipleOutgoingTrainsition(v : Synchronization) { + find transition(_, v, trg1); + find transition(_, v, trg2); + trg1 != trg2; +} + +pattern hasMultipleIncomingTrainsition(v : Synchronization) { + find transition(_, src1, v); + find transition(_, src2, v); + src1 != src2; +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) { + find transition(_, v1, s); + find transition(_, v2, s); + CompositeElement.regions.vertices(r1, v1); + CompositeElement.regions.vertices(r2, v2); + r1 != r2; +} or { + find transition(_, s, v1); + find transition(_, s, v2); + CompositeElement.regions.vertices(r1, v1); + CompositeElement.regions.vertices(r2, v2); + r1 != r2; +} + +/////////////////////////////// +// Extra +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) { +// find transition(_, v, s); +// neg find child(_,v); +//} or { +// find transition(_, s, v); +// neg find child(_,v); +//} + +pattern child(parent: CompositeElement, child: Vertex) { + CompositeElement.regions.vertices(parent, child); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) { + find transition(_, v, s); + find child(c,v); + neg find hasMultipleRegions(c); +} or { + find transition(_, s, v); + find child(c,v); + neg find hasMultipleRegions(c); +} + + +pattern hasMultipleRegions(composite: CompositeElement) { + CompositeElement.regions(composite,region1); + CompositeElement.regions(composite,region2); + region1 != region2; +} + +/** + * Simplifying model generation + */ +@Constraint(severity="error", message="error", key = {s}) +pattern synchThree(s: Synchronization) { + Transition.target(t1,s); + Transition.target(t2,s); + Transition.target(t3,s); + t1!=t2; + t2!=t3; + t1!=t3; +} or { + Transition.source(t1,s); + Transition.source(t2,s); + Transition.source(t3,s); + t1!=t2; + t2!=t3; + t1!=t3; +} + +/** + * Simplifying model generation + */ +@Constraint(severity="error", message="error", key = {s1,s2}) +pattern twoSynch(s1 : Synchronization, s2 : Synchronization) { + Synchronization(s1); + Synchronization(s2); + s1 != s2; +} + +/** + * Model generation task: at least one synch + */ +//@Constraint(severity="error", message="error", key = {s}) +//pattern noSynch(s:Statechart) { +// Statechart(s); +// neg find synch(_); +//} +//pattern synch(s:Synchronization) { +// Synchronization(s); +//} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java new file mode 100644 index 00000000..b8fafb35 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java @@ -0,0 +1,336 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * The Adapter Factory for the model. + * It provides an adapter createXXX method for each class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage + * @generated + */ +public class yakinduAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * + * + * @generated + */ + protected static yakinduPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * + * + * @generated + */ + public yakinduAdapterFactory() { + if (modelPackage == null) { + modelPackage = yakinduPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * + * This implementation returns true if the object is either the model's package or is an instance object of the model. + * + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the createXXX methods. + * + * + * @generated + */ + protected yakinduSwitch modelSwitch = + new yakinduSwitch() { + @Override + public Adapter casePseudostate(Pseudostate object) { + return createPseudostateAdapter(); + } + @Override + public Adapter caseVertex(Vertex object) { + return createVertexAdapter(); + } + @Override + public Adapter caseRegion(Region object) { + return createRegionAdapter(); + } + @Override + public Adapter caseTransition(Transition object) { + return createTransitionAdapter(); + } + @Override + public Adapter caseStatechart(Statechart object) { + return createStatechartAdapter(); + } + @Override + public Adapter caseEntry(Entry object) { + return createEntryAdapter(); + } + @Override + public Adapter caseSynchronization(Synchronization object) { + return createSynchronizationAdapter(); + } + @Override + public Adapter caseState(State object) { + return createStateAdapter(); + } + @Override + public Adapter caseRegularState(RegularState object) { + return createRegularStateAdapter(); + } + @Override + public Adapter caseCompositeElement(CompositeElement object) { + return createCompositeElementAdapter(); + } + @Override + public Adapter caseChoice(Choice object) { + return createChoiceAdapter(); + } + @Override + public Adapter caseExit(Exit object) { + return createExitAdapter(); + } + @Override + public Adapter caseFinalState(FinalState object) { + return createFinalStateAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the target. + * + * + * @param target the object to adapt. + * @return the adapter for the target. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate + * @generated + */ + public Adapter createPseudostateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex + * @generated + */ + public Adapter createVertexAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region + * @generated + */ + public Adapter createRegionAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition + * @generated + */ + public Adapter createTransitionAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart + * @generated + */ + public Adapter createStatechartAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry + * @generated + */ + public Adapter createEntryAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization + * @generated + */ + public Adapter createSynchronizationAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State + * @generated + */ + public Adapter createStateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState + * @generated + */ + public Adapter createRegularStateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement + * @generated + */ + public Adapter createCompositeElementAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice + * @generated + */ + public Adapter createChoiceAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit + * @generated + */ + public Adapter createExitAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState + * @generated + */ + public Adapter createFinalStateAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * + * This default implementation returns null. + * + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //yakinduAdapterFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java new file mode 100644 index 00000000..fbc6f821 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java @@ -0,0 +1,378 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +/** + * + * The Switch for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the caseXXX method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage + * @generated + */ +public class yakinduSwitch extends Switch { + /** + * The cached model package + * + * + * @generated + */ + protected static yakinduPackage modelPackage; + + /** + * Creates an instance of the switch. + * + * + * @generated + */ + public yakinduSwitch() { + if (modelPackage == null) { + modelPackage = yakinduPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * + * + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. + * + * + * @return the first non-null result returned by a caseXXX call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case yakinduPackage.PSEUDOSTATE: { + Pseudostate pseudostate = (Pseudostate)theEObject; + T result = casePseudostate(pseudostate); + if (result == null) result = caseVertex(pseudostate); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.VERTEX: { + Vertex vertex = (Vertex)theEObject; + T result = caseVertex(vertex); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.REGION: { + Region region = (Region)theEObject; + T result = caseRegion(region); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.TRANSITION: { + Transition transition = (Transition)theEObject; + T result = caseTransition(transition); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.STATECHART: { + Statechart statechart = (Statechart)theEObject; + T result = caseStatechart(statechart); + if (result == null) result = caseCompositeElement(statechart); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.ENTRY: { + Entry entry = (Entry)theEObject; + T result = caseEntry(entry); + if (result == null) result = casePseudostate(entry); + if (result == null) result = caseVertex(entry); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.SYNCHRONIZATION: { + Synchronization synchronization = (Synchronization)theEObject; + T result = caseSynchronization(synchronization); + if (result == null) result = casePseudostate(synchronization); + if (result == null) result = caseVertex(synchronization); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.STATE: { + State state = (State)theEObject; + T result = caseState(state); + if (result == null) result = caseRegularState(state); + if (result == null) result = caseCompositeElement(state); + if (result == null) result = caseVertex(state); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.REGULAR_STATE: { + RegularState regularState = (RegularState)theEObject; + T result = caseRegularState(regularState); + if (result == null) result = caseVertex(regularState); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.COMPOSITE_ELEMENT: { + CompositeElement compositeElement = (CompositeElement)theEObject; + T result = caseCompositeElement(compositeElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.CHOICE: { + Choice choice = (Choice)theEObject; + T result = caseChoice(choice); + if (result == null) result = casePseudostate(choice); + if (result == null) result = caseVertex(choice); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.EXIT: { + Exit exit = (Exit)theEObject; + T result = caseExit(exit); + if (result == null) result = casePseudostate(exit); + if (result == null) result = caseVertex(exit); + if (result == null) result = defaultCase(theEObject); + return result; + } + case yakinduPackage.FINAL_STATE: { + FinalState finalState = (FinalState)theEObject; + T result = caseFinalState(finalState); + if (result == null) result = caseRegularState(finalState); + if (result == null) result = caseVertex(finalState); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of 'Pseudostate'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Pseudostate'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePseudostate(Pseudostate object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Vertex'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Vertex'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseVertex(Vertex object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Region'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Region'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRegion(Region object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Transition'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Transition'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseTransition(Transition object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Statechart'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Statechart'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseStatechart(Statechart object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Entry'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Entry'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseEntry(Entry object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Synchronization'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Synchronization'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseSynchronization(Synchronization object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseState(State object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Regular State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Regular State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRegularState(RegularState object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Composite Element'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Composite Element'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseCompositeElement(CompositeElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Choice'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Choice'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseChoice(Choice object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Exit'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Exit'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseExit(Exit object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Final State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Final State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFinalState(FinalState object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'EObject'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'EObject'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //yakinduSwitch diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java new file mode 100644 index 00000000..6d437ecb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java @@ -0,0 +1,114 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.ecore.EFactory; + +/** + * + * The Factory for the model. + * It provides a create method for each non-abstract class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage + * @generated + */ +public interface yakinduFactory extends EFactory { + /** + * The singleton instance of the factory. + * + * + * @generated + */ + yakinduFactory eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduFactoryImpl.init(); + + /** + * Returns a new object of class 'Region'. + * + * + * @return a new object of class 'Region'. + * @generated + */ + Region createRegion(); + + /** + * Returns a new object of class 'Transition'. + * + * + * @return a new object of class 'Transition'. + * @generated + */ + Transition createTransition(); + + /** + * Returns a new object of class 'Statechart'. + * + * + * @return a new object of class 'Statechart'. + * @generated + */ + Statechart createStatechart(); + + /** + * Returns a new object of class 'Entry'. + * + * + * @return a new object of class 'Entry'. + * @generated + */ + Entry createEntry(); + + /** + * Returns a new object of class 'Synchronization'. + * + * + * @return a new object of class 'Synchronization'. + * @generated + */ + Synchronization createSynchronization(); + + /** + * Returns a new object of class 'State'. + * + * + * @return a new object of class 'State'. + * @generated + */ + State createState(); + + /** + * Returns a new object of class 'Choice'. + * + * + * @return a new object of class 'Choice'. + * @generated + */ + Choice createChoice(); + + /** + * Returns a new object of class 'Exit'. + * + * + * @return a new object of class 'Exit'. + * @generated + */ + Exit createExit(); + + /** + * Returns a new object of class 'Final State'. + * + * + * @return a new object of class 'Final State'. + * @generated + */ + FinalState createFinalState(); + + /** + * Returns the package supported by this factory. + * + * + * @return the package supported by this factory. + * @generated + */ + yakinduPackage getyakinduPackage(); + +} //yakinduFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java new file mode 100644 index 00000000..b3b14944 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java @@ -0,0 +1,1038 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * + * The Package for the model. + * It contains accessors for the meta objects to represent + *

    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduFactory + * @model kind="package" + * @generated + */ +public interface yakinduPackage extends EPackage { + /** + * The package name. + * + * + * @generated + */ + String eNAME = "yakindu"; + + /** + * The package namespace URI. + * + * + * @generated + */ + String eNS_URI = "YakinduMetamodel"; + + /** + * The package namespace name. + * + * + * @generated + */ + String eNS_PREFIX = "yakindu"; + + /** + * The singleton instance of the package. + * + * + * @generated + */ + yakinduPackage eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl.init(); + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getVertex() + * @generated + */ + int VERTEX = 1; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int VERTEX__INCOMING_TRANSITIONS = 0; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int VERTEX__OUTGOING_TRANSITIONS = 1; + + /** + * The number of structural features of the 'Vertex' class. + * + * + * @generated + * @ordered + */ + int VERTEX_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Vertex' class. + * + * + * @generated + * @ordered + */ + int VERTEX_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getPseudostate() + * @generated + */ + int PSEUDOSTATE = 0; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Pseudostate' class. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Pseudostate' class. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegion() + * @generated + */ + int REGION = 2; + + /** + * The feature id for the 'Vertices' containment reference list. + * + * + * @generated + * @ordered + */ + int REGION__VERTICES = 0; + + /** + * The number of structural features of the 'Region' class. + * + * + * @generated + * @ordered + */ + int REGION_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'Region' class. + * + * + * @generated + * @ordered + */ + int REGION_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getTransition() + * @generated + */ + int TRANSITION = 3; + + /** + * The feature id for the 'Target' reference. + * + * + * @generated + * @ordered + */ + int TRANSITION__TARGET = 0; + + /** + * The feature id for the 'Source' container reference. + * + * + * @generated + * @ordered + */ + int TRANSITION__SOURCE = 1; + + /** + * The number of structural features of the 'Transition' class. + * + * + * @generated + * @ordered + */ + int TRANSITION_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Transition' class. + * + * + * @generated + * @ordered + */ + int TRANSITION_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getCompositeElement() + * @generated + */ + int COMPOSITE_ELEMENT = 9; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT__REGIONS = 0; + + /** + * The number of structural features of the 'Composite Element' class. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'Composite Element' class. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getStatechart() + * @generated + */ + int STATECHART = 4; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATECHART__REGIONS = COMPOSITE_ELEMENT__REGIONS; + + /** + * The number of structural features of the 'Statechart' class. + * + * + * @generated + * @ordered + */ + int STATECHART_FEATURE_COUNT = COMPOSITE_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Statechart' class. + * + * + * @generated + * @ordered + */ + int STATECHART_OPERATION_COUNT = COMPOSITE_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getEntry() + * @generated + */ + int ENTRY = 5; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int ENTRY__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int ENTRY__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Entry' class. + * + * + * @generated + * @ordered + */ + int ENTRY_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Entry' class. + * + * + * @generated + * @ordered + */ + int ENTRY_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getSynchronization() + * @generated + */ + int SYNCHRONIZATION = 6; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Synchronization' class. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Synchronization' class. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegularState() + * @generated + */ + int REGULAR_STATE = 8; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Regular State' class. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Regular State' class. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getState() + * @generated + */ + int STATE = 7; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATE__REGIONS = REGULAR_STATE_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'State' class. + * + * + * @generated + * @ordered + */ + int STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 1; + + /** + * The number of operations of the 'State' class. + * + * + * @generated + * @ordered + */ + int STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getChoice() + * @generated + */ + int CHOICE = 10; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int CHOICE__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int CHOICE__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Choice' class. + * + * + * @generated + * @ordered + */ + int CHOICE_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Choice' class. + * + * + * @generated + * @ordered + */ + int CHOICE_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getExit() + * @generated + */ + int EXIT = 11; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int EXIT__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int EXIT__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Exit' class. + * + * + * @generated + * @ordered + */ + int EXIT_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Exit' class. + * + * + * @generated + * @ordered + */ + int EXIT_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getFinalState() + * @generated + */ + int FINAL_STATE = 12; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int FINAL_STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int FINAL_STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Final State' class. + * + * + * @generated + * @ordered + */ + int FINAL_STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Final State' class. + * + * + * @generated + * @ordered + */ + int FINAL_STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; + + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. + * + * + * @return the meta object for class 'Pseudostate'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate + * @generated + */ + EClass getPseudostate(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. + * + * + * @return the meta object for class 'Vertex'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex + * @generated + */ + EClass getVertex(); + + /** + * Returns the meta object for the reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions Incoming Transitions}'. + * + * + * @return the meta object for the reference list 'Incoming Transitions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions() + * @see #getVertex() + * @generated + */ + EReference getVertex_IncomingTransitions(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}'. + * + * + * @return the meta object for the containment reference list 'Outgoing Transitions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions() + * @see #getVertex() + * @generated + */ + EReference getVertex_OutgoingTransitions(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. + * + * + * @return the meta object for class 'Region'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region + * @generated + */ + EClass getRegion(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices Vertices}'. + * + * + * @return the meta object for the containment reference list 'Vertices'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices() + * @see #getRegion() + * @generated + */ + EReference getRegion_Vertices(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. + * + * + * @return the meta object for class 'Transition'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition + * @generated + */ + EClass getTransition(); + + /** + * Returns the meta object for the reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}'. + * + * + * @return the meta object for the reference 'Target'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget() + * @see #getTransition() + * @generated + */ + EReference getTransition_Target(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}'. + * + * + * @return the meta object for the container reference 'Source'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource() + * @see #getTransition() + * @generated + */ + EReference getTransition_Source(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. + * + * + * @return the meta object for class 'Statechart'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart + * @generated + */ + EClass getStatechart(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. + * + * + * @return the meta object for class 'Entry'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry + * @generated + */ + EClass getEntry(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. + * + * + * @return the meta object for class 'Synchronization'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization + * @generated + */ + EClass getSynchronization(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. + * + * + * @return the meta object for class 'State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State + * @generated + */ + EClass getState(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. + * + * + * @return the meta object for class 'Regular State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState + * @generated + */ + EClass getRegularState(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. + * + * + * @return the meta object for class 'Composite Element'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement + * @generated + */ + EClass getCompositeElement(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions Regions}'. + * + * + * @return the meta object for the containment reference list 'Regions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions() + * @see #getCompositeElement() + * @generated + */ + EReference getCompositeElement_Regions(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. + * + * + * @return the meta object for class 'Choice'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice + * @generated + */ + EClass getChoice(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. + * + * + * @return the meta object for class 'Exit'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit + * @generated + */ + EClass getExit(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. + * + * + * @return the meta object for class 'Final State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState + * @generated + */ + EClass getFinalState(); + + /** + * Returns the factory that creates the instances of the model. + * + * + * @return the factory that creates the instances of the model. + * @generated + */ + yakinduFactory getyakinduFactory(); + + /** + * + * Defines literals for the meta objects that represent + *
    + *
  • each class,
  • + *
  • each feature of each class,
  • + *
  • each operation of each class,
  • + *
  • each enum,
  • + *
  • and each data type
  • + *
+ * + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getPseudostate() + * @generated + */ + EClass PSEUDOSTATE = eINSTANCE.getPseudostate(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getVertex() + * @generated + */ + EClass VERTEX = eINSTANCE.getVertex(); + + /** + * The meta object literal for the 'Incoming Transitions' reference list feature. + * + * + * @generated + */ + EReference VERTEX__INCOMING_TRANSITIONS = eINSTANCE.getVertex_IncomingTransitions(); + + /** + * The meta object literal for the 'Outgoing Transitions' containment reference list feature. + * + * + * @generated + */ + EReference VERTEX__OUTGOING_TRANSITIONS = eINSTANCE.getVertex_OutgoingTransitions(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegion() + * @generated + */ + EClass REGION = eINSTANCE.getRegion(); + + /** + * The meta object literal for the 'Vertices' containment reference list feature. + * + * + * @generated + */ + EReference REGION__VERTICES = eINSTANCE.getRegion_Vertices(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getTransition() + * @generated + */ + EClass TRANSITION = eINSTANCE.getTransition(); + + /** + * The meta object literal for the 'Target' reference feature. + * + * + * @generated + */ + EReference TRANSITION__TARGET = eINSTANCE.getTransition_Target(); + + /** + * The meta object literal for the 'Source' container reference feature. + * + * + * @generated + */ + EReference TRANSITION__SOURCE = eINSTANCE.getTransition_Source(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getStatechart() + * @generated + */ + EClass STATECHART = eINSTANCE.getStatechart(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getEntry() + * @generated + */ + EClass ENTRY = eINSTANCE.getEntry(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getSynchronization() + * @generated + */ + EClass SYNCHRONIZATION = eINSTANCE.getSynchronization(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getState() + * @generated + */ + EClass STATE = eINSTANCE.getState(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegularState() + * @generated + */ + EClass REGULAR_STATE = eINSTANCE.getRegularState(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getCompositeElement() + * @generated + */ + EClass COMPOSITE_ELEMENT = eINSTANCE.getCompositeElement(); + + /** + * The meta object literal for the 'Regions' containment reference list feature. + * + * + * @generated + */ + EReference COMPOSITE_ELEMENT__REGIONS = eINSTANCE.getCompositeElement_Regions(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getChoice() + * @generated + */ + EClass CHOICE = eINSTANCE.getChoice(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getExit() + * @generated + */ + EClass EXIT = eINSTANCE.getExit(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getFinalState() + * @generated + */ + EClass FINAL_STATE = eINSTANCE.getFinalState(); + + } + +} //yakinduPackage -- cgit v1.2.3-54-g00ecf From 1da40b0bf07319bdb2e9a89f8d7d6ecfbc638952 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Sat, 16 Feb 2019 15:45:14 -0500 Subject: Integrate queries partially #19 --- .../.classpath | 1 + .../.project | 6 + .../META-INF/MANIFEST.MF | 34 +- .../build.properties | 4 +- .../configurations/ecore.vsconfig | 5 +- .../configurations/fam.vsconfig | 4 +- .../configurations/fileSystem.vsconfig | 4 +- .../configurations/yakindu.vsconfig | 6 +- .../metamodels/fam.ecore | 4 +- .../metamodels/filesystem.ecore | 2 +- .../outputs/fam/debug/errors.txt | 114 + .../fam/debug/generated3valued.vql_deactivated | 32522 +++++++++++++++++++ .../outputs/fam/debug/generation.logicproblem | 2 +- .../outputs/fam/debug/problem.als | 203 + .../outputs/fam/log.txt | 2 +- .../outputs/fam/models/1.gml | 6779 ++++ .../outputs/fam/models/1.png | Bin 141462 -> 159195 bytes .../outputs/fam/models/1.xmi | 13 +- .../outputs/fam/models/2.gml | 6874 ++++ .../outputs/fam/models/2.png | Bin 151601 -> 177546 bytes .../outputs/fam/models/2.xmi | 13 +- .../outputs/fam/models/3.gml | 5613 ++++ .../outputs/fam/models/3.png | Bin 157309 -> 177661 bytes .../outputs/fam/models/3.xmi | 13 +- .../outputs/fam/models/4.gml | 1136 + .../outputs/fam/models/4.png | Bin 162587 -> 189772 bytes .../outputs/fam/models/4.xmi | 11 +- .../outputs/fam/models/5.gml | 1155 + .../outputs/fam/models/5.png | Bin 168585 -> 194199 bytes .../outputs/fam/models/5.xmi | 11 +- .../outputs/fam/statistics.csv | 16 + .../outputs/yakindu/debug/errors.txt | 54 + .../yakindu/debug/generated3valued.vql_deactivated | 23532 ++++++++++++++ .../outputs/yakindu/debug/generation.logicproblem | 277 +- .../outputs/yakindu/debug/init.partialmodel | 47 +- .../outputs/yakindu/log.txt | 2 +- .../outputs/yakindu/models/1.gml | 4304 +++ .../outputs/yakindu/models/1.png | Bin 30880 -> 33827 bytes .../outputs/yakindu/models/1.xmi | 16 +- .../outputs/yakindu/models/2.gml | 3692 +++ .../outputs/yakindu/models/2.png | Bin 36094 -> 29697 bytes .../outputs/yakindu/models/2.xmi | 15 +- .../outputs/yakindu/statistics.csv | 20 + .../plugin.xml | 168 +- .../test/ecore/queries/ecorePatterns.vql | 29 + .../standalone/test/fam/queries/famPatterns.vql | 103 + .../test/filesystem/queries/FileSystemPatterns.vql | 24 + .../yakindu/queries/yakinduMutatedPatterns.vql | 270 + .../test/yakindu/queries/yakinduPatterns.vql | 227 + .../standalone/test/ecore/queries/.gitignore | 13 + .../standalone/test/fam/queries/.gitignore | 10 + .../test/fam/queries/TerminatorAndInformation.java | 747 + .../standalone/test/fam/queries/Type.java | 770 + .../standalone/test/filesystem/queries/.gitignore | 9 + .../standalone/test/yakindu/queries/.gitignore | 158 + .../standalone/test/yakindu/queries/Child.java | 721 + .../test/yakindu/queries/ChoiceHasNoIncoming.java | 551 + .../test/yakindu/queries/ChoiceHasNoOutgoing.java | 559 + .../test/yakindu/queries/EntryInRegion.java | 702 + .../queries/HasMultipleIncomingTrainsition.java | 549 + .../queries/HasMultipleOutgoingTrainsition.java | 549 + .../test/yakindu/queries/HasMultipleRegions.java | 555 + .../test/yakindu/queries/IncomingToEntry.java | 703 + .../queries/MultipleTransitionFromEntry.java | 827 + .../test/yakindu/queries/NoEntryInRegion.java | 550 + .../queries/NoOutgoingTransitionFromEntry.java | 551 + .../test/yakindu/queries/NoStateInRegion.java | 558 + .../yakindu/queries/NotSynchronizingStates.java | 554 + .../test/yakindu/queries/OutgoingFromExit.java | 715 + .../test/yakindu/queries/OutgoingFromFinal.java | 715 + .../test/yakindu/queries/StateInRegion.java | 694 + .../test/yakindu/queries/SynchHasNoIncoming.java | 551 + .../test/yakindu/queries/SynchHasNoOutgoing.java | 559 + .../test/yakindu/queries/SynchThree.java | 639 + .../queries/SynchronizedIncomingInSameRegion.java | 888 + ...nchronizedRegionDoesNotHaveMultipleRegions.java | 744 + .../queries/SynchronizedRegionsAreNotSiblings.java | 902 + .../test/yakindu/queries/Transition.java | 808 + .../standalone/test/yakindu/queries/TwoSynch.java | 714 + .../standalone/test/ecore/queries/Ecore.vql | 29 - .../dslreasoner/standalone/test/fam/Function.java | 2 +- .../standalone/test/fam/FunctionalElement.java | 2 +- .../standalone/test/fam/impl/famPackageImpl.java | 4 +- .../standalone/test/fam/queries/famPatterns.vql | 103 - .../test/filesystem/queries/FileSystem.vql | 24 - .../yakindu/queries/yakinduMutatedPatterns.vql | 270 - .../test/yakindu/queries/yakinduPatterns.vql | 227 - 87 files changed, 104682 insertions(+), 871 deletions(-) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystemPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/.gitignore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath index d8bd95f6..dbb1533f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath @@ -1,6 +1,7 @@ + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project index c2212771..279c4d65 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.project @@ -5,6 +5,11 @@ + + org.eclipse.xtext.ui.shared.xtextBuilder + + + org.eclipse.viatra.query.tooling.ui.projectbuilder @@ -30,5 +35,6 @@ org.eclipse.pde.PluginNature org.eclipse.jdt.core.javanature org.eclipse.viatra.query.projectnature + org.eclipse.xtext.ui.shared.xtextNature diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF index ca7ad11c..61135ac9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF @@ -6,22 +6,26 @@ Bundle-Version: 1.0.0.qualifier Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin -Export-Package: ca.mcgill.ecse.dslreasoner.standalone.test.fam, - ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.fam.util, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util +Export-Package: ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.fam, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.util, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.core.runtime;bundle-version="3.13.0", - org.eclipse.emf.ecore;bundle-version="2.13.0";visibility:=reexport, - org.eclipse.viatra.query.runtime;bundle-version="2.1.0", - org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", - org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", - org.eclipse.xtext.xbase.lib;bundle-version="2.12.0" + org.eclipse.core.runtime;bundle-version="3.13.0", + org.eclipse.emf.ecore;bundle-version="2.13.0";visibility:=reexport, + org.eclipse.viatra.query.runtime;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", + org.eclipse.xtext.xbase.lib;bundle-version="2.12.0" Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.standalone.test Bundle-ActivationPolicy: lazy diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties index 8ae35ddd..876d970c 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties @@ -3,5 +3,7 @@ bin.includes = META-INF/,\ plugin.properties jars.compile.order = . -source.. = src/ +source.. = src/,\ + src-gen/,\ + queries/ output.. = bin/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig index e5873211..9360ab61 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig @@ -1,4 +1,5 @@ import epackage "http://www.eclipse.org/emf/2002/Ecore" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.EcorePatterns" metamodel allSupported { package ecore excluding { EClassifier.instanceClass,EClassifier.defaultValue,EEnumLiteral.instance,EStructuralFeature.defaultValue, @@ -9,7 +10,7 @@ metamodel allSupported { package ecore excluding { generate { metamodel = allSupported - //constraints = { ... } +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries} partial-model = { "platform:/resource/Ecore-Plugin/InitialPackage.ecore" } solver = ViatraSolver scope = { @@ -23,7 +24,7 @@ generate { log-level = normal } - number = 5 + number = 3 runs = 1 debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig index f4f29089..d376dce8 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig @@ -1,9 +1,9 @@ import epackage "FamMetamodel" -//import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.queries.fam.FamPatterns" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns" generate { metamodel = { package fam } -// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} solver = ViatraSolver scope = { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig index 64775e8d..0e510a55 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig @@ -1,9 +1,9 @@ import epackage "FileSystemMetamodel" -//import viatra "" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries.FileSystemPatterns" generate { metamodel = { package filesystem } -// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries} partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi"} solver = ViatraSolver scope = { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig index 246337de..423bf80e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig @@ -1,13 +1,13 @@ import epackage "YakinduMetamodel" -//import viatra "" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.YakinduPatterns" generate { metamodel = { package yakindu } -// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.xyz } + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries } partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi"} solver = ViatraSolver scope = { - #node = 5 + #node = 6 } config = { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore index 498e9838..d9c8bfef 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore @@ -10,7 +10,7 @@ -
+
-
+
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore index 3dd2061b..8952cfb5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore @@ -10,7 +10,7 @@ -
+
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt index 94b0f4e3..e96fe7c5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt @@ -192,4 +192,118 @@ Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalo hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.builder.Alloy2LogicMapper.transformOutput(Alloy2LogicMapper.java:53) + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.AlloySolver.solve(AlloySolver.java:66) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Unable to translate query "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.oppositeDifferentClass". +Reason: IllegalArgumentException, Inconsistent types: [EStructuralFeature class, EModelElement class, ENamedElement class, EReference class, EObject class, ETypedElement class] + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:166) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Unable to translate query "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.oppositeDifferentClass". +Reason: IllegalArgumentException, Inconsistent types: [EStructuralFeature class, EModelElement class, ENamedElement class, EReference class, EObject class, ETypedElement class] + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:166) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated index 88497c64..f02c64b0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated @@ -31731,3 +31731,32525 @@ pattern refineRelation_value_attribute_EStringToStringMapEntry( find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); +} +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); +} +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "EAttribute class". + */ +private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAttribute class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAttribute class"); +} + +/** + * An element may be an instance of type "EAttribute class". + */ +private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EAnnotation class". + */ +private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EAnnotation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EAnnotation class"); +} + +/** + * An element may be an instance of type "EAnnotation class". + */ +private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClass class". + */ +private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClass class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClass class"); +} + +/** + * An element may be an instance of type "EClass class". + */ +private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClass_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EClassifier class". + */ +private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EClassifier class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EClassifier class"); +} + +/** + * An element may be an instance of type "EClassifier class". + */ +private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EDataType class". + */ +private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EDataType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EDataType class"); +} + +/** + * An element may be an instance of type "EDataType class". + */ +private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnum class". + */ +private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnum class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnum class"); +} + +/** + * An element may be an instance of type "EEnum class". + */ +private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EEnumLiteral class". + */ +private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EEnumLiteral class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EEnumLiteral class"); +} + +/** + * An element may be an instance of type "EEnumLiteral class". + */ +private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class". + */ +private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class"); +} + +/** + * An element may be an instance of type "EModelElement class". + */ +private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class". + */ +private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class"); +} + +/** + * An element may be an instance of type "ENamedElement class". + */ +private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EObject class". + */ +private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EObject class"); +} + +/** + * An element may be an instance of type "EObject class". + */ +private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EOperation class". + */ +private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EOperation class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EOperation class"); +} + +/** + * An element may be an instance of type "EOperation class". + */ +private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewEOperation_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class". + */ +private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class"); +} + +/** + * An element may be an instance of type "EPackage class". + */ +private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EParameter class". + */ +private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EParameter class"); +} + +/** + * An element may be an instance of type "EParameter class". + */ +private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewEParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EReference class". + */ +private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EReference class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EReference class"); +} + +/** + * An element may be an instance of type "EReference class". + */ +private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEReference_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEReference_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStructuralFeature class". + */ +private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStructuralFeature class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStructuralFeature class"); +} + +/** + * An element may be an instance of type "EStructuralFeature class". + */ +private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypedElement class". + */ +private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypedElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypedElement class"); +} + +/** + * An element may be an instance of type "ETypedElement class". + */ +private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find scopeDisallowsNewETypedElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EStringToStringMapEntry class". + */ +private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EStringToStringMapEntry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EStringToStringMapEntry class"); +} + +/** + * An element may be an instance of type "EStringToStringMapEntry class". + */ +private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EGenericType class". + */ +private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EGenericType class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EGenericType class"); +} + +/** + * An element may be an instance of type "EGenericType class". + */ +private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEGenericType_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } +/** + * An element must be an instance of type "ETypeParameter class". + */ +private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ETypeParameter class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ETypeParameter class"); +} + +/** + * An element may be an instance of type "ETypeParameter class". + */ +private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class DefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class DefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class DefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EModelElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EModelElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "EModelElement class UndefinedPart". + */ +private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class DefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class DefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"ENamedElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"ENamedElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "ENamedElement class UndefinedPart". + */ +private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class DefinedPart". + */ +private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class DefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class DefinedPart". + */ +private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "EPackage class UndefinedPart". + */ +private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"EPackage class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"EPackage class UndefinedPart"); +} + +/** + * An element may be an instance of type "EPackage class UndefinedPart". + */ +private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + */ +private pattern mustInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + */ +private pattern mayInRelationeAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + find mayInstanceOfEDataType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + */ +private pattern mustInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + */ +private pattern mayInRelationdetails_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + */ +private pattern mustInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + */ +private pattern mayInRelationeModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEModelElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + */ +private pattern mustInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + */ +private pattern mayInRelationcontents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + */ +private pattern mustInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + */ +private pattern mayInRelationreferences_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + find mayInstanceOfEObject_class(problem,interpretation,target); +} or { + find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + */ +private pattern mustInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + */ +private pattern mayInRelationeOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + */ +private pattern mustInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + */ +private pattern mayInRelationeAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + */ +private pattern mustInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + */ +private pattern mayInRelationeReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + */ +private pattern mustInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + */ +private pattern mayInRelationeAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + */ +private pattern mustInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + */ +private pattern mayInRelationeAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); +} or { + find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + */ +private pattern mustInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + */ +private pattern mayInRelationeAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); +} or { + find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); +} or { + find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); +} or { + find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + */ +private pattern mustInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + */ +private pattern mayInRelationeIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + */ +private pattern mustInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + */ +private pattern mayInRelationeStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + */ +private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); +} or { + find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + */ +private pattern mustInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + */ +private pattern mayInRelationePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + */ +private pattern mustInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + */ +private pattern mayInRelationeLiterals_reference_EEnum( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnum_class(problem,interpretation,source); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + */ +private pattern mustInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + */ +private pattern mayInRelationeEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + find mayInstanceOfEEnum_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + */ +private pattern mustInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + */ +private pattern mayInRelationeAnnotations_reference_EModelElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEModelElement_class(problem,interpretation,source); + find mayInstanceOfEAnnotation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + */ +private pattern mustInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + */ +private pattern mayInRelationeTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + */ +private pattern mustInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + */ +private pattern mayInRelationeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); +} or { + find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + */ +private pattern mustInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + */ +private pattern mayInRelationeGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEOperation_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + */ +private pattern mustInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + */ +private pattern mayInRelationeClassifiers_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + */ +private pattern mustInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + */ +private pattern mayInRelationeSubpackages_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + */ +private pattern mustInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + */ +private pattern mayInRelationeSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + find mayInstanceOfEPackage_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + */ +private pattern mustInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + */ +private pattern mayInRelationeOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEParameter_class(problem,interpretation,source); + find mayInstanceOfEOperation_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) + */ +private pattern mustInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) + */ +private pattern mayInRelationeOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEReference_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + */ +private pattern mustInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + */ +private pattern mayInRelationeReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + */ +private pattern mustInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + */ +private pattern mayInRelationeKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + find mayInstanceOfEAttribute_class(problem,interpretation,target); +} or { + find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mustInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + */ +private pattern mayInRelationeContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + find mayInstanceOfEClass_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + */ +private pattern mustInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + */ +private pattern mayInRelationeType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + */ +private pattern mustInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + */ +private pattern mayInRelationeGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + */ +private pattern mustInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + */ +private pattern mayInRelationeUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + */ +private pattern mustInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + */ +private pattern mayInRelationeRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + */ +private pattern mustInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + */ +private pattern mayInRelationeLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + */ +private pattern mustInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + */ +private pattern mayInRelationeTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfETypeParameter_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + */ +private pattern mustInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + */ +private pattern mayInRelationeClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEGenericType_class(problem,interpretation,source); + find mayInstanceOfEClassifier_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + */ +private pattern mustInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + */ +private pattern mayInRelationeBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypeParameter_class(problem,interpretation,source); + find mayInstanceOfEGenericType_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + */ +private pattern mustInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + */ +private pattern mayInRelationiD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAttribute_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + */ +private pattern mustInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + */ +private pattern mayInRelationsource_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEAnnotation_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + */ +private pattern mustInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + */ +private pattern mayInRelationabstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface attribute EClass(source,target) + */ +private pattern mustInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + */ +private pattern mayInRelationinterface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClass_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + */ +private pattern mustInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + */ +private pattern mayInRelationinstanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEClassifier_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + */ +private pattern mustInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + */ +private pattern mayInRelationserializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEDataType_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationvalue_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) + */ +private pattern mustInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) + */ +private pattern mayInRelationliteral_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + */ +private pattern mustInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + */ +private pattern mayInRelationname_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfENamedElement_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + */ +private pattern mustInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + */ +private pattern mayInRelationnsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + */ +private pattern mustInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + */ +private pattern mayInRelationnsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEPackage_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []containment attribute EReference(source,target) + */ +private pattern mustInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>containment attribute EReference(source,target) + */ +private pattern mayInRelationcontainment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []container attribute EReference(source,target) + */ +private pattern mustInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>container attribute EReference(source,target) + */ +private pattern mayInRelationcontainer_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) + */ +private pattern mustInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + */ +private pattern mayInRelationresolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEReference_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationchangeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationvolatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationtransient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationunsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + */ +private pattern mustInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + */ +private pattern mayInRelationderived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + */ +private pattern mustInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + */ +private pattern mayInRelationordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + */ +private pattern mustInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + */ +private pattern mayInRelationunique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationlowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + */ +private pattern mustInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + */ +private pattern mayInRelationupperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + IntegerElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + */ +private pattern mustInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + */ +private pattern mayInRelationmany_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + */ +private pattern mustInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + */ +private pattern mayInRelationrequired_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfETypedElement_class(problem,interpretation,source); + BooleanElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationkey_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + */ +private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + */ +private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); + StringElement(target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or + + { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or + + { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or + + { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or + + { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or + + { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or + + { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or + + { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or + + { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustInstanceOfEAttribute_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustInstanceOfEReference_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEOperation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEGenericType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAttribute_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEDataType_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClassifier_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEAnnotation_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypeParameter_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEReference_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEEnum_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfETypedElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEClass_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EStringToStringMapEntry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnum_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); + find mayInstanceOfEEnum_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + find mayInstanceOfEParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); + find mustInstanceOfETypedElement_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); + find mustInstanceOfEGenericType_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); + find mustInstanceOfETypeParameter_class(problem,interpretation,container); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EGenericType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EPackage_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class_by_contents_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); + find mustInstanceOfEAnnotation_class(problem,interpretation,container); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EObject_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); + find mayInstanceOfEObject_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); + find mustInstanceOfEEnum_class(problem,interpretation,container); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EEnumLiteral_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); + find mustInstanceOfEClassifier_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); + find mustInstanceOfEOperation_class(problem,interpretation,container); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_ETypeParameter_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); + find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAttribute_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EOperation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); + find mayInstanceOfEOperation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); + find mustInstanceOfEModelElement_class(problem,interpretation,container); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EAnnotation_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); + find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); + find mustInstanceOfEClass_class(problem,interpretation,container); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EReference_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); + find mayInstanceOfEReference_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EDataType_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + find mayInstanceOfEDataType_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); + find mustInstanceOfEPackage_class(problem,interpretation,container); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_EClass_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); + find mayInstanceOfEClass_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); +} +pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); +} +pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); +} +pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEModelElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); +} +pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); +} +pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); +} +pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); +} +pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfENamedElement_class(problem,interpretation,element); +} +pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEParameter_class(problem,interpretation,element); + neg find mustInstanceOfEReference_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfEClassifier_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); + neg find mustInstanceOfEOperation_class(problem,interpretation,element); + neg find mustInstanceOfEAttribute_class(problem,interpretation,element); +} +pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEEnum_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); +} +pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); + neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); + neg find mustInstanceOfEGenericType_class(problem,interpretation,element); + neg find mustInstanceOfEObject_class(problem,interpretation,element); + neg find mustInstanceOfEDataType_class(problem,interpretation,element); + neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); + neg find mustInstanceOfETypedElement_class(problem,interpretation,element); + neg find mustInstanceOfEClass_class(problem,interpretation,element); + neg find mustInstanceOfEPackage_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_eAttributeType_reference_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + find mustInstanceOfEDataType_class(problem,interpretation,to); + find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_references_reference_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + find mustInstanceOfEObject_class(problem,interpretation,to); + find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_eSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eReferences_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAttributes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllContainments_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllOperations_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEOperation_class(problem,interpretation,to); + find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllStructuralFeatures_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); + find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eIDAttribute_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eAllGenericSuperTypes_reference_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + find mustInstanceOfEGenericType_class(problem,interpretation,to); + find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); +} +pattern refineRelation_eExceptions_reference_EOperation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEOperation_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); +} +pattern refineRelation_eOpposite_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEReference_class(problem,interpretation,to); + find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eReferenceType_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEClass_class(problem,interpretation,to); + find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eKeys_reference_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + find mustInstanceOfEAttribute_class(problem,interpretation,to); + find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); +} +pattern refineRelation_eType_reference_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_eRawType_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eTypeParameter_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfETypeParameter_class(problem,interpretation,to); + find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_eClassifier_reference_EGenericType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEGenericType_class(problem,interpretation,from); + find mustInstanceOfEClassifier_class(problem,interpretation,to); + find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); +} +pattern refineRelation_iD_attribute_EAttribute( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAttribute_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); +} +pattern refineRelation_source_attribute_EAnnotation( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEAnnotation_class(problem,interpretation,from); + StringElement(to); + find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); +} +pattern refineRelation_abstract_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_interface_attribute_EClass( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClass_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); + neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); +} +pattern refineRelation_instanceClassName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_instanceTypeName_attribute_EClassifier( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEClassifier_class(problem,interpretation,from); + StringElement(to); + find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); +} +pattern refineRelation_serializable_attribute_EDataType( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEDataType_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_literal_attribute_EEnumLiteral( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); + StringElement(to); + find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); +} +pattern refineRelation_name_attribute_ENamedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfENamedElement_class(problem,interpretation,from); + StringElement(to); + find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); +} +pattern refineRelation_nsURI_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_nsPrefix_attribute_EPackage( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEPackage_class(problem,interpretation,from); + StringElement(to); + find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); +} +pattern refineRelation_containment_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_container_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_resolveProxies_attribute_EReference( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEReference_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); +} +pattern refineRelation_changeable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_volatile_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_transient_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + StringElement(to); + find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_unsettable_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_derived_attribute_EStructuralFeature( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); +} +pattern refineRelation_ordered_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_unique_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_lowerBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_upperBound_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + IntegerElement(to); + find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_many_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_required_attribute_ETypedElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfETypedElement_class(problem,interpretation,from); + BooleanElement(to); + find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); +} +pattern refineRelation_key_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} +pattern refineRelation_value_attribute_EStringToStringMapEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); + StringElement(to); + find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem index ab657f0b..169eadb3 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem @@ -1995,7 +1995,7 @@ - + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als new file mode 100644 index 00000000..16ff4006 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als @@ -0,0 +1,203 @@ +one sig util'language { + util'root : one type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))), + util'contains : (type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) lone->set (type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) +} +abstract sig util'Object { +} +sig type'FunctionalElement'class in util'Object { + interface'reference'FunctionalElement : lone type'FunctionalInterface'class, + parent'reference'FunctionalElement : lone type'Function'class +} +sig type'FunctionalArchitectureModel'class in util'Object { + rootElements'reference'FunctionalArchitectureModel : set type'FunctionalElement'class +} +sig type'Function'class in type'FunctionalElement'class { + subElements'reference'Function : set type'FunctionalElement'class +} +sig type'FAMTerminator'class in util'Object { + data'reference'FAMTerminator : lone type'FunctionalData'class +} +sig type'InformationLink'class in util'Object { + from'reference'InformationLink : lone type'FunctionalOutput'class, + to'reference'InformationLink : one type'FunctionalInput'class +} +sig type'FunctionalInterface'class in util'Object { + data'reference'FunctionalInterface : set type'FunctionalData'class, + element'reference'FunctionalInterface : lone type'FunctionalElement'class +} +sig type'FunctionalInput'class in type'FunctionalData'class { + IncomingLinks'reference'FunctionalInput : set type'InformationLink'class +} +sig type'FunctionalOutput'class in type'FunctionalData'class { + outgoingLinks'reference'FunctionalOutput : set type'InformationLink'class +} +sig type'FunctionalData'class in util'Object { + terminator'reference'FunctionalData : lone type'FAMTerminator'class, + interface'reference'FunctionalData : lone type'FunctionalInterface'class +} +sig type'FunctionType'enum in util'Object { +} +sig type'FunctionalArchitectureModel'class'DefinedPart in type'FunctionalArchitectureModel'class { +} +sig type'FunctionalArchitectureModel'class'UndefinedPart in type'FunctionalArchitectureModel'class { +} +one sig element'o'1 in type'FunctionalArchitectureModel'class'DefinedPart { +} +one sig element'Root'literal'FunctionType, +element'Intermediate'literal'FunctionType, +element'Leaf'literal'FunctionType in type'FunctionType'enum { +} +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation [parameter'T: type'FAMTerminator'class, parameter'I: type'InformationLink'class] { + (some variable'Out: type'FunctionalOutput'class { parameter'I in variable'Out.outgoingLinks'reference'FunctionalOutput && parameter'T in variable'Out.terminator'reference'FunctionalData }) || (some variable'In: type'FunctionalInput'class { variable'In in parameter'I.to'reference'InformationLink && (variable'In in type'FunctionalInput'class && parameter'T in variable'In.terminator'reference'FunctionalData) }) +} +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [parameter'This: type'Function'class, parameter'Target: type'FunctionType'enum] { + (some variable'Model: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [ variable'Model , parameter'This ] && parameter'Target = element'Root'literal'FunctionType }) || ((all variable'Child: type'Function'class, variable'Model: type'FunctionalArchitectureModel'class { parameter'This in type'Function'class && (! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ variable'Child , parameter'This ]) && (! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [ variable'Model , parameter'This ]) && parameter'Target = element'Leaf'literal'FunctionType)) }) || (some variable'Par: type'Function'class, variable'Child: type'Function'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ parameter'This , variable'Par ] && (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ variable'Child , parameter'This ] && parameter'Target = element'Intermediate'literal'FunctionType) })) +} +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [parameter'Model: type'FunctionalArchitectureModel'class, parameter'Root: type'Function'class] { + parameter'Root in type'Function'class && parameter'Root in parameter'Model.rootElements'reference'FunctionalArchitectureModel +} +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [parameter'Func: type'Function'class, parameter'Par: type'Function'class] { + parameter'Func in type'Function'class && (parameter'Par in parameter'Func.parent'reference'FunctionalElement && parameter'Par in type'Function'class) +} +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [parameter'This: type'FunctionalElement'class, parameter'Target: type'FunctionalArchitectureModel'class] { + parameter'This in type'FunctionalElement'class && parameter'Target in type'FunctionalArchitectureModel'class +} +fact typedefinition'FunctionType'enum { + type'FunctionType'enum = element'Root'literal'FunctionType + (element'Intermediate'literal'FunctionType + element'Leaf'literal'FunctionType) +} +fact typedefinition'FunctionalArchitectureModel'class'DefinedPart { + type'FunctionalArchitectureModel'class'DefinedPart = element'o'1 +} +fact typeElementsUnique'FunctionType'enum { + element'Root'literal'FunctionType != element'Intermediate'literal'FunctionType && (element'Root'literal'FunctionType != element'Leaf'literal'FunctionType && (element'Root'literal'FunctionType != element'o'1 && (element'Intermediate'literal'FunctionType != element'Leaf'literal'FunctionType && (element'Intermediate'literal'FunctionType != element'o'1 && element'Leaf'literal'FunctionType != element'o'1)))) +} +fact typeElementsUnique'FunctionalArchitectureModel'class'DefinedPart { + element'Root'literal'FunctionType != element'Intermediate'literal'FunctionType && (element'Root'literal'FunctionType != element'Leaf'literal'FunctionType && (element'Root'literal'FunctionType != element'o'1 && (element'Intermediate'literal'FunctionType != element'Leaf'literal'FunctionType && (element'Intermediate'literal'FunctionType != element'o'1 && element'Leaf'literal'FunctionType != element'o'1)))) +} +fact abstract'FunctionalElement'class { + type'FunctionalElement'class = type'Function'class +} +fact abstract'FunctionalArchitectureModel'class { + type'FunctionalArchitectureModel'class = type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart +} +fact abstract'FunctionalData'class { + type'FunctionalData'class = type'FunctionalInput'class + type'FunctionalOutput'class +} +fact ObjectTypeDefinition { + util'Object = type'FunctionalElement'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalData'class + type'FunctionType'enum))))) +} +fact common'types'FunctionalArchitectureModel'class'FunctionalElement'class { + type'FunctionalArchitectureModel'class & type'FunctionalElement'class = none +} +fact common'types'FAMTerminator'class'FunctionalElement'class { + type'FAMTerminator'class & type'FunctionalElement'class = none +} +fact common'types'FAMTerminator'class'FunctionalArchitectureModel'class { + type'FAMTerminator'class & type'FunctionalArchitectureModel'class = none +} +fact common'types'InformationLink'class'FunctionalElement'class { + type'InformationLink'class & type'FunctionalElement'class = none +} +fact common'types'InformationLink'class'FunctionalArchitectureModel'class { + type'InformationLink'class & type'FunctionalArchitectureModel'class = none +} +fact common'types'InformationLink'class'FAMTerminator'class { + type'InformationLink'class & type'FAMTerminator'class = none +} +fact common'types'FunctionalInterface'class'FunctionalElement'class { + type'FunctionalInterface'class & type'FunctionalElement'class = none +} +fact common'types'FunctionalInterface'class'FunctionalArchitectureModel'class { + type'FunctionalInterface'class & type'FunctionalArchitectureModel'class = none +} +fact common'types'FunctionalInterface'class'FAMTerminator'class { + type'FunctionalInterface'class & type'FAMTerminator'class = none +} +fact common'types'FunctionalInterface'class'InformationLink'class { + type'FunctionalInterface'class & type'InformationLink'class = none +} +fact common'types'FunctionalData'class'FunctionalElement'class { + type'FunctionalData'class & type'FunctionalElement'class = none +} +fact common'types'FunctionalData'class'FunctionalArchitectureModel'class { + type'FunctionalData'class & type'FunctionalArchitectureModel'class = none +} +fact common'types'FunctionalData'class'FAMTerminator'class { + type'FunctionalData'class & type'FAMTerminator'class = none +} +fact common'types'FunctionalData'class'InformationLink'class { + type'FunctionalData'class & type'InformationLink'class = none +} +fact common'types'FunctionalData'class'FunctionalInterface'class { + type'FunctionalData'class & type'FunctionalInterface'class = none +} +fact common'types'FunctionType'enum'FunctionalElement'class { + type'FunctionType'enum & type'FunctionalElement'class = none +} +fact common'types'FunctionType'enum'FunctionalArchitectureModel'class { + type'FunctionType'enum & type'FunctionalArchitectureModel'class = none +} +fact common'types'FunctionType'enum'FAMTerminator'class { + type'FunctionType'enum & type'FAMTerminator'class = none +} +fact common'types'FunctionType'enum'InformationLink'class { + type'FunctionType'enum & type'InformationLink'class = none +} +fact common'types'FunctionType'enum'FunctionalInterface'class { + type'FunctionType'enum & type'FunctionalInterface'class = none +} +fact common'types'FunctionType'enum'FunctionalData'class { + type'FunctionType'enum & type'FunctionalData'class = none +} +fact common'types'FunctionalArchitectureModel'class'UndefinedPart'FunctionalArchitectureModel'class'DefinedPart { + type'FunctionalArchitectureModel'class'UndefinedPart & type'FunctionalArchitectureModel'class'DefinedPart = none +} +fact common'types'FunctionalOutput'class'FunctionalInput'class { + type'FunctionalOutput'class & type'FunctionalInput'class = none +} +fact util'containmentDefinition { + util'language.util'contains = interface'reference'FunctionalElement + (rootElements'reference'FunctionalArchitectureModel + (subElements'reference'Function + (data'reference'FunctionalInterface + (outgoingLinks'reference'FunctionalOutput + terminator'reference'FunctionalData)))) +} +fact util'noParentForRoot { + no parent: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->(util'language.util'root) in util'language.util'contains } +} +fact util'atLeastOneParent { + all child: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { child = util'language.util'root || (some parent: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->child in util'language.util'contains }) } +} +fact util'noCircularContainment { + no circle: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { circle->circle in ^ (util'language.util'contains) } +} +fact lowerMultiplicity'model'FunctionalElement { + all src: type'FunctionalElement'class { some trg'1: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'1 ] } } +} +fact upperMultiplicity'model'FunctionalElement { + all src: type'FunctionalElement'class, trg'1: type'FunctionalArchitectureModel'class, trg'2: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'1 ] && pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'2 ] => ! (trg'1 != trg'2) } +} +fact oppositeReference'interface'FunctionalElement { + interface'reference'FunctionalElement = ~ element'reference'FunctionalInterface +} +fact oppositeReference'parent'FunctionalElement { + parent'reference'FunctionalElement = ~ subElements'reference'Function +} +fact oppositeReference'data'FAMTerminator { + data'reference'FAMTerminator = ~ terminator'reference'FunctionalData +} +fact oppositeReference'from'InformationLink { + from'reference'InformationLink = ~ outgoingLinks'reference'FunctionalOutput +} +fact oppositeReference'to'InformationLink { + to'reference'InformationLink = ~ IncomingLinks'reference'FunctionalInput +} +fact oppositeReference'data'FunctionalInterface { + data'reference'FunctionalInterface = ~ interface'reference'FunctionalData +} +fact lowerMultiplicity'type'Function { + all src: type'Function'class { some trg'1: type'FunctionType'enum { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'1 ] } } +} +fact upperMultiplicity'type'Function { + all src: type'Function'class, trg'1: type'FunctionType'enum, trg'2: type'FunctionType'enum { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'1 ] && pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'2 ] => ! (trg'1 != trg'2) } +} +fact errorpattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation { + all p0: type'FAMTerminator'class, p1: type'InformationLink'class { ! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation [ p0 , p1 ]) } +} +run { } for exactly 5 util'Object , 31 Int , exactly 0 String \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt index 69222b92..8c87a095 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt @@ -1 +1 @@ -Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file +Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedModel generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedModel generation startedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml index c55209f7..9eac10b7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml @@ -7639,3 +7639,6782 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EEnumLiteral class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eLiterals reference EEnum" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eEnum reference EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "literal attribute EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 12 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "abstract attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EOperation class + ETypedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 238.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EStringToStringMapEntry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "details reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eOperations reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eAllSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eContainingClass reference EOperation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "unique attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "upperBound attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png index c1d6f49f..0ea0ef1b 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi index d9529633..cb79481b 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi @@ -1,9 +1,10 @@ - - - - - - + +
+ + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml index f6242732..77ffa87d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml @@ -4760,3 +4760,6877 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EEnumLiteral class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eLiterals reference EEnum" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eEnum reference EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "literal attribute EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 12 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "abstract attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EOperation class + ETypedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 238.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EStringToStringMapEntry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "details reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eOperations reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eAllSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eContainingClass reference EOperation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "unique attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "upperBound attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png index e01ca46b..b5fea093 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi index c6287127..4a9086fe 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi @@ -1,9 +1,10 @@ - - - - - - + +
+ + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml index 05f41ccb..55dc70ba 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml @@ -2067,3 +2067,5616 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EEnumLiteral class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eLiterals reference EEnum" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eEnum reference EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "literal attribute EEnumLiteral" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 124 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EEnum class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + ETypeParameter class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eTypeParameters reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 12 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "abstract attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EPackage class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + EPackage class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class + ENamedElement class + EOperation class + ETypedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 238.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EStringToStringMapEntry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 14 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "details reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eOperations reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eAllSuperTypes reference EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eContainingClass reference EOperation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eSubpackages reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eSuperPackage reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 1 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "unique attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "upperBound attribute ETypedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png index afaa28c2..bfe18c4e 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi index ef8e8e65..45634c72 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi @@ -1,9 +1,10 @@ - - - - - - + +
+ + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml index d61b14d0..a44b2785 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml @@ -1182,3 +1182,1139 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png index 72ccb4b6..a47da297 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi index 1a10e5b6..8bff1dc6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi @@ -1,9 +1,8 @@ - - - - - - + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml index f071f63e..e5647b66 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml @@ -1201,3 +1201,1158 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 254.10000000000002 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EModelElement class DefinedPart + ENamedElement class DefinedPart + EPackage class DefinedPart + EModelElement class + ENamedElement class + EPackage class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 24.200000000000003 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "-1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "0" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 15.400000000000002 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""A"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 33.0 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""B"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 94.60000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsPrefix"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 68.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""nsUri"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 121.00000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text ""packageName"" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClass class + EClassifier class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 269.5 + h 110 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EClassifier class + EDataType class + EModelElement class + ENamedElement class + EModelElement class UndefinedPart + ENamedElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 269.5 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + EAnnotation class + EModelElement class + EModelElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 12 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "eModelElement reference EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "ePackage reference EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eAnnotations reference EModelElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "eClassifiers reference EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source attribute EAnnotation" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "abstract attribute EClass" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceClassName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "instanceTypeName attribute EClassifier" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "serializable attribute EDataType" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "name attribute ENamedElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsURI attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "nsPrefix attribute EPackage" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png index bb835587..7b6e8da5 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi index 1a10e5b6..8bff1dc6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi @@ -1,9 +1,8 @@ - - - - - - + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv index 0c19baf2..6422beb9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv @@ -30,3 +30,19 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformati 1;1;ModelResultImpl;443;2849;2573;4906642931;151;171;75;124;7;0;8 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime 2;1;ModelResultImpl;19;4315;9042;20459725100;239;247;252;257;261;217;19;6;0;11 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;513;2237;2193;6152392500;162;177;77;150;6;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;11;1602;1604;2992330200;66;77;38;16;1;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;128;4855;10109;16068923000;382;391;398;403;409;349;37;8;0;16 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;18;3632;9743;7955260600;299;307;313;261;17;7;0;8 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;471;5606;10554;10190416000;482;497;509;400;189;16;0;21 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;28;4850;10801;9664839300;622;635;651;560;23;18;0;20 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;6;1884;1462;3186743800;40;48;20;16;1;0;1 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +2;1;ModelResultImpl;9;4021;9222;7668037900;233;239;243;201;10;8;0;6 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt index 2086fece..5caab94d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt @@ -18,4 +18,58 @@ Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is n hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Error loading group hu.bme.mit.inf.dslreasoner.domains.alloyexamples.FileSystem + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$QueryGroupProvider.get(ExtensionBasedQuerySpecificationLoader.java:204) + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:282) + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:1) + org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:66) + org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:1) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl.(FileSystemImpl.java:55) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.createFileSystem(filesystemFactoryImpl.java:74) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.create(filesystemFactoryImpl.java:59) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Error loading group hu.bme.mit.inf.dslreasoner.domains.alloyexamples.FileSystem + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$QueryGroupProvider.get(ExtensionBasedQuerySpecificationLoader.java:204) + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:282) + org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:1) + org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:66) + org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:1) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl.(FileSystemImpl.java:55) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.createFileSystem(filesystemFactoryImpl.java:74) + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.create(filesystemFactoryImpl.java:59) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated index 6d8fc404..f90ed439 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated @@ -1470,3 +1470,23535 @@ pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ +private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>live reference FileSystem(source,target) + */ +private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); +} or { + find mustInRelationlive_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ +private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>live reference FileSystem(source,target) + */ +private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); +} or { + find mustInRelationlive_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFSObject_class(problem,interpretation,var_o1); + find mayInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mayInstanceOfDir_class(problem,interpretation,var_o1); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_o2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_l); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_root); + find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); +} +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); +} +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFSObject_class(problem,interpretation,var_o1); + find mayInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mayInstanceOfDir_class(problem,interpretation,var_o1); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_o2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_l); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_root); + find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); +} +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFSObject_class(problem,interpretation,var_o1); + find mayInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mayInstanceOfDir_class(problem,interpretation,var_o1); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_o2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_l); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_root); + find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); +} +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FileSystem class". + */ +private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FileSystem class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FileSystem class"); +} + +/** + * An element may be an instance of type "FileSystem class". + */ +private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FSObject class". + */ +private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FSObject class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FSObject class"); +} + +/** + * An element may be an instance of type "FSObject class". + */ +private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFSObject_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFSObject_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Dir class". + */ +private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Dir class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Dir class"); +} + +/** + * An element may be an instance of type "Dir class". + */ +private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewDir_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfDir_class(problem,interpretation,element); } +/** + * An element must be an instance of type "File class". + */ +private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"File class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"File class"); +} + +/** + * An element may be an instance of type "File class". + */ +private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFile_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFile_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class". + */ +private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class"); +} + +/** + * An element may be an instance of type "Model class". + */ +private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class DefinedPart". + */ +private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class DefinedPart"); +} + +/** + * An element may be an instance of type "Model class DefinedPart". + */ +private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Model class UndefinedPart". + */ +private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Model class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Model class UndefinedPart"); +} + +/** + * An element may be an instance of type "Model class UndefinedPart". + */ +private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); + neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []root reference FileSystem(source,target) + */ +private pattern mustInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>root reference FileSystem(source,target) + */ +private pattern mayInRelationroot_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFileSystem_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mustInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []live reference FileSystem(source,target) + */ + private pattern mayInRelationlive_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) + { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); + } +/** + * Matcher for detecting tuples t where []parent reference FSObject(source,target) + */ +private pattern mustInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FSObject(source,target) + */ +private pattern mayInRelationparent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFSObject_class(problem,interpretation,source); + find mayInstanceOfDir_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []contents reference Dir(source,target) + */ +private pattern mustInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>contents reference Dir(source,target) + */ +private pattern mayInRelationcontents_reference_Dir( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfDir_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []filesystems reference Model(source,target) + */ +private pattern mustInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>filesystems reference Model(source,target) + */ +private pattern mayInRelationfilesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFileSystem_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) + */ +private pattern mustInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) + */ +private pattern mayInRelationotherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfModel_class(problem,interpretation,source); + find mayInstanceOfFSObject_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFSObject_class(problem,interpretation,var_o1); + find mayInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mayInstanceOfDir_class(problem,interpretation,var_o1); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_o2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_o1, var_o2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,var_o1); + find mustInstanceOfFSObject_class(problem,interpretation,var_o2); + // o1 is exported + // o2 is exported + find mustInstanceOfDir_class(problem,interpretation,var_o1); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_o2; +} +private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_l); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mayInstanceOfFileSystem_class(problem,interpretation,var_this); + find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mayInstanceOfDir_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_root); + find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( + problem:LogicProblem, interpretation:PartialInterpretation, + var_this, var_l) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_l; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInstanceOfFSObject_class(problem,interpretation,var_l); + // this is exported + // l is exported + find mustInstanceOfFileSystem_class(problem,interpretation,var_this); + find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); + find mustInstanceOfDir_class(problem,interpretation,var_virtual0); + var_virtual0 == var_root; + find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfDir_class(problem,interpretation,var_parent); + find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_child); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInstanceOfFSObject_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfDir_class(problem,interpretation,var_parent); + find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); + var_virtual0 == var_child; + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or + + { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + + { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + + { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFile_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfDir_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Dir_class_by_root_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); + find mustInstanceOfFileSystem_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Dir_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + find mayInstanceOfDir_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class_by_filesystems_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FileSystem_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Model_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); + find mustInstanceOfDir_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class_by_otherFSObjects_reference_Model( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); + find mustInstanceOfModel_class(problem,interpretation,container); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_File_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + find mayInstanceOfFile_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); +} +pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFSObject_class(problem,interpretation,element); +} +pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfDir_class(problem,interpretation,element); + neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + neg find mustInstanceOfFile_class(problem,interpretation,element); + neg find mustInstanceOfModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_live_reference_FileSystem( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFileSystem_class(problem,interpretation,from); + find mustInstanceOfFSObject_class(problem,interpretation,to); + find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); + neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem index b744bf95..991c88fd 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem @@ -1,33 +1,23 @@ - - - - - - - - - - - - - - - - - - - + + + + + + + + + - + - + - + @@ -35,24 +25,24 @@ - + - + - + - + - + - + @@ -66,24 +56,24 @@ - + - + - + - + - + - + @@ -97,75 +87,220 @@ - + - + - - + + + + + + + + + + + + + + + + + - - - - + + + + + + + + + + + + + + + + - - - + + + + + - + - + - - - + + + - - - + + + - + + + + + + + + + + + + + + + + + + + + + + - - + - + - + - - + + + + + + - - + + + + + + + + + + + + + + + + - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel index ead2b44e..6c0e5571 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel @@ -37,53 +37,25 @@ - + - + - + - + - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - @@ -94,13 +66,4 @@ - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt index 4d22da6b..162931cc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt @@ -1 +1 @@ -Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finished \ No newline at end of file +Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Model generation startedProblem is consistent, 2 models are generated!Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is inconsistent, no model is created!Model generation finishedModel generation startedProblem is inconsistent, no model is created!Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml index 4c5b2e7d..e73f85db 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml @@ -477,3 +477,4307 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "parent reference FSObject" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "contents reference Dir" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png index d9b7c988..605b244d 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi index f6b5a41e..ffc48f68 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi @@ -1,9 +1,9 @@ - - - - - - - - + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml index f07ae0db..57d704cf 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml @@ -477,3 +477,3695 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Model class DefinedPart + Model class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FileSystem class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + Dir class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 123.20000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FSObject class + File class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "root reference FileSystem" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "filesystems reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "otherFSObjects reference Model" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png index 38dadff8..1fddfd99 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi index bc0e55cc..6b9900e2 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi @@ -1,9 +1,8 @@ - - - - - - - - + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv index ee8829e5..d1c8d98d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv @@ -1,2 +1,22 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime 1;1;ModelResultImpl;335;2777;2544;7194393100;105;140;61;186;9;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;120;2483;7934;1838851300;477;3162;36;100;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;InconsistencyResultImpl;20;2258;2771;12900;42;12;1;0;0 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;InconsistencyResultImpl;14;2066;3146;29000;439;14;13;0;0 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;15;1857;2520;3998461000;169;207;102;9;4;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;70;2695;2815;3409332300;111;133;61;18;3;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;16;2246;2987;3347793300;168;362;201;7;6;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;6;839;711;3017372100;45;206;107;9;7;0;1 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;5;879;674;2970538700;33;111;55;7;2;0;1 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;5;882;742;2902370500;64;203;110;9;6;0;1 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;10;1041;730;3174826600;23;31;19;12;0;0;1 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index efdbb9b2..a09e1cf4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -1,26 +1,146 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql new file mode 100644 index 00000000..9af35b50 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql @@ -0,0 +1,29 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries + +import epackage "http://www.eclipse.org/emf/2002/Ecore" + +pattern directSupertype(a: EClass, b:EClass) { + EClass.eSuperTypes(a,b); +} + +@Constraint(key={a}, severity="error", message="error") +pattern loopInInheritence(a: EClass) { + find directSupertype+(a,a); +} + +pattern opposite(a:EReference, b: EReference) { + EReference.eOpposite(a,b); +} +@Constraint(key={a}, severity="error", message="error") +pattern oppositeDifferentClass(a:EReference) { + EReference.eOpposite(a,b); + EReference.eContainingClass(a,aContaining); + EReference.eType(b,bTarget); + aContaining != bTarget; +} + +@Constraint(key={a}, severity="error", message="error") +pattern nonSymmetricOpposite(a:EReference, b:EReference) { + find opposite(a,b); + neg find opposite(b,a); +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql new file mode 100644 index 00000000..02d34dcd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql @@ -0,0 +1,103 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries + +import "FamMetamodel" + +@Constraint(message="terminatorAndInformation", severity="error", key={T}) +pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { + FunctionalOutput.outgoingLinks(Out,I); + FunctionalOutput.terminator(Out,T); +} or { + InformationLink.to(I,In); + FunctionalInput.terminator(In,T); +} + +@QueryBasedFeature +pattern type(This : Function, Target : FunctionType) = { + find rootElements(_Model, This); + Target == FunctionType::Root; +} or { + neg find parent(_Child, This); + neg find rootElements(_Model, This); + Target == FunctionType::Leaf; +} or { + find parent(This, _Par); + find parent(_Child, This); + Target == FunctionType::Intermediate; +} + +pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { + FunctionalArchitectureModel.rootElements(Model, Root); +} + +pattern parent(Func : Function, Par : Function) = { + Function.parent(Func, Par); +} + +@QueryBasedFeature +pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { + FunctionalElement(This); + FunctionalArchitectureModel(Target); +} + +/* +@Constraint(message="noRoot", severity="error", key={fam}) +pattern noRoot(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasRoot(_); +} +@Constraint(message="noIntermediate", severity="error", key={fam}) +pattern noInt(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasInt(_); +} +@Constraint(message="noLeaf", severity="error", key={fam}) +pattern noLeaf(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasLeaf(_); +} +*/ + +/* +@QueryBasedFeature +pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { + find parent+(This, Parent); + find rootElements(Target, Parent); +} or { + find rootElements(Target, This); +} + +pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { + FunctionalInterface.data(FI, FD); +} + +@QueryBasedFeature +pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.outputs(This, Output); + InformationLink.from(Target, Output); +} + +@QueryBasedFeature +pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.inputs(This, Input); + InformationLink.to(Target, Input); +} + +@QueryBasedFeature +pattern connects(This : FunctionalElement, Target : FunctionalElement) = { + FunctionalElement.outgoingLinks(This,Link); + FunctionalElement.incomingLinks(Target,Link); +}*/ + +/*pattern frequency(a: Function, b : EInt) { + Function.minimumFrequency(a,b); +}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystemPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystemPatterns.vql new file mode 100644 index 00000000..269a4242 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystemPatterns.vql @@ -0,0 +1,24 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries + +import epackage "FileSystemMetamodel" + +pattern patternContent(o1: FSObject, o2: FSObject) { + Dir.contents(o1,o2); +} + +@QueryBasedFeature +pattern live(this: FileSystem, l: FSObject) { + FileSystem.root(this,l); +} or { + FileSystem.root(this,root); + find patternContent+(root,l); +} + +@Constraint(key={child}, severity="error", message="error") +pattern contentInNotLive(parent : Dir, child: FSObject) { + Dir.contents(parent,child); + neg find live(_,parent); +} or { + Dir.contents(parent,child); + neg find live(_,child); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql new file mode 100644 index 00000000..2e498670 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql @@ -0,0 +1,270 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries + +import epackage "YakinduMetamodel" + +///////// +// Entry +///////// + +pattern entryInRegion_M0(r1 : Region, e1 : Entry) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M1(r1 : Region, e1) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M2(r1 : Region, e1: Entry) { + // For positive constraint + Region(r1);Entry(e1); +} + + +//@Constraint(severity="error", message="error", key = {r1}) +pattern noEntryInRegion_M0(r1 : Region) { + neg find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M1(r1 : Region) { + neg find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M2(r1 : Region) { + neg find entryInRegion_M2(r1, _); +} +pattern noEntryInRegion_M3(r1 : Region) { + find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M4(r1 : Region) { + find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M5(r1 : Region) { + find entryInRegion_M2(r1, _); +} + +//@Constraint(severity="error", message="error", key = {r}) +pattern multipleEntryInRegion_M0(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M1(r : Region) { + find entryInRegion_M1(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M2(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M3(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M1(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M4(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M2(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M5(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); +} + + +pattern transition_M0(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t, trg); +} +pattern transition_M1(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Vertex(trg); +} +pattern transition_M2(t : Transition, src : Vertex, trg : Vertex) { + Vertex(src); + Transition.target(t, trg); +} +pattern transition_M3(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t_x, src); + Transition.target(t, trg); +} +pattern transition_M4(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t_x, trg); +} + +//@Constraint(severity="error", message="error", key = {e}) +pattern incomingToEntry_M0(t : Transition, e : Entry) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_1(t : Transition, e) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_2(t : Transition, e : Entry) { + find transition_M1(t, _, e); +} +pattern incomingToEntry_3(t : Transition, e : Entry) { + find transition_M2(t, _, e); +} +pattern incomingToEntry_4(t : Transition, e : Entry) { + find transition_M3(t, _, e); +} +pattern incomingToEntry_5(t : Transition, e : Entry) { + find transition_M4(t, _, e); +} + +pattern noOutgoingTransitionFromEntry_M0(e : Entry) { + neg find transition_M0(_, e, _); +} + +pattern noOutgoingTransitionFromEntry_M1(e) { + Vertex(e); + neg find transition_M0(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M2(e : Entry) { + neg find transition_M1(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M3(e : Entry) { + neg find transition_M2(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M4(e : Entry) { + neg find transition_M3(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M5(e : Entry) { + neg find transition_M4(_, e, _); +} + + +//@Constraint(severity="error", message="error", key = {e}) +pattern multipleTransitionFromEntry_M0(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M1(e, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M2(e : Entry, t1 : Transition, t2: Transition) { + Transition(t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M3(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Transition(t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M4(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); +} + +///////// +// Exit +///////// + +//@Constraint(severity="error", message="error", key = {e}) +pattern outgoingFromExit_M0(t : Transition, e : Exit) { + Exit.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M1(t : Transition, e) { + Vertex.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M2(t : Transition, e : Exit) { + Transition(t); + Exit(e); +} + +///////// +// Final +///////// + +//@Constraint(severity="error", message="error", key = {f}) +pattern outgoingFromFinal_M0(t : Transition, f : FinalState) { + FinalState.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M1(t : Transition, f) { + Vertex.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M2(t : Transition, f : FinalState) { + Transition(t); + FinalState(f); +} + +///////// +// State vs Region +///////// + +//@Constraint(severity="error", message="error", key = {region}) +pattern noStateInRegion_M0(region: Region) { + neg find StateInRegion_M0(region,_); +} +pattern noStateInRegion_M1(region: Region) { + neg find StateInRegion_M1(region,_); +} +pattern noStateInRegion_M2(region: Region) { + neg find StateInRegion_M2(region,_); +} +pattern noStateInRegion_M3(region: Region) { + find StateInRegion_M0(region,_); +} + +pattern StateInRegion_M0(region: Region, state: State) { + Region.vertices(region,state); +} +pattern StateInRegion_M1(region: Region, state) { + Region.vertices(region,state); +} +pattern StateInRegion_M2(region: Region, state:State) { + Region(region);State(state); +} + +///////// +// Choice +///////// + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoOutgoing_M0(c : Choice) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M1(c:Vertex) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M2(c : Choice) { + neg find transition_M1(_, c, _); +} +pattern choiceHasNoOutgoing_M3(c : Choice) { + neg find transition_M2(_, c, _); +} +pattern choiceHasNoOutgoing_M4(c : Choice) { + neg find transition_M3(_, c, _); +} +pattern choiceHasNoOutgoing_M5(c : Choice) { + neg find transition_M4(_, c, _); +} +pattern choiceHasNoOutgoing_M6(c : Choice) { + find transition_M0(_, c, _); +} + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoIncoming_M0(c: Choice) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M1(c:Vertex) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M2(c: Choice) { + neg find transition_M1(_, _, c); +} +pattern choiceHasNoIncoming_M3(c: Choice) { + neg find transition_M2(_, _, c); +} +pattern choiceHasNoIncoming_M4(c: Choice) { + neg find transition_M3(_, _, c); +} +pattern choiceHasNoIncoming_M5(c: Choice) { + neg find transition_M4(_, _, c); +} +pattern choiceHasNoIncoming_M6(c: Choice) { + find transition_M0(_, _, c); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql new file mode 100644 index 00000000..597b1691 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql @@ -0,0 +1,227 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries + +import epackage "YakinduMetamodel" + +///////// +// Entry +///////// + +pattern entryInRegion(r1 : Region, e1 : Entry) { + Region.vertices(r1, e1); +} + +@Constraint(severity="error", message="error", key = {r1}) +pattern noEntryInRegion(r1 : Region) { + neg find entryInRegion(r1, _); +} + +@Constraint(severity="error", message="error", key = {r}) +pattern multipleEntryInRegion(r : Region) { + find entryInRegion(r, e1); + find entryInRegion(r, e2); + e1 != e2; +} + +pattern transition(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t, trg); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern incomingToEntry(t : Transition, e : Entry) { + find transition(t, _, e); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern noOutgoingTransitionFromEntry(e : Entry) { + neg find transition(_, e, _); +} + +@Constraint(severity="error", message="error", key = {e}) +pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} + +///////// +// Exit +///////// + +@Constraint(severity="error", message="error", key = {e}) +pattern outgoingFromExit(t : Transition, e : Exit) { + Exit.outgoingTransitions(e,t); +} + +///////// +// Final +///////// + +@Constraint(severity="error", message="error", key = {f}) +pattern outgoingFromFinal(t : Transition, f : FinalState) { + FinalState.outgoingTransitions(f,t); +} + +///////// +// State vs Region +///////// + +@Constraint(severity="error", message="error", key = {region}) +pattern noStateInRegion(region: Region) { + neg find StateInRegion(region,_); +} +pattern StateInRegion(region: Region, state: State) { + Region.vertices(region,state); +} + +///////// +// Choice +///////// + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoOutgoing(c : Choice) { + neg find transition(_, c, _); +} + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoIncoming(c: Choice) { + neg find transition(_, _, c); +} + +///////// +// Synchronization +///////// + +@Constraint(severity="error", message="error", key = {s}) +pattern synchHasNoOutgoing(s : Synchronization) { + neg find transition(_, s, _); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern synchHasNoIncoming(s : Synchronization) { + neg find transition(_, _, s); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) { + find transition(t1, v1, s); + find transition(t2, v2, s); + t1!=t2; + Region.vertices(r, v1); + Region.vertices(r, v2); +} or { + find transition(t1, s, v1); + find transition(t2, s, v2); + t1!=t2; + Region.vertices(r, v1); + Region.vertices(r, v2); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern notSynchronizingStates(s : Synchronization) { + neg find hasMultipleOutgoingTrainsition(s); + neg find hasMultipleIncomingTrainsition(s); +} + +pattern hasMultipleOutgoingTrainsition(v : Synchronization) { + find transition(_, v, trg1); + find transition(_, v, trg2); + trg1 != trg2; +} + +pattern hasMultipleIncomingTrainsition(v : Synchronization) { + find transition(_, src1, v); + find transition(_, src2, v); + src1 != src2; +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) { + find transition(_, v1, s); + find transition(_, v2, s); + CompositeElement.regions.vertices(r1, v1); + CompositeElement.regions.vertices(r2, v2); + r1 != r2; +} or { + find transition(_, s, v1); + find transition(_, s, v2); + CompositeElement.regions.vertices(r1, v1); + CompositeElement.regions.vertices(r2, v2); + r1 != r2; +} + +/////////////////////////////// +// Extra +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) { +// find transition(_, v, s); +// neg find child(_,v); +//} or { +// find transition(_, s, v); +// neg find child(_,v); +//} + +pattern child(parent: CompositeElement, child: Vertex) { + CompositeElement.regions.vertices(parent, child); +} + +@Constraint(severity="error", message="error", key = {s}) +pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) { + find transition(_, v, s); + find child(c,v); + neg find hasMultipleRegions(c); +} or { + find transition(_, s, v); + find child(c,v); + neg find hasMultipleRegions(c); +} + + +pattern hasMultipleRegions(composite: CompositeElement) { + CompositeElement.regions(composite,region1); + CompositeElement.regions(composite,region2); + region1 != region2; +} + +/** + * Simplifying model generation + */ +@Constraint(severity="error", message="error", key = {s}) +pattern synchThree(s: Synchronization) { + Transition.target(t1,s); + Transition.target(t2,s); + Transition.target(t3,s); + t1!=t2; + t2!=t3; + t1!=t3; +} or { + Transition.source(t1,s); + Transition.source(t2,s); + Transition.source(t3,s); + t1!=t2; + t2!=t3; + t1!=t3; +} + +/** + * Simplifying model generation + */ +@Constraint(severity="error", message="error", key = {s1,s2}) +pattern twoSynch(s1 : Synchronization, s2 : Synchronization) { + Synchronization(s1); + Synchronization(s2); + s1 != s2; +} + +/** + * Model generation task: at least one synch + */ +//@Constraint(severity="error", message="error", key = {s}) +//pattern noSynch(s:Statechart) { +// Statechart(s); +// neg find synch(_); +//} +//pattern synch(s:Synchronization) { +// Synchronization(s); +//} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore new file mode 100644 index 00000000..a9786e0f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore @@ -0,0 +1,13 @@ +/.DirectSupertype.java._trace +/.Ecore.java._trace +/.LoopInInheritence.java._trace +/.NonSymmetricOpposite.java._trace +/.Opposite.java._trace +/.OppositeDifferentClass.java._trace +/.EcorePatterns.java._trace +/DirectSupertype.java +/EcorePatterns.java +/LoopInInheritence.java +/NonSymmetricOpposite.java +/Opposite.java +/OppositeDifferentClass.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore new file mode 100644 index 00000000..60f1891b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore @@ -0,0 +1,10 @@ +/.FamPatterns.java._trace +/.Model.java._trace +/.Parent.java._trace +/.RootElements.java._trace +/.TerminatorAndInformation.java._trace +/.Type.java._trace +/FamPatterns.java +/Model.java +/Parent.java +/RootElements.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java new file mode 100644 index 00000000..69a6b9f4 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java @@ -0,0 +1,747 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
+ *         pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
+ *         	FunctionalOutput.outgoingLinks(Out,I);
+ *         	FunctionalOutput.terminator(Out,T); 
+ *         } or {
+ *         	InformationLink.to(I,In);
+ *         	FunctionalInput.terminator(In,T);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class TerminatorAndInformation extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private FAMTerminator fT; + + private InformationLink fI; + + private static List parameterNames = makeImmutableList("T", "I"); + + private Match(final FAMTerminator pT, final InformationLink pI) { + this.fT = pT; + this.fI = pI; + } + + @Override + public Object get(final String parameterName) { + if ("T".equals(parameterName)) return this.fT; + if ("I".equals(parameterName)) return this.fI; + return null; + } + + public FAMTerminator getT() { + return this.fT; + } + + public InformationLink getI() { + return this.fI; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("T".equals(parameterName) ) { + this.fT = (FAMTerminator) newValue; + return true; + } + if ("I".equals(parameterName) ) { + this.fI = (InformationLink) newValue; + return true; + } + return false; + } + + public void setT(final FAMTerminator pT) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT = pT; + } + + public void setI(final InformationLink pI) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fI = pI; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation"; + } + + @Override + public List parameterNames() { + return TerminatorAndInformation.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fT, fI}; + } + + @Override + public TerminatorAndInformation.Match toImmutable() { + return isMutable() ? newMatch(fT, fI) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"T\"=" + prettyPrintValue(fT) + ", "); + result.append("\"I\"=" + prettyPrintValue(fI)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fT, fI); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof TerminatorAndInformation.Match)) { + TerminatorAndInformation.Match other = (TerminatorAndInformation.Match) obj; + return Objects.equals(fT, other.fT) && Objects.equals(fI, other.fI); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public TerminatorAndInformation specification() { + return TerminatorAndInformation.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static TerminatorAndInformation.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static TerminatorAndInformation.Match newMutableMatch(final FAMTerminator pT, final InformationLink pI) { + return new Mutable(pT, pI); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return the (partial) match object. + * + */ + public static TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { + return new Immutable(pT, pI); + } + + private static final class Mutable extends TerminatorAndInformation.Match { + Mutable(final FAMTerminator pT, final InformationLink pI) { + super(pT, pI); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends TerminatorAndInformation.Match { + Immutable(final FAMTerminator pT, final InformationLink pI) { + super(pT, pI); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
+   * pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
+   * 	FunctionalOutput.outgoingLinks(Out,I);
+   * 	FunctionalOutput.terminator(Out,T); 
+   * } or {
+   * 	InformationLink.to(I,In);
+   * 	FunctionalInput.terminator(In,T);
+   * }
+   * 
+ * + * @see Match + * @see TerminatorAndInformation + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static TerminatorAndInformation.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static TerminatorAndInformation.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_T = 0; + + private final static int POSITION_I = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(TerminatorAndInformation.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final FAMTerminator pT, final InformationLink pI) { + return rawStreamAllMatches(new Object[]{pT, pI}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final FAMTerminator pT, final InformationLink pI) { + return rawStreamAllMatches(new Object[]{pT, pI}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI) { + return rawGetOneArbitraryMatch(new Object[]{pT, pI}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final FAMTerminator pT, final InformationLink pI) { + return rawHasMatch(new Object[]{pT, pI}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final FAMTerminator pT, final InformationLink pI) { + return rawCountMatches(new Object[]{pT, pI}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pT, pI}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter T, or null if not bound. + * @param pI the fixed value of pattern parameter I, or null if not bound. + * @return the (partial) match object. + * + */ + public TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { + return TerminatorAndInformation.Match.newMatch(pT, pI); + } + + /** + * Retrieve the set of values that occur in matches for T. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfT(final Object[] parameters) { + return rawStreamAllValues(POSITION_T, parameters).map(FAMTerminator.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for T. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfT() { + return rawStreamAllValuesOfT(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for T. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfT() { + return rawStreamAllValuesOfT(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for T. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { + return rawStreamAllValuesOfT(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for T. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfT(final InformationLink pI) { + return rawStreamAllValuesOfT(new Object[]{null, pI}); + } + + /** + * Retrieve the set of values that occur in matches for T. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { + return rawStreamAllValuesOfT(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for T. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfT(final InformationLink pI) { + return rawStreamAllValuesOfT(new Object[]{null, pI}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for I. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfI(final Object[] parameters) { + return rawStreamAllValues(POSITION_I, parameters).map(InformationLink.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for I. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfI() { + return rawStreamAllValuesOfI(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for I. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfI() { + return rawStreamAllValuesOfI(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for I. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { + return rawStreamAllValuesOfI(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for I. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfI(final FAMTerminator pT) { + return rawStreamAllValuesOfI(new Object[]{pT, null}); + } + + /** + * Retrieve the set of values that occur in matches for I. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { + return rawStreamAllValuesOfI(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for I. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfI(final FAMTerminator pT) { + return rawStreamAllValuesOfI(new Object[]{pT, null}).collect(Collectors.toSet()); + } + + @Override + protected TerminatorAndInformation.Match tupleToMatch(final Tuple t) { + try { + return TerminatorAndInformation.Match.newMatch((FAMTerminator) t.get(POSITION_T), (InformationLink) t.get(POSITION_I)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected TerminatorAndInformation.Match arrayToMatch(final Object[] match) { + try { + return TerminatorAndInformation.Match.newMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected TerminatorAndInformation.Match arrayToMatchMutable(final Object[] match) { + try { + return TerminatorAndInformation.Match.newMutableMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return TerminatorAndInformation.instance(); + } + } + + private TerminatorAndInformation() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static TerminatorAndInformation instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected TerminatorAndInformation.Matcher instantiate(final ViatraQueryEngine engine) { + return TerminatorAndInformation.Matcher.on(engine); + } + + @Override + public TerminatorAndInformation.Matcher instantiate() { + return TerminatorAndInformation.Matcher.create(); + } + + @Override + public TerminatorAndInformation.Match newEmptyMatch() { + return TerminatorAndInformation.Match.newEmptyMatch(); + } + + @Override + public TerminatorAndInformation.Match newMatch(final Object... parameters) { + return TerminatorAndInformation.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static TerminatorAndInformation INSTANCE = new TerminatorAndInformation(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static TerminatorAndInformation.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_T = new PParameter("T", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "FAMTerminator")), PParameterDirection.INOUT); + + private final PParameter parameter_I = new PParameter("I", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "InformationLink")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_T, parameter_I); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("T","I"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_T = body.getOrCreateVariableByName("T"); + PVariable var_I = body.getOrCreateVariableByName("I"); + PVariable var_Out = body.getOrCreateVariableByName("Out"); + new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_T, parameter_T), + new ExportedParameter(body, var_I, parameter_I) + )); + // FunctionalOutput.outgoingLinks(Out,I) + new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalOutput"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalOutput", "outgoingLinks"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); + new Equality(body, var__virtual_0_, var_I); + // FunctionalOutput.terminator(Out,T) + new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalOutput"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalData", "terminator"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); + new Equality(body, var__virtual_1_, var_T); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_T = body.getOrCreateVariableByName("T"); + PVariable var_I = body.getOrCreateVariableByName("I"); + PVariable var_In = body.getOrCreateVariableByName("In"); + new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_T, parameter_T), + new ExportedParameter(body, var_I, parameter_I) + )); + // InformationLink.to(I,In) + new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_I, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "InformationLink", "to"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalInput"))); + new Equality(body, var__virtual_0_, var_In); + // FunctionalInput.terminator(In,T) + new TypeConstraint(body, Tuples.flatTupleOf(var_In), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalInput"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_In, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalData", "terminator"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); + new Equality(body, var__virtual_1_, var_T); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("message", "terminatorAndInformation"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("T") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java new file mode 100644 index 00000000..bc3230c5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java @@ -0,0 +1,770 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Parent; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.RootElements; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EDataTypeInSlotsKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.ConstantValue; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}QueryBasedFeature 
+ *         pattern type(This : Function, Target : FunctionType) = {
+ *         	find rootElements(_Model, This);
+ *         	Target == FunctionType::Root;
+ *         } or {
+ *         	neg find parent(_Child, This);
+ *         	neg find rootElements(_Model, This);
+ *         	Target == FunctionType::Leaf;
+ *         } or  {
+ *         	find parent(This, _Par);
+ *         	find parent(_Child, This);
+ *         	Target == FunctionType::Intermediate;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class Type extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Function fThis; + + private FunctionType fTarget; + + private static List parameterNames = makeImmutableList("This", "Target"); + + private Match(final Function pThis, final FunctionType pTarget) { + this.fThis = pThis; + this.fTarget = pTarget; + } + + @Override + public Object get(final String parameterName) { + if ("This".equals(parameterName)) return this.fThis; + if ("Target".equals(parameterName)) return this.fTarget; + return null; + } + + public Function getThis() { + return this.fThis; + } + + public FunctionType getTarget() { + return this.fTarget; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("This".equals(parameterName) ) { + this.fThis = (Function) newValue; + return true; + } + if ("Target".equals(parameterName) ) { + this.fTarget = (FunctionType) newValue; + return true; + } + return false; + } + + public void setThis(final Function pThis) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fThis = pThis; + } + + public void setTarget(final FunctionType pTarget) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fTarget = pTarget; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"; + } + + @Override + public List parameterNames() { + return Type.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fThis, fTarget}; + } + + @Override + public Type.Match toImmutable() { + return isMutable() ? newMatch(fThis, fTarget) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"This\"=" + prettyPrintValue(fThis) + ", "); + result.append("\"Target\"=" + prettyPrintValue(fTarget)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fThis, fTarget); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof Type.Match)) { + Type.Match other = (Type.Match) obj; + return Objects.equals(fThis, other.fThis) && Objects.equals(fTarget, other.fTarget); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public Type specification() { + return Type.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static Type.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static Type.Match newMutableMatch(final Function pThis, final FunctionType pTarget) { + return new Mutable(pThis, pTarget); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return the (partial) match object. + * + */ + public static Type.Match newMatch(final Function pThis, final FunctionType pTarget) { + return new Immutable(pThis, pTarget); + } + + private static final class Mutable extends Type.Match { + Mutable(final Function pThis, final FunctionType pTarget) { + super(pThis, pTarget); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends Type.Match { + Immutable(final Function pThis, final FunctionType pTarget) { + super(pThis, pTarget); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}QueryBasedFeature 
+   * pattern type(This : Function, Target : FunctionType) = {
+   * 	find rootElements(_Model, This);
+   * 	Target == FunctionType::Root;
+   * } or {
+   * 	neg find parent(_Child, This);
+   * 	neg find rootElements(_Model, This);
+   * 	Target == FunctionType::Leaf;
+   * } or  {
+   * 	find parent(This, _Par);
+   * 	find parent(_Child, This);
+   * 	Target == FunctionType::Intermediate;
+   * }
+   * 
+ * + * @see Match + * @see Type + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static Type.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static Type.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_THIS = 0; + + private final static int POSITION_TARGET = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Type.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Function pThis, final FunctionType pTarget) { + return rawStreamAllMatches(new Object[]{pThis, pTarget}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Function pThis, final FunctionType pTarget) { + return rawStreamAllMatches(new Object[]{pThis, pTarget}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Function pThis, final FunctionType pTarget) { + return rawGetOneArbitraryMatch(new Object[]{pThis, pTarget}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Function pThis, final FunctionType pTarget) { + return rawHasMatch(new Object[]{pThis, pTarget}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Function pThis, final FunctionType pTarget) { + return rawCountMatches(new Object[]{pThis, pTarget}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Function pThis, final FunctionType pTarget, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pThis, pTarget}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pThis the fixed value of pattern parameter This, or null if not bound. + * @param pTarget the fixed value of pattern parameter Target, or null if not bound. + * @return the (partial) match object. + * + */ + public Type.Match newMatch(final Function pThis, final FunctionType pTarget) { + return Type.Match.newMatch(pThis, pTarget); + } + + /** + * Retrieve the set of values that occur in matches for This. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfThis(final Object[] parameters) { + return rawStreamAllValues(POSITION_THIS, parameters).map(Function.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for This. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfThis() { + return rawStreamAllValuesOfThis(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for This. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfThis() { + return rawStreamAllValuesOfThis(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for This. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfThis(final Type.Match partialMatch) { + return rawStreamAllValuesOfThis(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for This. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfThis(final FunctionType pTarget) { + return rawStreamAllValuesOfThis(new Object[]{null, pTarget}); + } + + /** + * Retrieve the set of values that occur in matches for This. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfThis(final Type.Match partialMatch) { + return rawStreamAllValuesOfThis(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for This. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfThis(final FunctionType pTarget) { + return rawStreamAllValuesOfThis(new Object[]{null, pTarget}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for Target. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfTarget(final Object[] parameters) { + return rawStreamAllValues(POSITION_TARGET, parameters).map(FunctionType.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for Target. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfTarget() { + return rawStreamAllValuesOfTarget(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for Target. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfTarget() { + return rawStreamAllValuesOfTarget(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for Target. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfTarget(final Type.Match partialMatch) { + return rawStreamAllValuesOfTarget(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for Target. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfTarget(final Function pThis) { + return rawStreamAllValuesOfTarget(new Object[]{pThis, null}); + } + + /** + * Retrieve the set of values that occur in matches for Target. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfTarget(final Type.Match partialMatch) { + return rawStreamAllValuesOfTarget(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for Target. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfTarget(final Function pThis) { + return rawStreamAllValuesOfTarget(new Object[]{pThis, null}).collect(Collectors.toSet()); + } + + @Override + protected Type.Match tupleToMatch(final Tuple t) { + try { + return Type.Match.newMatch((Function) t.get(POSITION_THIS), (FunctionType) t.get(POSITION_TARGET)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected Type.Match arrayToMatch(final Object[] match) { + try { + return Type.Match.newMatch((Function) match[POSITION_THIS], (FunctionType) match[POSITION_TARGET]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected Type.Match arrayToMatchMutable(final Object[] match) { + try { + return Type.Match.newMutableMatch((Function) match[POSITION_THIS], (FunctionType) match[POSITION_TARGET]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return Type.instance(); + } + } + + private Type() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static Type instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected Type.Matcher instantiate(final ViatraQueryEngine engine) { + return Type.Matcher.on(engine); + } + + @Override + public Type.Matcher instantiate() { + return Type.Matcher.create(); + } + + @Override + public Type.Match newEmptyMatch() { + return Type.Match.newEmptyMatch(); + } + + @Override + public Type.Match newMatch(final Object... parameters) { + return Type.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type (visibility: PUBLIC, simpleName: Type, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type (visibility: PUBLIC, simpleName: Type, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static Type INSTANCE = new Type(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static Type.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_This = new PParameter("This", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "Function")), PParameterDirection.INOUT); + + private final PParameter parameter_Target = new PParameter("Target", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType", new EDataTypeInSlotsKey((EDataType)getClassifierLiteralSafe("FamMetamodel", "FunctionType")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_This, parameter_Target); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("This","Target"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_This = body.getOrCreateVariableByName("This"); + PVariable var_Target = body.getOrCreateVariableByName("Target"); + PVariable var__Model = body.getOrCreateVariableByName("_Model"); + new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_This, parameter_This), + new ExportedParameter(body, var_Target, parameter_Target) + )); + // find rootElements(_Model, This) + new PositivePatternCall(body, Tuples.flatTupleOf(var__Model, var_This), RootElements.instance().getInternalQueryRepresentation()); + // Target == FunctionType::Root + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Root").getInstance()); + new Equality(body, var_Target, var__virtual_0_); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_This = body.getOrCreateVariableByName("This"); + PVariable var_Target = body.getOrCreateVariableByName("Target"); + PVariable var__Child = body.getOrCreateVariableByName("_Child"); + PVariable var__Model = body.getOrCreateVariableByName("_Model"); + new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_This, parameter_This), + new ExportedParameter(body, var_Target, parameter_Target) + )); + // neg find parent(_Child, This) + new NegativePatternCall(body, Tuples.flatTupleOf(var__Child, var_This), Parent.instance().getInternalQueryRepresentation()); + // neg find rootElements(_Model, This) + new NegativePatternCall(body, Tuples.flatTupleOf(var__Model, var_This), RootElements.instance().getInternalQueryRepresentation()); + // Target == FunctionType::Leaf + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Leaf").getInstance()); + new Equality(body, var_Target, var__virtual_0_); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_This = body.getOrCreateVariableByName("This"); + PVariable var_Target = body.getOrCreateVariableByName("Target"); + PVariable var__Par = body.getOrCreateVariableByName("_Par"); + PVariable var__Child = body.getOrCreateVariableByName("_Child"); + new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_This, parameter_This), + new ExportedParameter(body, var_Target, parameter_Target) + )); + // find parent(This, _Par) + new PositivePatternCall(body, Tuples.flatTupleOf(var_This, var__Par), Parent.instance().getInternalQueryRepresentation()); + // find parent(_Child, This) + new PositivePatternCall(body, Tuples.flatTupleOf(var__Child, var_This), Parent.instance().getInternalQueryRepresentation()); + // Target == FunctionType::Intermediate + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Intermediate").getInstance()); + new Equality(body, var_Target, var__virtual_0_); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("QueryBasedFeature"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/.gitignore new file mode 100644 index 00000000..dcc36d34 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/.gitignore @@ -0,0 +1,9 @@ +/.ContentInNotLive.java._trace +/.FileSystem.java._trace +/.Live.java._trace +/.PatternContent.java._trace +/.FileSystemPatterns.java._trace +/PatternContent.java +/ContentInNotLive.java +/FileSystemPatterns.java +/Live.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore new file mode 100644 index 00000000..96fd178f --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore @@ -0,0 +1,158 @@ +/.EntryInRegion_M0.java._trace +/.EntryInRegion_M1.java._trace +/.EntryInRegion_M2.java._trace +/.MultipleEntryInRegion_M0.java._trace +/.MultipleEntryInRegion_M1.java._trace +/.MultipleEntryInRegion_M2.java._trace +/.NoEntryInRegion_M0.java._trace +/.NoEntryInRegion_M1.java._trace +/.NoEntryInRegion_M2.java._trace +/.NoEntryInRegion_M3.java._trace +/.NoEntryInRegion_M4.java._trace +/.NoEntryInRegion_M5.java._trace +/.MultipleEntryInRegion_M3.java._trace +/.EntryInRegion.java._trace +/.MultipleEntryInRegion.java._trace +/.NoEntryInRegion.java._trace +/.Transition.java._trace +/.Child.java._trace +/.ChoiceHasNoIncoming.java._trace +/.ChoiceHasNoOutgoing.java._trace +/.HasMultipleIncomingTrainsition.java._trace +/.HasMultipleOutgoingTrainsition.java._trace +/.HasMultipleRegions.java._trace +/.IncomingToEntry.java._trace +/.MultipleTransitionFromEntry.java._trace +/.NoOutgoingTransitionFromEntry.java._trace +/.NoStateInRegion.java._trace +/.NotSynchronizingStates.java._trace +/.OutgoingFromExit.java._trace +/.OutgoingFromFinal.java._trace +/.StateInRegion.java._trace +/.SynchHasNoIncoming.java._trace +/.SynchHasNoOutgoing.java._trace +/.SynchThree.java._trace +/.SynchronizedIncomingInSameRegion.java._trace +/.SynchronizedRegionDoesNotHaveMultipleRegions.java._trace +/.SynchronizedRegionsAreNotSiblings.java._trace +/.TwoSynch.java._trace +/.YakinduPatterns.java._trace +/.ChoiceHasNoIncoming_M0.java._trace +/.ChoiceHasNoIncoming_M1.java._trace +/.ChoiceHasNoIncoming_M2.java._trace +/.ChoiceHasNoIncoming_M3.java._trace +/.ChoiceHasNoIncoming_M4.java._trace +/.ChoiceHasNoIncoming_M5.java._trace +/.ChoiceHasNoIncoming_M6.java._trace +/.ChoiceHasNoOutgoing_M0.java._trace +/.ChoiceHasNoOutgoing_M1.java._trace +/.ChoiceHasNoOutgoing_M2.java._trace +/.ChoiceHasNoOutgoing_M3.java._trace +/.ChoiceHasNoOutgoing_M4.java._trace +/.ChoiceHasNoOutgoing_M5.java._trace +/.ChoiceHasNoOutgoing_M6.java._trace +/.IncomingToEntry_1.java._trace +/.IncomingToEntry_2.java._trace +/.IncomingToEntry_3.java._trace +/.IncomingToEntry_4.java._trace +/.IncomingToEntry_5.java._trace +/.IncomingToEntry_M0.java._trace +/.MultipleEntryInRegion_M4.java._trace +/.MultipleEntryInRegion_M5.java._trace +/.MultipleTransitionFromEntry_M0.java._trace +/.MultipleTransitionFromEntry_M1.java._trace +/.MultipleTransitionFromEntry_M2.java._trace +/.MultipleTransitionFromEntry_M3.java._trace +/.MultipleTransitionFromEntry_M4.java._trace +/.NoOutgoingTransitionFromEntry_M0.java._trace +/.NoOutgoingTransitionFromEntry_M1.java._trace +/.NoOutgoingTransitionFromEntry_M2.java._trace +/.NoOutgoingTransitionFromEntry_M3.java._trace +/.NoOutgoingTransitionFromEntry_M4.java._trace +/.NoOutgoingTransitionFromEntry_M5.java._trace +/.NoStateInRegion_M0.java._trace +/.NoStateInRegion_M1.java._trace +/.NoStateInRegion_M2.java._trace +/.NoStateInRegion_M3.java._trace +/.OutgoingFromExit_M0.java._trace +/.OutgoingFromExit_M1.java._trace +/.OutgoingFromExit_M2.java._trace +/.OutgoingFromFinal_M0.java._trace +/.OutgoingFromFinal_M1.java._trace +/.OutgoingFromFinal_M2.java._trace +/.StateInRegion_M0.java._trace +/.StateInRegion_M1.java._trace +/.StateInRegion_M2.java._trace +/.Transition_M0.java._trace +/.Transition_M1.java._trace +/.Transition_M2.java._trace +/.Transition_M3.java._trace +/.Transition_M4.java._trace +/.YakinduMutatedPatterns.java._trace +/YakinduPatterns.java +/MultipleEntryInRegion.java +/ChoiceHasNoIncoming_M0.java +/ChoiceHasNoIncoming_M1.java +/ChoiceHasNoIncoming_M2.java +/ChoiceHasNoIncoming_M3.java +/ChoiceHasNoIncoming_M4.java +/ChoiceHasNoIncoming_M5.java +/ChoiceHasNoIncoming_M6.java +/ChoiceHasNoOutgoing_M0.java +/ChoiceHasNoOutgoing_M1.java +/ChoiceHasNoOutgoing_M2.java +/ChoiceHasNoOutgoing_M3.java +/ChoiceHasNoOutgoing_M4.java +/ChoiceHasNoOutgoing_M5.java +/ChoiceHasNoOutgoing_M6.java +/EntryInRegion_M0.java +/EntryInRegion_M1.java +/EntryInRegion_M2.java +/IncomingToEntry_1.java +/IncomingToEntry_2.java +/IncomingToEntry_3.java +/IncomingToEntry_4.java +/IncomingToEntry_5.java +/IncomingToEntry_M0.java +/MultipleEntryInRegion_M0.java +/MultipleEntryInRegion_M1.java +/MultipleEntryInRegion_M2.java +/MultipleEntryInRegion_M3.java +/MultipleEntryInRegion_M4.java +/MultipleEntryInRegion_M5.java +/MultipleTransitionFromEntry_M0.java +/MultipleTransitionFromEntry_M1.java +/MultipleTransitionFromEntry_M2.java +/MultipleTransitionFromEntry_M3.java +/MultipleTransitionFromEntry_M4.java +/NoEntryInRegion_M0.java +/NoEntryInRegion_M1.java +/NoEntryInRegion_M2.java +/NoEntryInRegion_M3.java +/NoEntryInRegion_M4.java +/NoEntryInRegion_M5.java +/NoOutgoingTransitionFromEntry_M0.java +/NoOutgoingTransitionFromEntry_M1.java +/NoOutgoingTransitionFromEntry_M2.java +/NoOutgoingTransitionFromEntry_M3.java +/NoOutgoingTransitionFromEntry_M4.java +/NoOutgoingTransitionFromEntry_M5.java +/NoStateInRegion_M0.java +/NoStateInRegion_M1.java +/NoStateInRegion_M2.java +/NoStateInRegion_M3.java +/OutgoingFromExit_M0.java +/OutgoingFromExit_M1.java +/OutgoingFromExit_M2.java +/OutgoingFromFinal_M0.java +/OutgoingFromFinal_M1.java +/OutgoingFromFinal_M2.java +/StateInRegion_M0.java +/StateInRegion_M1.java +/StateInRegion_M2.java +/Transition_M0.java +/Transition_M1.java +/Transition_M2.java +/Transition_M3.java +/Transition_M4.java +/YakinduMutatedPatterns.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java new file mode 100644 index 00000000..9867c1ee --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java @@ -0,0 +1,721 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         ///////////////////////////////
+ *         // Extra
+ *         //
+ *         //{@literal @}Constraint(severity="error", message="error", key = {s})
+ *         //pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) {
+ *         //	find transition(_, v, s);
+ *         //	neg find child(_,v);
+ *         //} or {
+ *         //	find transition(_, s, v);
+ *         //	neg find child(_,v);
+ *         //}
+ *         
+ *         pattern child(parent: CompositeElement, child: Vertex) {
+ *         	CompositeElement.regions.vertices(parent, child);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class Child extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private CompositeElement fParent; + + private Vertex fChild; + + private static List parameterNames = makeImmutableList("parent", "child"); + + private Match(final CompositeElement pParent, final Vertex pChild) { + this.fParent = pParent; + this.fChild = pChild; + } + + @Override + public Object get(final String parameterName) { + if ("parent".equals(parameterName)) return this.fParent; + if ("child".equals(parameterName)) return this.fChild; + return null; + } + + public CompositeElement getParent() { + return this.fParent; + } + + public Vertex getChild() { + return this.fChild; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("parent".equals(parameterName) ) { + this.fParent = (CompositeElement) newValue; + return true; + } + if ("child".equals(parameterName) ) { + this.fChild = (Vertex) newValue; + return true; + } + return false; + } + + public void setParent(final CompositeElement pParent) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fParent = pParent; + } + + public void setChild(final Vertex pChild) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fChild = pChild; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child"; + } + + @Override + public List parameterNames() { + return Child.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fParent, fChild}; + } + + @Override + public Child.Match toImmutable() { + return isMutable() ? newMatch(fParent, fChild) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"parent\"=" + prettyPrintValue(fParent) + ", "); + result.append("\"child\"=" + prettyPrintValue(fChild)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fParent, fChild); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof Child.Match)) { + Child.Match other = (Child.Match) obj; + return Objects.equals(fParent, other.fParent) && Objects.equals(fChild, other.fChild); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public Child specification() { + return Child.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static Child.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static Child.Match newMutableMatch(final CompositeElement pParent, final Vertex pChild) { + return new Mutable(pParent, pChild); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the (partial) match object. + * + */ + public static Child.Match newMatch(final CompositeElement pParent, final Vertex pChild) { + return new Immutable(pParent, pChild); + } + + private static final class Mutable extends Child.Match { + Mutable(final CompositeElement pParent, final Vertex pChild) { + super(pParent, pChild); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends Child.Match { + Immutable(final CompositeElement pParent, final Vertex pChild) { + super(pParent, pChild); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * ///////////////////////////////
+   * // Extra
+   * //
+   * //{@literal @}Constraint(severity="error", message="error", key = {s})
+   * //pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) {
+   * //	find transition(_, v, s);
+   * //	neg find child(_,v);
+   * //} or {
+   * //	find transition(_, s, v);
+   * //	neg find child(_,v);
+   * //}
+   * 
+   * pattern child(parent: CompositeElement, child: Vertex) {
+   * 	CompositeElement.regions.vertices(parent, child);
+   * }
+   * 
+ * + * @see Match + * @see Child + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static Child.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static Child.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_PARENT = 0; + + private final static int POSITION_CHILD = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Child.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final CompositeElement pParent, final Vertex pChild) { + return rawStreamAllMatches(new Object[]{pParent, pChild}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final CompositeElement pParent, final Vertex pChild) { + return rawStreamAllMatches(new Object[]{pParent, pChild}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final CompositeElement pParent, final Vertex pChild) { + return rawGetOneArbitraryMatch(new Object[]{pParent, pChild}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final CompositeElement pParent, final Vertex pChild) { + return rawHasMatch(new Object[]{pParent, pChild}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final CompositeElement pParent, final Vertex pChild) { + return rawCountMatches(new Object[]{pParent, pChild}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final CompositeElement pParent, final Vertex pChild, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pParent, pChild}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the (partial) match object. + * + */ + public Child.Match newMatch(final CompositeElement pParent, final Vertex pChild) { + return Child.Match.newMatch(pParent, pChild); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfparent(final Object[] parameters) { + return rawStreamAllValues(POSITION_PARENT, parameters).map(CompositeElement.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent() { + return rawStreamAllValuesOfparent(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent() { + return rawStreamAllValuesOfparent(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent(final Child.Match partialMatch) { + return rawStreamAllValuesOfparent(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent(final Vertex pChild) { + return rawStreamAllValuesOfparent(new Object[]{null, pChild}); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent(final Child.Match partialMatch) { + return rawStreamAllValuesOfparent(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent(final Vertex pChild) { + return rawStreamAllValuesOfparent(new Object[]{null, pChild}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfchild(final Object[] parameters) { + return rawStreamAllValues(POSITION_CHILD, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild() { + return rawStreamAllValuesOfchild(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild() { + return rawStreamAllValuesOfchild(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for child. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild(final Child.Match partialMatch) { + return rawStreamAllValuesOfchild(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for child. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild(final CompositeElement pParent) { + return rawStreamAllValuesOfchild(new Object[]{pParent, null}); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild(final Child.Match partialMatch) { + return rawStreamAllValuesOfchild(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild(final CompositeElement pParent) { + return rawStreamAllValuesOfchild(new Object[]{pParent, null}).collect(Collectors.toSet()); + } + + @Override + protected Child.Match tupleToMatch(final Tuple t) { + try { + return Child.Match.newMatch((CompositeElement) t.get(POSITION_PARENT), (Vertex) t.get(POSITION_CHILD)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected Child.Match arrayToMatch(final Object[] match) { + try { + return Child.Match.newMatch((CompositeElement) match[POSITION_PARENT], (Vertex) match[POSITION_CHILD]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected Child.Match arrayToMatchMutable(final Object[] match) { + try { + return Child.Match.newMutableMatch((CompositeElement) match[POSITION_PARENT], (Vertex) match[POSITION_CHILD]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return Child.instance(); + } + } + + private Child() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static Child instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected Child.Matcher instantiate(final ViatraQueryEngine engine) { + return Child.Matcher.on(engine); + } + + @Override + public Child.Matcher instantiate() { + return Child.Matcher.create(); + } + + @Override + public Child.Match newEmptyMatch() { + return Child.Match.newEmptyMatch(); + } + + @Override + public Child.Match newMatch(final Object... parameters) { + return Child.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child (visibility: PUBLIC, simpleName: Child, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child (visibility: PUBLIC, simpleName: Child, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static Child INSTANCE = new Child(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static Child.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_parent = new PParameter("parent", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "CompositeElement")), PParameterDirection.INOUT); + + private final PParameter parameter_child = new PParameter("child", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_parent, parameter_child); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("parent","child"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_parent = body.getOrCreateVariableByName("parent"); + PVariable var_child = body.getOrCreateVariableByName("child"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_child), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_parent, parameter_parent), + new ExportedParameter(body, var_child, parameter_child) + )); + // CompositeElement.regions.vertices(parent, child) + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_child); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java new file mode 100644 index 00000000..8e62ee9d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java @@ -0,0 +1,551 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {c})
+ *         pattern choiceHasNoIncoming(c: Choice) {
+ *         	neg find transition(_, _, c);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class ChoiceHasNoIncoming extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Choice fC; + + private static List parameterNames = makeImmutableList("c"); + + private Match(final Choice pC) { + this.fC = pC; + } + + @Override + public Object get(final String parameterName) { + if ("c".equals(parameterName)) return this.fC; + return null; + } + + public Choice getC() { + return this.fC; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("c".equals(parameterName) ) { + this.fC = (Choice) newValue; + return true; + } + return false; + } + + public void setC(final Choice pC) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fC = pC; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming"; + } + + @Override + public List parameterNames() { + return ChoiceHasNoIncoming.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fC}; + } + + @Override + public ChoiceHasNoIncoming.Match toImmutable() { + return isMutable() ? newMatch(fC) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"c\"=" + prettyPrintValue(fC)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fC); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof ChoiceHasNoIncoming.Match)) { + ChoiceHasNoIncoming.Match other = (ChoiceHasNoIncoming.Match) obj; + return Objects.equals(fC, other.fC); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public ChoiceHasNoIncoming specification() { + return ChoiceHasNoIncoming.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static ChoiceHasNoIncoming.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static ChoiceHasNoIncoming.Match newMutableMatch(final Choice pC) { + return new Mutable(pC); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the (partial) match object. + * + */ + public static ChoiceHasNoIncoming.Match newMatch(final Choice pC) { + return new Immutable(pC); + } + + private static final class Mutable extends ChoiceHasNoIncoming.Match { + Mutable(final Choice pC) { + super(pC); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends ChoiceHasNoIncoming.Match { + Immutable(final Choice pC) { + super(pC); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {c})
+   * pattern choiceHasNoIncoming(c: Choice) {
+   * 	neg find transition(_, _, c);
+   * }
+   * 
+ * + * @see Match + * @see ChoiceHasNoIncoming + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static ChoiceHasNoIncoming.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static ChoiceHasNoIncoming.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_C = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(ChoiceHasNoIncoming.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Choice pC) { + return rawStreamAllMatches(new Object[]{pC}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Choice pC) { + return rawStreamAllMatches(new Object[]{pC}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Choice pC) { + return rawGetOneArbitraryMatch(new Object[]{pC}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Choice pC) { + return rawHasMatch(new Object[]{pC}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Choice pC) { + return rawCountMatches(new Object[]{pC}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Choice pC, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pC}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the (partial) match object. + * + */ + public ChoiceHasNoIncoming.Match newMatch(final Choice pC) { + return ChoiceHasNoIncoming.Match.newMatch(pC); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfc(final Object[] parameters) { + return rawStreamAllValues(POSITION_C, parameters).map(Choice.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfc() { + return rawStreamAllValuesOfc(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfc() { + return rawStreamAllValuesOfc(emptyArray()); + } + + @Override + protected ChoiceHasNoIncoming.Match tupleToMatch(final Tuple t) { + try { + return ChoiceHasNoIncoming.Match.newMatch((Choice) t.get(POSITION_C)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected ChoiceHasNoIncoming.Match arrayToMatch(final Object[] match) { + try { + return ChoiceHasNoIncoming.Match.newMatch((Choice) match[POSITION_C]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected ChoiceHasNoIncoming.Match arrayToMatchMutable(final Object[] match) { + try { + return ChoiceHasNoIncoming.Match.newMutableMatch((Choice) match[POSITION_C]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return ChoiceHasNoIncoming.instance(); + } + } + + private ChoiceHasNoIncoming() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static ChoiceHasNoIncoming instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected ChoiceHasNoIncoming.Matcher instantiate(final ViatraQueryEngine engine) { + return ChoiceHasNoIncoming.Matcher.on(engine); + } + + @Override + public ChoiceHasNoIncoming.Matcher instantiate() { + return ChoiceHasNoIncoming.Matcher.create(); + } + + @Override + public ChoiceHasNoIncoming.Match newEmptyMatch() { + return ChoiceHasNoIncoming.Match.newEmptyMatch(); + } + + @Override + public ChoiceHasNoIncoming.Match newMatch(final Object... parameters) { + return ChoiceHasNoIncoming.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming (visibility: PUBLIC, simpleName: ChoiceHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming (visibility: PUBLIC, simpleName: ChoiceHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static ChoiceHasNoIncoming INSTANCE = new ChoiceHasNoIncoming(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static ChoiceHasNoIncoming.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_c = new PParameter("c", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Choice")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_c); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("c"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_c = body.getOrCreateVariableByName("c"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_c), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Choice"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_c, parameter_c) + )); + // neg find transition(_, _, c) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var___1_, var_c), Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("c") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java new file mode 100644 index 00000000..1c20a03b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java @@ -0,0 +1,559 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // Choice
+ *         /////////
+ *         
+ *         {@literal @}Constraint(severity="error", message="error", key = {c})
+ *         pattern choiceHasNoOutgoing(c : Choice) {
+ *         	neg find transition(_, c, _);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class ChoiceHasNoOutgoing extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Choice fC; + + private static List parameterNames = makeImmutableList("c"); + + private Match(final Choice pC) { + this.fC = pC; + } + + @Override + public Object get(final String parameterName) { + if ("c".equals(parameterName)) return this.fC; + return null; + } + + public Choice getC() { + return this.fC; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("c".equals(parameterName) ) { + this.fC = (Choice) newValue; + return true; + } + return false; + } + + public void setC(final Choice pC) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fC = pC; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing"; + } + + @Override + public List parameterNames() { + return ChoiceHasNoOutgoing.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fC}; + } + + @Override + public ChoiceHasNoOutgoing.Match toImmutable() { + return isMutable() ? newMatch(fC) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"c\"=" + prettyPrintValue(fC)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fC); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof ChoiceHasNoOutgoing.Match)) { + ChoiceHasNoOutgoing.Match other = (ChoiceHasNoOutgoing.Match) obj; + return Objects.equals(fC, other.fC); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public ChoiceHasNoOutgoing specification() { + return ChoiceHasNoOutgoing.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static ChoiceHasNoOutgoing.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static ChoiceHasNoOutgoing.Match newMutableMatch(final Choice pC) { + return new Mutable(pC); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the (partial) match object. + * + */ + public static ChoiceHasNoOutgoing.Match newMatch(final Choice pC) { + return new Immutable(pC); + } + + private static final class Mutable extends ChoiceHasNoOutgoing.Match { + Mutable(final Choice pC) { + super(pC); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends ChoiceHasNoOutgoing.Match { + Immutable(final Choice pC) { + super(pC); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // Choice
+   * /////////
+   * 
+   * {@literal @}Constraint(severity="error", message="error", key = {c})
+   * pattern choiceHasNoOutgoing(c : Choice) {
+   * 	neg find transition(_, c, _);
+   * }
+   * 
+ * + * @see Match + * @see ChoiceHasNoOutgoing + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static ChoiceHasNoOutgoing.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static ChoiceHasNoOutgoing.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_C = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(ChoiceHasNoOutgoing.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Choice pC) { + return rawStreamAllMatches(new Object[]{pC}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Choice pC) { + return rawStreamAllMatches(new Object[]{pC}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Choice pC) { + return rawGetOneArbitraryMatch(new Object[]{pC}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Choice pC) { + return rawHasMatch(new Object[]{pC}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Choice pC) { + return rawCountMatches(new Object[]{pC}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Choice pC, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pC}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pC the fixed value of pattern parameter c, or null if not bound. + * @return the (partial) match object. + * + */ + public ChoiceHasNoOutgoing.Match newMatch(final Choice pC) { + return ChoiceHasNoOutgoing.Match.newMatch(pC); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfc(final Object[] parameters) { + return rawStreamAllValues(POSITION_C, parameters).map(Choice.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfc() { + return rawStreamAllValuesOfc(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for c. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfc() { + return rawStreamAllValuesOfc(emptyArray()); + } + + @Override + protected ChoiceHasNoOutgoing.Match tupleToMatch(final Tuple t) { + try { + return ChoiceHasNoOutgoing.Match.newMatch((Choice) t.get(POSITION_C)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected ChoiceHasNoOutgoing.Match arrayToMatch(final Object[] match) { + try { + return ChoiceHasNoOutgoing.Match.newMatch((Choice) match[POSITION_C]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected ChoiceHasNoOutgoing.Match arrayToMatchMutable(final Object[] match) { + try { + return ChoiceHasNoOutgoing.Match.newMutableMatch((Choice) match[POSITION_C]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return ChoiceHasNoOutgoing.instance(); + } + } + + private ChoiceHasNoOutgoing() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static ChoiceHasNoOutgoing instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected ChoiceHasNoOutgoing.Matcher instantiate(final ViatraQueryEngine engine) { + return ChoiceHasNoOutgoing.Matcher.on(engine); + } + + @Override + public ChoiceHasNoOutgoing.Matcher instantiate() { + return ChoiceHasNoOutgoing.Matcher.create(); + } + + @Override + public ChoiceHasNoOutgoing.Match newEmptyMatch() { + return ChoiceHasNoOutgoing.Match.newEmptyMatch(); + } + + @Override + public ChoiceHasNoOutgoing.Match newMatch(final Object... parameters) { + return ChoiceHasNoOutgoing.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing (visibility: PUBLIC, simpleName: ChoiceHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing (visibility: PUBLIC, simpleName: ChoiceHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static ChoiceHasNoOutgoing INSTANCE = new ChoiceHasNoOutgoing(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static ChoiceHasNoOutgoing.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_c = new PParameter("c", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Choice")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_c); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("c"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_c = body.getOrCreateVariableByName("c"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_c), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Choice"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_c, parameter_c) + )); + // neg find transition(_, c, _) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_c, var___1_), Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("c") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java new file mode 100644 index 00000000..147b27f9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java @@ -0,0 +1,702 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // Entry
+ *         /////////
+ *         
+ *         pattern entryInRegion(r1 : Region, e1 : Entry) {
+ *         	Region.vertices(r1, e1);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class EntryInRegion extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Region fR1; + + private Entry fE1; + + private static List parameterNames = makeImmutableList("r1", "e1"); + + private Match(final Region pR1, final Entry pE1) { + this.fR1 = pR1; + this.fE1 = pE1; + } + + @Override + public Object get(final String parameterName) { + if ("r1".equals(parameterName)) return this.fR1; + if ("e1".equals(parameterName)) return this.fE1; + return null; + } + + public Region getR1() { + return this.fR1; + } + + public Entry getE1() { + return this.fE1; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("r1".equals(parameterName) ) { + this.fR1 = (Region) newValue; + return true; + } + if ("e1".equals(parameterName) ) { + this.fE1 = (Entry) newValue; + return true; + } + return false; + } + + public void setR1(final Region pR1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fR1 = pR1; + } + + public void setE1(final Entry pE1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fE1 = pE1; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion"; + } + + @Override + public List parameterNames() { + return EntryInRegion.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fR1, fE1}; + } + + @Override + public EntryInRegion.Match toImmutable() { + return isMutable() ? newMatch(fR1, fE1) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"r1\"=" + prettyPrintValue(fR1) + ", "); + result.append("\"e1\"=" + prettyPrintValue(fE1)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fR1, fE1); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof EntryInRegion.Match)) { + EntryInRegion.Match other = (EntryInRegion.Match) obj; + return Objects.equals(fR1, other.fR1) && Objects.equals(fE1, other.fE1); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public EntryInRegion specification() { + return EntryInRegion.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static EntryInRegion.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static EntryInRegion.Match newMutableMatch(final Region pR1, final Entry pE1) { + return new Mutable(pR1, pE1); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return the (partial) match object. + * + */ + public static EntryInRegion.Match newMatch(final Region pR1, final Entry pE1) { + return new Immutable(pR1, pE1); + } + + private static final class Mutable extends EntryInRegion.Match { + Mutable(final Region pR1, final Entry pE1) { + super(pR1, pE1); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends EntryInRegion.Match { + Immutable(final Region pR1, final Entry pE1) { + super(pR1, pE1); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // Entry
+   * /////////
+   * 
+   * pattern entryInRegion(r1 : Region, e1 : Entry) {
+   * 	Region.vertices(r1, e1);
+   * }
+   * 
+ * + * @see Match + * @see EntryInRegion + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static EntryInRegion.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static EntryInRegion.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_R1 = 0; + + private final static int POSITION_E1 = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(EntryInRegion.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Region pR1, final Entry pE1) { + return rawStreamAllMatches(new Object[]{pR1, pE1}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Region pR1, final Entry pE1) { + return rawStreamAllMatches(new Object[]{pR1, pE1}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Region pR1, final Entry pE1) { + return rawGetOneArbitraryMatch(new Object[]{pR1, pE1}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Region pR1, final Entry pE1) { + return rawHasMatch(new Object[]{pR1, pE1}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Region pR1, final Entry pE1) { + return rawCountMatches(new Object[]{pR1, pE1}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Region pR1, final Entry pE1, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pR1, pE1}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param pE1 the fixed value of pattern parameter e1, or null if not bound. + * @return the (partial) match object. + * + */ + public EntryInRegion.Match newMatch(final Region pR1, final Entry pE1) { + return EntryInRegion.Match.newMatch(pR1, pE1); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfr1(final Object[] parameters) { + return rawStreamAllValues(POSITION_R1, parameters).map(Region.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfr1() { + return rawStreamAllValuesOfr1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfr1() { + return rawStreamAllValuesOfr1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for r1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfr1(final EntryInRegion.Match partialMatch) { + return rawStreamAllValuesOfr1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for r1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfr1(final Entry pE1) { + return rawStreamAllValuesOfr1(new Object[]{null, pE1}); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfr1(final EntryInRegion.Match partialMatch) { + return rawStreamAllValuesOfr1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfr1(final Entry pE1) { + return rawStreamAllValuesOfr1(new Object[]{null, pE1}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfe1(final Object[] parameters) { + return rawStreamAllValues(POSITION_E1, parameters).map(Entry.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for e1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe1() { + return rawStreamAllValuesOfe1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe1() { + return rawStreamAllValuesOfe1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for e1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe1(final EntryInRegion.Match partialMatch) { + return rawStreamAllValuesOfe1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for e1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe1(final Region pR1) { + return rawStreamAllValuesOfe1(new Object[]{pR1, null}); + } + + /** + * Retrieve the set of values that occur in matches for e1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe1(final EntryInRegion.Match partialMatch) { + return rawStreamAllValuesOfe1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe1(final Region pR1) { + return rawStreamAllValuesOfe1(new Object[]{pR1, null}).collect(Collectors.toSet()); + } + + @Override + protected EntryInRegion.Match tupleToMatch(final Tuple t) { + try { + return EntryInRegion.Match.newMatch((Region) t.get(POSITION_R1), (Entry) t.get(POSITION_E1)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected EntryInRegion.Match arrayToMatch(final Object[] match) { + try { + return EntryInRegion.Match.newMatch((Region) match[POSITION_R1], (Entry) match[POSITION_E1]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected EntryInRegion.Match arrayToMatchMutable(final Object[] match) { + try { + return EntryInRegion.Match.newMutableMatch((Region) match[POSITION_R1], (Entry) match[POSITION_E1]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return EntryInRegion.instance(); + } + } + + private EntryInRegion() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static EntryInRegion instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected EntryInRegion.Matcher instantiate(final ViatraQueryEngine engine) { + return EntryInRegion.Matcher.on(engine); + } + + @Override + public EntryInRegion.Matcher instantiate() { + return EntryInRegion.Matcher.create(); + } + + @Override + public EntryInRegion.Match newEmptyMatch() { + return EntryInRegion.Match.newEmptyMatch(); + } + + @Override + public EntryInRegion.Match newMatch(final Object... parameters) { + return EntryInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion (visibility: PUBLIC, simpleName: EntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion (visibility: PUBLIC, simpleName: EntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static EntryInRegion INSTANCE = new EntryInRegion(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static EntryInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_r1 = new PParameter("r1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); + + private final PParameter parameter_e1 = new PParameter("e1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_r1, parameter_e1); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("r1","e1"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_r1 = body.getOrCreateVariableByName("r1"); + PVariable var_e1 = body.getOrCreateVariableByName("e1"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_e1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_r1, parameter_r1), + new ExportedParameter(body, var_e1, parameter_e1) + )); + // Region.vertices(r1, e1) + new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_e1); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java new file mode 100644 index 00000000..236ce5ff --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java @@ -0,0 +1,549 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern hasMultipleIncomingTrainsition(v : Synchronization) {
+ *         	find transition(_, src1, v);
+ *         	find transition(_, src2, v);
+ *         	src1 != src2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class HasMultipleIncomingTrainsition extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fV; + + private static List parameterNames = makeImmutableList("v"); + + private Match(final Synchronization pV) { + this.fV = pV; + } + + @Override + public Object get(final String parameterName) { + if ("v".equals(parameterName)) return this.fV; + return null; + } + + public Synchronization getV() { + return this.fV; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("v".equals(parameterName) ) { + this.fV = (Synchronization) newValue; + return true; + } + return false; + } + + public void setV(final Synchronization pV) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV = pV; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition"; + } + + @Override + public List parameterNames() { + return HasMultipleIncomingTrainsition.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fV}; + } + + @Override + public HasMultipleIncomingTrainsition.Match toImmutable() { + return isMutable() ? newMatch(fV) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"v\"=" + prettyPrintValue(fV)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fV); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof HasMultipleIncomingTrainsition.Match)) { + HasMultipleIncomingTrainsition.Match other = (HasMultipleIncomingTrainsition.Match) obj; + return Objects.equals(fV, other.fV); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public HasMultipleIncomingTrainsition specification() { + return HasMultipleIncomingTrainsition.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static HasMultipleIncomingTrainsition.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static HasMultipleIncomingTrainsition.Match newMutableMatch(final Synchronization pV) { + return new Mutable(pV); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public static HasMultipleIncomingTrainsition.Match newMatch(final Synchronization pV) { + return new Immutable(pV); + } + + private static final class Mutable extends HasMultipleIncomingTrainsition.Match { + Mutable(final Synchronization pV) { + super(pV); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends HasMultipleIncomingTrainsition.Match { + Immutable(final Synchronization pV) { + super(pV); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern hasMultipleIncomingTrainsition(v : Synchronization) {
+   * 	find transition(_, src1, v);
+   * 	find transition(_, src2, v);
+   * 	src1 != src2;
+   * }
+   * 
+ * + * @see Match + * @see HasMultipleIncomingTrainsition + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static HasMultipleIncomingTrainsition.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static HasMultipleIncomingTrainsition.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_V = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleIncomingTrainsition.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pV) { + return rawStreamAllMatches(new Object[]{pV}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pV) { + return rawStreamAllMatches(new Object[]{pV}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pV) { + return rawGetOneArbitraryMatch(new Object[]{pV}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pV) { + return rawHasMatch(new Object[]{pV}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pV) { + return rawCountMatches(new Object[]{pV}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pV, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pV}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public HasMultipleIncomingTrainsition.Match newMatch(final Synchronization pV) { + return HasMultipleIncomingTrainsition.Match.newMatch(pV); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv(final Object[] parameters) { + return rawStreamAllValues(POSITION_V, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()); + } + + @Override + protected HasMultipleIncomingTrainsition.Match tupleToMatch(final Tuple t) { + try { + return HasMultipleIncomingTrainsition.Match.newMatch((Synchronization) t.get(POSITION_V)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleIncomingTrainsition.Match arrayToMatch(final Object[] match) { + try { + return HasMultipleIncomingTrainsition.Match.newMatch((Synchronization) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleIncomingTrainsition.Match arrayToMatchMutable(final Object[] match) { + try { + return HasMultipleIncomingTrainsition.Match.newMutableMatch((Synchronization) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return HasMultipleIncomingTrainsition.instance(); + } + } + + private HasMultipleIncomingTrainsition() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static HasMultipleIncomingTrainsition instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected HasMultipleIncomingTrainsition.Matcher instantiate(final ViatraQueryEngine engine) { + return HasMultipleIncomingTrainsition.Matcher.on(engine); + } + + @Override + public HasMultipleIncomingTrainsition.Matcher instantiate() { + return HasMultipleIncomingTrainsition.Matcher.create(); + } + + @Override + public HasMultipleIncomingTrainsition.Match newEmptyMatch() { + return HasMultipleIncomingTrainsition.Match.newEmptyMatch(); + } + + @Override + public HasMultipleIncomingTrainsition.Match newMatch(final Object... parameters) { + return HasMultipleIncomingTrainsition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition (visibility: PUBLIC, simpleName: HasMultipleIncomingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition (visibility: PUBLIC, simpleName: HasMultipleIncomingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static HasMultipleIncomingTrainsition INSTANCE = new HasMultipleIncomingTrainsition(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static HasMultipleIncomingTrainsition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_v); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("v"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_v = body.getOrCreateVariableByName("v"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var_src1 = body.getOrCreateVariableByName("src1"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + PVariable var_src2 = body.getOrCreateVariableByName("src2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_v, parameter_v) + )); + // find transition(_, src1, v) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_src1, var_v), Transition.instance().getInternalQueryRepresentation()); + // find transition(_, src2, v) + new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_src2, var_v), Transition.instance().getInternalQueryRepresentation()); + // src1 != src2 + new Inequality(body, var_src1, var_src2); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java new file mode 100644 index 00000000..115b93e1 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java @@ -0,0 +1,549 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern hasMultipleOutgoingTrainsition(v : Synchronization) {
+ *         	find transition(_, v, trg1);
+ *         	find transition(_, v, trg2);
+ *         	trg1 != trg2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class HasMultipleOutgoingTrainsition extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fV; + + private static List parameterNames = makeImmutableList("v"); + + private Match(final Synchronization pV) { + this.fV = pV; + } + + @Override + public Object get(final String parameterName) { + if ("v".equals(parameterName)) return this.fV; + return null; + } + + public Synchronization getV() { + return this.fV; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("v".equals(parameterName) ) { + this.fV = (Synchronization) newValue; + return true; + } + return false; + } + + public void setV(final Synchronization pV) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV = pV; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition"; + } + + @Override + public List parameterNames() { + return HasMultipleOutgoingTrainsition.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fV}; + } + + @Override + public HasMultipleOutgoingTrainsition.Match toImmutable() { + return isMutable() ? newMatch(fV) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"v\"=" + prettyPrintValue(fV)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fV); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof HasMultipleOutgoingTrainsition.Match)) { + HasMultipleOutgoingTrainsition.Match other = (HasMultipleOutgoingTrainsition.Match) obj; + return Objects.equals(fV, other.fV); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public HasMultipleOutgoingTrainsition specification() { + return HasMultipleOutgoingTrainsition.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static HasMultipleOutgoingTrainsition.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static HasMultipleOutgoingTrainsition.Match newMutableMatch(final Synchronization pV) { + return new Mutable(pV); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public static HasMultipleOutgoingTrainsition.Match newMatch(final Synchronization pV) { + return new Immutable(pV); + } + + private static final class Mutable extends HasMultipleOutgoingTrainsition.Match { + Mutable(final Synchronization pV) { + super(pV); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends HasMultipleOutgoingTrainsition.Match { + Immutable(final Synchronization pV) { + super(pV); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern hasMultipleOutgoingTrainsition(v : Synchronization) {
+   * 	find transition(_, v, trg1);
+   * 	find transition(_, v, trg2);
+   * 	trg1 != trg2;
+   * }
+   * 
+ * + * @see Match + * @see HasMultipleOutgoingTrainsition + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static HasMultipleOutgoingTrainsition.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static HasMultipleOutgoingTrainsition.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_V = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleOutgoingTrainsition.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pV) { + return rawStreamAllMatches(new Object[]{pV}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pV) { + return rawStreamAllMatches(new Object[]{pV}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pV) { + return rawGetOneArbitraryMatch(new Object[]{pV}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pV) { + return rawHasMatch(new Object[]{pV}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pV) { + return rawCountMatches(new Object[]{pV}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pV, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pV}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public HasMultipleOutgoingTrainsition.Match newMatch(final Synchronization pV) { + return HasMultipleOutgoingTrainsition.Match.newMatch(pV); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv(final Object[] parameters) { + return rawStreamAllValues(POSITION_V, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()); + } + + @Override + protected HasMultipleOutgoingTrainsition.Match tupleToMatch(final Tuple t) { + try { + return HasMultipleOutgoingTrainsition.Match.newMatch((Synchronization) t.get(POSITION_V)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleOutgoingTrainsition.Match arrayToMatch(final Object[] match) { + try { + return HasMultipleOutgoingTrainsition.Match.newMatch((Synchronization) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleOutgoingTrainsition.Match arrayToMatchMutable(final Object[] match) { + try { + return HasMultipleOutgoingTrainsition.Match.newMutableMatch((Synchronization) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return HasMultipleOutgoingTrainsition.instance(); + } + } + + private HasMultipleOutgoingTrainsition() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static HasMultipleOutgoingTrainsition instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected HasMultipleOutgoingTrainsition.Matcher instantiate(final ViatraQueryEngine engine) { + return HasMultipleOutgoingTrainsition.Matcher.on(engine); + } + + @Override + public HasMultipleOutgoingTrainsition.Matcher instantiate() { + return HasMultipleOutgoingTrainsition.Matcher.create(); + } + + @Override + public HasMultipleOutgoingTrainsition.Match newEmptyMatch() { + return HasMultipleOutgoingTrainsition.Match.newEmptyMatch(); + } + + @Override + public HasMultipleOutgoingTrainsition.Match newMatch(final Object... parameters) { + return HasMultipleOutgoingTrainsition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition (visibility: PUBLIC, simpleName: HasMultipleOutgoingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition (visibility: PUBLIC, simpleName: HasMultipleOutgoingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static HasMultipleOutgoingTrainsition INSTANCE = new HasMultipleOutgoingTrainsition(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static HasMultipleOutgoingTrainsition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_v); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("v"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_v = body.getOrCreateVariableByName("v"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var_trg1 = body.getOrCreateVariableByName("trg1"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + PVariable var_trg2 = body.getOrCreateVariableByName("trg2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_v, parameter_v) + )); + // find transition(_, v, trg1) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v, var_trg1), Transition.instance().getInternalQueryRepresentation()); + // find transition(_, v, trg2) + new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_v, var_trg2), Transition.instance().getInternalQueryRepresentation()); + // trg1 != trg2 + new Inequality(body, var_trg1, var_trg2); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java new file mode 100644 index 00000000..5542ccbb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java @@ -0,0 +1,555 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern hasMultipleRegions(composite: CompositeElement) {
+ *         	CompositeElement.regions(composite,region1);
+ *         	CompositeElement.regions(composite,region2);
+ *         	region1 != region2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class HasMultipleRegions extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private CompositeElement fComposite; + + private static List parameterNames = makeImmutableList("composite"); + + private Match(final CompositeElement pComposite) { + this.fComposite = pComposite; + } + + @Override + public Object get(final String parameterName) { + if ("composite".equals(parameterName)) return this.fComposite; + return null; + } + + public CompositeElement getComposite() { + return this.fComposite; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("composite".equals(parameterName) ) { + this.fComposite = (CompositeElement) newValue; + return true; + } + return false; + } + + public void setComposite(final CompositeElement pComposite) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fComposite = pComposite; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions"; + } + + @Override + public List parameterNames() { + return HasMultipleRegions.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fComposite}; + } + + @Override + public HasMultipleRegions.Match toImmutable() { + return isMutable() ? newMatch(fComposite) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"composite\"=" + prettyPrintValue(fComposite)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fComposite); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof HasMultipleRegions.Match)) { + HasMultipleRegions.Match other = (HasMultipleRegions.Match) obj; + return Objects.equals(fComposite, other.fComposite); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public HasMultipleRegions specification() { + return HasMultipleRegions.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static HasMultipleRegions.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static HasMultipleRegions.Match newMutableMatch(final CompositeElement pComposite) { + return new Mutable(pComposite); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return the (partial) match object. + * + */ + public static HasMultipleRegions.Match newMatch(final CompositeElement pComposite) { + return new Immutable(pComposite); + } + + private static final class Mutable extends HasMultipleRegions.Match { + Mutable(final CompositeElement pComposite) { + super(pComposite); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends HasMultipleRegions.Match { + Immutable(final CompositeElement pComposite) { + super(pComposite); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern hasMultipleRegions(composite: CompositeElement) {
+   * 	CompositeElement.regions(composite,region1);
+   * 	CompositeElement.regions(composite,region2);
+   * 	region1 != region2;
+   * }
+   * 
+ * + * @see Match + * @see HasMultipleRegions + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static HasMultipleRegions.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static HasMultipleRegions.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_COMPOSITE = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleRegions.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final CompositeElement pComposite) { + return rawStreamAllMatches(new Object[]{pComposite}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final CompositeElement pComposite) { + return rawStreamAllMatches(new Object[]{pComposite}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final CompositeElement pComposite) { + return rawGetOneArbitraryMatch(new Object[]{pComposite}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final CompositeElement pComposite) { + return rawHasMatch(new Object[]{pComposite}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final CompositeElement pComposite) { + return rawCountMatches(new Object[]{pComposite}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final CompositeElement pComposite, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pComposite}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pComposite the fixed value of pattern parameter composite, or null if not bound. + * @return the (partial) match object. + * + */ + public HasMultipleRegions.Match newMatch(final CompositeElement pComposite) { + return HasMultipleRegions.Match.newMatch(pComposite); + } + + /** + * Retrieve the set of values that occur in matches for composite. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfcomposite(final Object[] parameters) { + return rawStreamAllValues(POSITION_COMPOSITE, parameters).map(CompositeElement.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for composite. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfcomposite() { + return rawStreamAllValuesOfcomposite(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for composite. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfcomposite() { + return rawStreamAllValuesOfcomposite(emptyArray()); + } + + @Override + protected HasMultipleRegions.Match tupleToMatch(final Tuple t) { + try { + return HasMultipleRegions.Match.newMatch((CompositeElement) t.get(POSITION_COMPOSITE)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleRegions.Match arrayToMatch(final Object[] match) { + try { + return HasMultipleRegions.Match.newMatch((CompositeElement) match[POSITION_COMPOSITE]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected HasMultipleRegions.Match arrayToMatchMutable(final Object[] match) { + try { + return HasMultipleRegions.Match.newMutableMatch((CompositeElement) match[POSITION_COMPOSITE]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return HasMultipleRegions.instance(); + } + } + + private HasMultipleRegions() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static HasMultipleRegions instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected HasMultipleRegions.Matcher instantiate(final ViatraQueryEngine engine) { + return HasMultipleRegions.Matcher.on(engine); + } + + @Override + public HasMultipleRegions.Matcher instantiate() { + return HasMultipleRegions.Matcher.create(); + } + + @Override + public HasMultipleRegions.Match newEmptyMatch() { + return HasMultipleRegions.Match.newEmptyMatch(); + } + + @Override + public HasMultipleRegions.Match newMatch(final Object... parameters) { + return HasMultipleRegions.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions (visibility: PUBLIC, simpleName: HasMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions (visibility: PUBLIC, simpleName: HasMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static HasMultipleRegions INSTANCE = new HasMultipleRegions(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static HasMultipleRegions.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_composite = new PParameter("composite", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "CompositeElement")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_composite); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("composite"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_composite = body.getOrCreateVariableByName("composite"); + PVariable var_region1 = body.getOrCreateVariableByName("region1"); + PVariable var_region2 = body.getOrCreateVariableByName("region2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_composite, parameter_composite) + )); + // CompositeElement.regions(composite,region1) + new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_composite, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + new Equality(body, var__virtual_0_, var_region1); + // CompositeElement.regions(composite,region2) + new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_composite, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + new Equality(body, var__virtual_1_, var_region2); + // region1 != region2 + new Inequality(body, var_region1, var_region2); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java new file mode 100644 index 00000000..ed8ca3e5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java @@ -0,0 +1,703 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {e})
+ *         pattern incomingToEntry(t : Transition, e : Entry) {
+ *         	find transition(t, _, e);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class IncomingToEntry extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Transition fT; + + private Entry fE; + + private static List parameterNames = makeImmutableList("t", "e"); + + private Match(final Transition pT, final Entry pE) { + this.fT = pT; + this.fE = pE; + } + + @Override + public Object get(final String parameterName) { + if ("t".equals(parameterName)) return this.fT; + if ("e".equals(parameterName)) return this.fE; + return null; + } + + public Transition getT() { + return this.fT; + } + + public Entry getE() { + return this.fE; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("t".equals(parameterName) ) { + this.fT = (Transition) newValue; + return true; + } + if ("e".equals(parameterName) ) { + this.fE = (Entry) newValue; + return true; + } + return false; + } + + public void setT(final Transition pT) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT = pT; + } + + public void setE(final Entry pE) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fE = pE; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry"; + } + + @Override + public List parameterNames() { + return IncomingToEntry.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fT, fE}; + } + + @Override + public IncomingToEntry.Match toImmutable() { + return isMutable() ? newMatch(fT, fE) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"t\"=" + prettyPrintValue(fT) + ", "); + result.append("\"e\"=" + prettyPrintValue(fE)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fT, fE); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof IncomingToEntry.Match)) { + IncomingToEntry.Match other = (IncomingToEntry.Match) obj; + return Objects.equals(fT, other.fT) && Objects.equals(fE, other.fE); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public IncomingToEntry specification() { + return IncomingToEntry.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static IncomingToEntry.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static IncomingToEntry.Match newMutableMatch(final Transition pT, final Entry pE) { + return new Mutable(pT, pE); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public static IncomingToEntry.Match newMatch(final Transition pT, final Entry pE) { + return new Immutable(pT, pE); + } + + private static final class Mutable extends IncomingToEntry.Match { + Mutable(final Transition pT, final Entry pE) { + super(pT, pE); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends IncomingToEntry.Match { + Immutable(final Transition pT, final Entry pE) { + super(pT, pE); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {e})
+   * pattern incomingToEntry(t : Transition, e : Entry) {
+   * 	find transition(t, _, e);
+   * }
+   * 
+ * + * @see Match + * @see IncomingToEntry + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static IncomingToEntry.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static IncomingToEntry.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_T = 0; + + private final static int POSITION_E = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(IncomingToEntry.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Transition pT, final Entry pE) { + return rawStreamAllMatches(new Object[]{pT, pE}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Transition pT, final Entry pE) { + return rawStreamAllMatches(new Object[]{pT, pE}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Transition pT, final Entry pE) { + return rawGetOneArbitraryMatch(new Object[]{pT, pE}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Transition pT, final Entry pE) { + return rawHasMatch(new Object[]{pT, pE}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Transition pT, final Entry pE) { + return rawCountMatches(new Object[]{pT, pE}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Transition pT, final Entry pE, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pT, pE}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public IncomingToEntry.Match newMatch(final Transition pT, final Entry pE) { + return IncomingToEntry.Match.newMatch(pT, pE); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft(final Object[] parameters) { + return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final IncomingToEntry.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final Entry pE) { + return rawStreamAllValuesOft(new Object[]{null, pE}); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final IncomingToEntry.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final Entry pE) { + return rawStreamAllValuesOft(new Object[]{null, pE}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfe(final Object[] parameters) { + return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final IncomingToEntry.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final Transition pT) { + return rawStreamAllValuesOfe(new Object[]{pT, null}); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final IncomingToEntry.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final Transition pT) { + return rawStreamAllValuesOfe(new Object[]{pT, null}).collect(Collectors.toSet()); + } + + @Override + protected IncomingToEntry.Match tupleToMatch(final Tuple t) { + try { + return IncomingToEntry.Match.newMatch((Transition) t.get(POSITION_T), (Entry) t.get(POSITION_E)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected IncomingToEntry.Match arrayToMatch(final Object[] match) { + try { + return IncomingToEntry.Match.newMatch((Transition) match[POSITION_T], (Entry) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected IncomingToEntry.Match arrayToMatchMutable(final Object[] match) { + try { + return IncomingToEntry.Match.newMutableMatch((Transition) match[POSITION_T], (Entry) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return IncomingToEntry.instance(); + } + } + + private IncomingToEntry() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IncomingToEntry instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected IncomingToEntry.Matcher instantiate(final ViatraQueryEngine engine) { + return IncomingToEntry.Matcher.on(engine); + } + + @Override + public IncomingToEntry.Matcher instantiate() { + return IncomingToEntry.Matcher.create(); + } + + @Override + public IncomingToEntry.Match newEmptyMatch() { + return IncomingToEntry.Match.newEmptyMatch(); + } + + @Override + public IncomingToEntry.Match newMatch(final Object... parameters) { + return IncomingToEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry (visibility: PUBLIC, simpleName: IncomingToEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry (visibility: PUBLIC, simpleName: IncomingToEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static IncomingToEntry INSTANCE = new IncomingToEntry(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static IncomingToEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_t, parameter_e); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("t","e"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_t = body.getOrCreateVariableByName("t"); + PVariable var_e = body.getOrCreateVariableByName("e"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_t, parameter_t), + new ExportedParameter(body, var_e, parameter_e) + )); + // find transition(t, _, e) + new PositivePatternCall(body, Tuples.flatTupleOf(var_t, var___0_, var_e), ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("e") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java new file mode 100644 index 00000000..e4c1bac5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java @@ -0,0 +1,827 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {e})
+ *         pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) {
+ *         	Entry.outgoingTransitions(e,t1);
+ *         	Entry.outgoingTransitions(e,t2);
+ *         	t1!=t2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class MultipleTransitionFromEntry extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Entry fE; + + private Transition fT1; + + private Transition fT2; + + private static List parameterNames = makeImmutableList("e", "t1", "t2"); + + private Match(final Entry pE, final Transition pT1, final Transition pT2) { + this.fE = pE; + this.fT1 = pT1; + this.fT2 = pT2; + } + + @Override + public Object get(final String parameterName) { + if ("e".equals(parameterName)) return this.fE; + if ("t1".equals(parameterName)) return this.fT1; + if ("t2".equals(parameterName)) return this.fT2; + return null; + } + + public Entry getE() { + return this.fE; + } + + public Transition getT1() { + return this.fT1; + } + + public Transition getT2() { + return this.fT2; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("e".equals(parameterName) ) { + this.fE = (Entry) newValue; + return true; + } + if ("t1".equals(parameterName) ) { + this.fT1 = (Transition) newValue; + return true; + } + if ("t2".equals(parameterName) ) { + this.fT2 = (Transition) newValue; + return true; + } + return false; + } + + public void setE(final Entry pE) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fE = pE; + } + + public void setT1(final Transition pT1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT1 = pT1; + } + + public void setT2(final Transition pT2) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT2 = pT2; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry"; + } + + @Override + public List parameterNames() { + return MultipleTransitionFromEntry.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fE, fT1, fT2}; + } + + @Override + public MultipleTransitionFromEntry.Match toImmutable() { + return isMutable() ? newMatch(fE, fT1, fT2) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"e\"=" + prettyPrintValue(fE) + ", "); + result.append("\"t1\"=" + prettyPrintValue(fT1) + ", "); + result.append("\"t2\"=" + prettyPrintValue(fT2)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fE, fT1, fT2); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof MultipleTransitionFromEntry.Match)) { + MultipleTransitionFromEntry.Match other = (MultipleTransitionFromEntry.Match) obj; + return Objects.equals(fE, other.fE) && Objects.equals(fT1, other.fT1) && Objects.equals(fT2, other.fT2); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public MultipleTransitionFromEntry specification() { + return MultipleTransitionFromEntry.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static MultipleTransitionFromEntry.Match newEmptyMatch() { + return new Mutable(null, null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static MultipleTransitionFromEntry.Match newMutableMatch(final Entry pE, final Transition pT1, final Transition pT2) { + return new Mutable(pE, pT1, pT2); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return the (partial) match object. + * + */ + public static MultipleTransitionFromEntry.Match newMatch(final Entry pE, final Transition pT1, final Transition pT2) { + return new Immutable(pE, pT1, pT2); + } + + private static final class Mutable extends MultipleTransitionFromEntry.Match { + Mutable(final Entry pE, final Transition pT1, final Transition pT2) { + super(pE, pT1, pT2); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends MultipleTransitionFromEntry.Match { + Immutable(final Entry pE, final Transition pT1, final Transition pT2) { + super(pE, pT1, pT2); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {e})
+   * pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) {
+   * 	Entry.outgoingTransitions(e,t1);
+   * 	Entry.outgoingTransitions(e,t2);
+   * 	t1!=t2;
+   * }
+   * 
+ * + * @see Match + * @see MultipleTransitionFromEntry + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static MultipleTransitionFromEntry.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static MultipleTransitionFromEntry.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_E = 0; + + private final static int POSITION_T1 = 1; + + private final static int POSITION_T2 = 2; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(MultipleTransitionFromEntry.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Entry pE, final Transition pT1, final Transition pT2) { + return rawStreamAllMatches(new Object[]{pE, pT1, pT2}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Entry pE, final Transition pT1, final Transition pT2) { + return rawStreamAllMatches(new Object[]{pE, pT1, pT2}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Entry pE, final Transition pT1, final Transition pT2) { + return rawGetOneArbitraryMatch(new Object[]{pE, pT1, pT2}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Entry pE, final Transition pT1, final Transition pT2) { + return rawHasMatch(new Object[]{pE, pT1, pT2}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Entry pE, final Transition pT1, final Transition pT2) { + return rawCountMatches(new Object[]{pE, pT1, pT2}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Entry pE, final Transition pT1, final Transition pT2, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pE, pT1, pT2}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param pT1 the fixed value of pattern parameter t1, or null if not bound. + * @param pT2 the fixed value of pattern parameter t2, or null if not bound. + * @return the (partial) match object. + * + */ + public MultipleTransitionFromEntry.Match newMatch(final Entry pE, final Transition pT1, final Transition pT2) { + return MultipleTransitionFromEntry.Match.newMatch(pE, pT1, pT2); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfe(final Object[] parameters) { + return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final Transition pT1, final Transition pT2) { + return rawStreamAllValuesOfe(new Object[]{null, pT1, pT2}); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final Transition pT1, final Transition pT2) { + return rawStreamAllValuesOfe(new Object[]{null, pT1, pT2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft1(final Object[] parameters) { + return rawStreamAllValues(POSITION_T1, parameters).map(Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft1() { + return rawStreamAllValuesOft1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft1() { + return rawStreamAllValuesOft1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft1(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOft1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft1(final Entry pE, final Transition pT2) { + return rawStreamAllValuesOft1(new Object[]{pE, null, pT2}); + } + + /** + * Retrieve the set of values that occur in matches for t1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft1(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOft1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft1(final Entry pE, final Transition pT2) { + return rawStreamAllValuesOft1(new Object[]{pE, null, pT2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t2. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft2(final Object[] parameters) { + return rawStreamAllValues(POSITION_T2, parameters).map(Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft2() { + return rawStreamAllValuesOft2(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft2() { + return rawStreamAllValuesOft2(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft2(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOft2(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft2(final Entry pE, final Transition pT1) { + return rawStreamAllValuesOft2(new Object[]{pE, pT1, null}); + } + + /** + * Retrieve the set of values that occur in matches for t2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft2(final MultipleTransitionFromEntry.Match partialMatch) { + return rawStreamAllValuesOft2(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft2(final Entry pE, final Transition pT1) { + return rawStreamAllValuesOft2(new Object[]{pE, pT1, null}).collect(Collectors.toSet()); + } + + @Override + protected MultipleTransitionFromEntry.Match tupleToMatch(final Tuple t) { + try { + return MultipleTransitionFromEntry.Match.newMatch((Entry) t.get(POSITION_E), (Transition) t.get(POSITION_T1), (Transition) t.get(POSITION_T2)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected MultipleTransitionFromEntry.Match arrayToMatch(final Object[] match) { + try { + return MultipleTransitionFromEntry.Match.newMatch((Entry) match[POSITION_E], (Transition) match[POSITION_T1], (Transition) match[POSITION_T2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected MultipleTransitionFromEntry.Match arrayToMatchMutable(final Object[] match) { + try { + return MultipleTransitionFromEntry.Match.newMutableMatch((Entry) match[POSITION_E], (Transition) match[POSITION_T1], (Transition) match[POSITION_T2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return MultipleTransitionFromEntry.instance(); + } + } + + private MultipleTransitionFromEntry() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static MultipleTransitionFromEntry instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected MultipleTransitionFromEntry.Matcher instantiate(final ViatraQueryEngine engine) { + return MultipleTransitionFromEntry.Matcher.on(engine); + } + + @Override + public MultipleTransitionFromEntry.Matcher instantiate() { + return MultipleTransitionFromEntry.Matcher.create(); + } + + @Override + public MultipleTransitionFromEntry.Match newEmptyMatch() { + return MultipleTransitionFromEntry.Match.newEmptyMatch(); + } + + @Override + public MultipleTransitionFromEntry.Match newMatch(final Object... parameters) { + return MultipleTransitionFromEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[2]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry (visibility: PUBLIC, simpleName: MultipleTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry (visibility: PUBLIC, simpleName: MultipleTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static MultipleTransitionFromEntry INSTANCE = new MultipleTransitionFromEntry(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static MultipleTransitionFromEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); + + private final PParameter parameter_t1 = new PParameter("t1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final PParameter parameter_t2 = new PParameter("t2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_e, parameter_t1, parameter_t2); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("e","t1","t2"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_e = body.getOrCreateVariableByName("e"); + PVariable var_t1 = body.getOrCreateVariableByName("t1"); + PVariable var_t2 = body.getOrCreateVariableByName("t2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_e, parameter_e), + new ExportedParameter(body, var_t1, parameter_t1), + new ExportedParameter(body, var_t2, parameter_t2) + )); + // Entry.outgoingTransitions(e,t1) + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new Equality(body, var__virtual_0_, var_t1); + // Entry.outgoingTransitions(e,t2) + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new Equality(body, var__virtual_1_, var_t2); + // t1!=t2 + new Inequality(body, var_t1, var_t2); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("e") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java new file mode 100644 index 00000000..c1f7df4a --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java @@ -0,0 +1,550 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {r1})
+ *         pattern noEntryInRegion(r1 : Region) {
+ *         	neg find entryInRegion(r1, _);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class NoEntryInRegion extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Region fR1; + + private static List parameterNames = makeImmutableList("r1"); + + private Match(final Region pR1) { + this.fR1 = pR1; + } + + @Override + public Object get(final String parameterName) { + if ("r1".equals(parameterName)) return this.fR1; + return null; + } + + public Region getR1() { + return this.fR1; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("r1".equals(parameterName) ) { + this.fR1 = (Region) newValue; + return true; + } + return false; + } + + public void setR1(final Region pR1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fR1 = pR1; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion"; + } + + @Override + public List parameterNames() { + return NoEntryInRegion.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fR1}; + } + + @Override + public NoEntryInRegion.Match toImmutable() { + return isMutable() ? newMatch(fR1) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"r1\"=" + prettyPrintValue(fR1)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fR1); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof NoEntryInRegion.Match)) { + NoEntryInRegion.Match other = (NoEntryInRegion.Match) obj; + return Objects.equals(fR1, other.fR1); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public NoEntryInRegion specification() { + return NoEntryInRegion.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static NoEntryInRegion.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static NoEntryInRegion.Match newMutableMatch(final Region pR1) { + return new Mutable(pR1); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return the (partial) match object. + * + */ + public static NoEntryInRegion.Match newMatch(final Region pR1) { + return new Immutable(pR1); + } + + private static final class Mutable extends NoEntryInRegion.Match { + Mutable(final Region pR1) { + super(pR1); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends NoEntryInRegion.Match { + Immutable(final Region pR1) { + super(pR1); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {r1})
+   * pattern noEntryInRegion(r1 : Region) {
+   * 	neg find entryInRegion(r1, _);
+   * }
+   * 
+ * + * @see Match + * @see NoEntryInRegion + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static NoEntryInRegion.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static NoEntryInRegion.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_R1 = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoEntryInRegion.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Region pR1) { + return rawStreamAllMatches(new Object[]{pR1}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Region pR1) { + return rawStreamAllMatches(new Object[]{pR1}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Region pR1) { + return rawGetOneArbitraryMatch(new Object[]{pR1}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Region pR1) { + return rawHasMatch(new Object[]{pR1}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Region pR1) { + return rawCountMatches(new Object[]{pR1}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Region pR1, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pR1}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pR1 the fixed value of pattern parameter r1, or null if not bound. + * @return the (partial) match object. + * + */ + public NoEntryInRegion.Match newMatch(final Region pR1) { + return NoEntryInRegion.Match.newMatch(pR1); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfr1(final Object[] parameters) { + return rawStreamAllValues(POSITION_R1, parameters).map(Region.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfr1() { + return rawStreamAllValuesOfr1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for r1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfr1() { + return rawStreamAllValuesOfr1(emptyArray()); + } + + @Override + protected NoEntryInRegion.Match tupleToMatch(final Tuple t) { + try { + return NoEntryInRegion.Match.newMatch((Region) t.get(POSITION_R1)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected NoEntryInRegion.Match arrayToMatch(final Object[] match) { + try { + return NoEntryInRegion.Match.newMatch((Region) match[POSITION_R1]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected NoEntryInRegion.Match arrayToMatchMutable(final Object[] match) { + try { + return NoEntryInRegion.Match.newMutableMatch((Region) match[POSITION_R1]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return NoEntryInRegion.instance(); + } + } + + private NoEntryInRegion() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static NoEntryInRegion instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected NoEntryInRegion.Matcher instantiate(final ViatraQueryEngine engine) { + return NoEntryInRegion.Matcher.on(engine); + } + + @Override + public NoEntryInRegion.Matcher instantiate() { + return NoEntryInRegion.Matcher.create(); + } + + @Override + public NoEntryInRegion.Match newEmptyMatch() { + return NoEntryInRegion.Match.newEmptyMatch(); + } + + @Override + public NoEntryInRegion.Match newMatch(final Object... parameters) { + return NoEntryInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion (visibility: PUBLIC, simpleName: NoEntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion (visibility: PUBLIC, simpleName: NoEntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static NoEntryInRegion INSTANCE = new NoEntryInRegion(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static NoEntryInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_r1 = new PParameter("r1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_r1); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("r1"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_r1 = body.getOrCreateVariableByName("r1"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_r1, parameter_r1) + )); + // neg find entryInRegion(r1, _) + new NegativePatternCall(body, Tuples.flatTupleOf(var_r1, var___0_), EntryInRegion.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("r1") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java new file mode 100644 index 00000000..d9a3de50 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java @@ -0,0 +1,551 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {e})
+ *         pattern noOutgoingTransitionFromEntry(e : Entry) {
+ *         	neg find transition(_, e, _);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class NoOutgoingTransitionFromEntry extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Entry fE; + + private static List parameterNames = makeImmutableList("e"); + + private Match(final Entry pE) { + this.fE = pE; + } + + @Override + public Object get(final String parameterName) { + if ("e".equals(parameterName)) return this.fE; + return null; + } + + public Entry getE() { + return this.fE; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("e".equals(parameterName) ) { + this.fE = (Entry) newValue; + return true; + } + return false; + } + + public void setE(final Entry pE) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fE = pE; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry"; + } + + @Override + public List parameterNames() { + return NoOutgoingTransitionFromEntry.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fE}; + } + + @Override + public NoOutgoingTransitionFromEntry.Match toImmutable() { + return isMutable() ? newMatch(fE) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"e\"=" + prettyPrintValue(fE)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fE); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof NoOutgoingTransitionFromEntry.Match)) { + NoOutgoingTransitionFromEntry.Match other = (NoOutgoingTransitionFromEntry.Match) obj; + return Objects.equals(fE, other.fE); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public NoOutgoingTransitionFromEntry specification() { + return NoOutgoingTransitionFromEntry.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static NoOutgoingTransitionFromEntry.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static NoOutgoingTransitionFromEntry.Match newMutableMatch(final Entry pE) { + return new Mutable(pE); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public static NoOutgoingTransitionFromEntry.Match newMatch(final Entry pE) { + return new Immutable(pE); + } + + private static final class Mutable extends NoOutgoingTransitionFromEntry.Match { + Mutable(final Entry pE) { + super(pE); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends NoOutgoingTransitionFromEntry.Match { + Immutable(final Entry pE) { + super(pE); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {e})
+   * pattern noOutgoingTransitionFromEntry(e : Entry) {
+   * 	neg find transition(_, e, _);
+   * }
+   * 
+ * + * @see Match + * @see NoOutgoingTransitionFromEntry + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static NoOutgoingTransitionFromEntry.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static NoOutgoingTransitionFromEntry.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_E = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoOutgoingTransitionFromEntry.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Entry pE) { + return rawStreamAllMatches(new Object[]{pE}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Entry pE) { + return rawStreamAllMatches(new Object[]{pE}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Entry pE) { + return rawGetOneArbitraryMatch(new Object[]{pE}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Entry pE) { + return rawHasMatch(new Object[]{pE}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Entry pE) { + return rawCountMatches(new Object[]{pE}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Entry pE, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pE}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public NoOutgoingTransitionFromEntry.Match newMatch(final Entry pE) { + return NoOutgoingTransitionFromEntry.Match.newMatch(pE); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfe(final Object[] parameters) { + return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()); + } + + @Override + protected NoOutgoingTransitionFromEntry.Match tupleToMatch(final Tuple t) { + try { + return NoOutgoingTransitionFromEntry.Match.newMatch((Entry) t.get(POSITION_E)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected NoOutgoingTransitionFromEntry.Match arrayToMatch(final Object[] match) { + try { + return NoOutgoingTransitionFromEntry.Match.newMatch((Entry) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected NoOutgoingTransitionFromEntry.Match arrayToMatchMutable(final Object[] match) { + try { + return NoOutgoingTransitionFromEntry.Match.newMutableMatch((Entry) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return NoOutgoingTransitionFromEntry.instance(); + } + } + + private NoOutgoingTransitionFromEntry() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static NoOutgoingTransitionFromEntry instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected NoOutgoingTransitionFromEntry.Matcher instantiate(final ViatraQueryEngine engine) { + return NoOutgoingTransitionFromEntry.Matcher.on(engine); + } + + @Override + public NoOutgoingTransitionFromEntry.Matcher instantiate() { + return NoOutgoingTransitionFromEntry.Matcher.create(); + } + + @Override + public NoOutgoingTransitionFromEntry.Match newEmptyMatch() { + return NoOutgoingTransitionFromEntry.Match.newEmptyMatch(); + } + + @Override + public NoOutgoingTransitionFromEntry.Match newMatch(final Object... parameters) { + return NoOutgoingTransitionFromEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry (visibility: PUBLIC, simpleName: NoOutgoingTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry (visibility: PUBLIC, simpleName: NoOutgoingTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static NoOutgoingTransitionFromEntry INSTANCE = new NoOutgoingTransitionFromEntry(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static NoOutgoingTransitionFromEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_e); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("e"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_e = body.getOrCreateVariableByName("e"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_e, parameter_e) + )); + // neg find transition(_, e, _) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_e, var___1_), Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("e") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java new file mode 100644 index 00000000..841339ae --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java @@ -0,0 +1,558 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // State vs Region
+ *         /////////
+ *         
+ *         {@literal @}Constraint(severity="error", message="error", key = {region})
+ *         pattern noStateInRegion(region: Region) {
+ *         	neg find StateInRegion(region,_);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class NoStateInRegion extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Region fRegion; + + private static List parameterNames = makeImmutableList("region"); + + private Match(final Region pRegion) { + this.fRegion = pRegion; + } + + @Override + public Object get(final String parameterName) { + if ("region".equals(parameterName)) return this.fRegion; + return null; + } + + public Region getRegion() { + return this.fRegion; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("region".equals(parameterName) ) { + this.fRegion = (Region) newValue; + return true; + } + return false; + } + + public void setRegion(final Region pRegion) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fRegion = pRegion; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion"; + } + + @Override + public List parameterNames() { + return NoStateInRegion.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fRegion}; + } + + @Override + public NoStateInRegion.Match toImmutable() { + return isMutable() ? newMatch(fRegion) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"region\"=" + prettyPrintValue(fRegion)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fRegion); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof NoStateInRegion.Match)) { + NoStateInRegion.Match other = (NoStateInRegion.Match) obj; + return Objects.equals(fRegion, other.fRegion); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public NoStateInRegion specification() { + return NoStateInRegion.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static NoStateInRegion.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static NoStateInRegion.Match newMutableMatch(final Region pRegion) { + return new Mutable(pRegion); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return the (partial) match object. + * + */ + public static NoStateInRegion.Match newMatch(final Region pRegion) { + return new Immutable(pRegion); + } + + private static final class Mutable extends NoStateInRegion.Match { + Mutable(final Region pRegion) { + super(pRegion); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends NoStateInRegion.Match { + Immutable(final Region pRegion) { + super(pRegion); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // State vs Region
+   * /////////
+   * 
+   * {@literal @}Constraint(severity="error", message="error", key = {region})
+   * pattern noStateInRegion(region: Region) {
+   * 	neg find StateInRegion(region,_);
+   * }
+   * 
+ * + * @see Match + * @see NoStateInRegion + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static NoStateInRegion.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static NoStateInRegion.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_REGION = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoStateInRegion.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Region pRegion) { + return rawStreamAllMatches(new Object[]{pRegion}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Region pRegion) { + return rawStreamAllMatches(new Object[]{pRegion}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Region pRegion) { + return rawGetOneArbitraryMatch(new Object[]{pRegion}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Region pRegion) { + return rawHasMatch(new Object[]{pRegion}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Region pRegion) { + return rawCountMatches(new Object[]{pRegion}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Region pRegion, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pRegion}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @return the (partial) match object. + * + */ + public NoStateInRegion.Match newMatch(final Region pRegion) { + return NoStateInRegion.Match.newMatch(pRegion); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfregion(final Object[] parameters) { + return rawStreamAllValues(POSITION_REGION, parameters).map(Region.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfregion() { + return rawStreamAllValuesOfregion(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfregion() { + return rawStreamAllValuesOfregion(emptyArray()); + } + + @Override + protected NoStateInRegion.Match tupleToMatch(final Tuple t) { + try { + return NoStateInRegion.Match.newMatch((Region) t.get(POSITION_REGION)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected NoStateInRegion.Match arrayToMatch(final Object[] match) { + try { + return NoStateInRegion.Match.newMatch((Region) match[POSITION_REGION]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected NoStateInRegion.Match arrayToMatchMutable(final Object[] match) { + try { + return NoStateInRegion.Match.newMutableMatch((Region) match[POSITION_REGION]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return NoStateInRegion.instance(); + } + } + + private NoStateInRegion() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static NoStateInRegion instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected NoStateInRegion.Matcher instantiate(final ViatraQueryEngine engine) { + return NoStateInRegion.Matcher.on(engine); + } + + @Override + public NoStateInRegion.Matcher instantiate() { + return NoStateInRegion.Matcher.create(); + } + + @Override + public NoStateInRegion.Match newEmptyMatch() { + return NoStateInRegion.Match.newEmptyMatch(); + } + + @Override + public NoStateInRegion.Match newMatch(final Object... parameters) { + return NoStateInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion (visibility: PUBLIC, simpleName: NoStateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion (visibility: PUBLIC, simpleName: NoStateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static NoStateInRegion INSTANCE = new NoStateInRegion(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static NoStateInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_region = new PParameter("region", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_region); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("region"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_region = body.getOrCreateVariableByName("region"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_region, parameter_region) + )); + // neg find StateInRegion(region,_) + new NegativePatternCall(body, Tuples.flatTupleOf(var_region, var___0_), StateInRegion.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("region") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java new file mode 100644 index 00000000..b9a60ca9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java @@ -0,0 +1,554 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern notSynchronizingStates(s : Synchronization) {
+ *         	neg find hasMultipleOutgoingTrainsition(s);
+ *         	neg find hasMultipleIncomingTrainsition(s);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class NotSynchronizingStates extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private static List parameterNames = makeImmutableList("s"); + + private Match(final Synchronization pS) { + this.fS = pS; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates"; + } + + @Override + public List parameterNames() { + return NotSynchronizingStates.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS}; + } + + @Override + public NotSynchronizingStates.Match toImmutable() { + return isMutable() ? newMatch(fS) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof NotSynchronizingStates.Match)) { + NotSynchronizingStates.Match other = (NotSynchronizingStates.Match) obj; + return Objects.equals(fS, other.fS); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public NotSynchronizingStates specification() { + return NotSynchronizingStates.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static NotSynchronizingStates.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static NotSynchronizingStates.Match newMutableMatch(final Synchronization pS) { + return new Mutable(pS); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public static NotSynchronizingStates.Match newMatch(final Synchronization pS) { + return new Immutable(pS); + } + + private static final class Mutable extends NotSynchronizingStates.Match { + Mutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends NotSynchronizingStates.Match { + Immutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern notSynchronizingStates(s : Synchronization) {
+   * 	neg find hasMultipleOutgoingTrainsition(s);
+   * 	neg find hasMultipleIncomingTrainsition(s);
+   * }
+   * 
+ * + * @see Match + * @see NotSynchronizingStates + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static NotSynchronizingStates.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static NotSynchronizingStates.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NotSynchronizingStates.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS) { + return rawGetOneArbitraryMatch(new Object[]{pS}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS) { + return rawHasMatch(new Object[]{pS}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS) { + return rawCountMatches(new Object[]{pS}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public NotSynchronizingStates.Match newMatch(final Synchronization pS) { + return NotSynchronizingStates.Match.newMatch(pS); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + @Override + protected NotSynchronizingStates.Match tupleToMatch(final Tuple t) { + try { + return NotSynchronizingStates.Match.newMatch((Synchronization) t.get(POSITION_S)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected NotSynchronizingStates.Match arrayToMatch(final Object[] match) { + try { + return NotSynchronizingStates.Match.newMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected NotSynchronizingStates.Match arrayToMatchMutable(final Object[] match) { + try { + return NotSynchronizingStates.Match.newMutableMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return NotSynchronizingStates.instance(); + } + } + + private NotSynchronizingStates() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static NotSynchronizingStates instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected NotSynchronizingStates.Matcher instantiate(final ViatraQueryEngine engine) { + return NotSynchronizingStates.Matcher.on(engine); + } + + @Override + public NotSynchronizingStates.Matcher instantiate() { + return NotSynchronizingStates.Matcher.create(); + } + + @Override + public NotSynchronizingStates.Match newEmptyMatch() { + return NotSynchronizingStates.Match.newEmptyMatch(); + } + + @Override + public NotSynchronizingStates.Match newMatch(final Object... parameters) { + return NotSynchronizingStates.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates (visibility: PUBLIC, simpleName: NotSynchronizingStates, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates (visibility: PUBLIC, simpleName: NotSynchronizingStates, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static NotSynchronizingStates INSTANCE = new NotSynchronizingStates(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static NotSynchronizingStates.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s) + )); + // neg find hasMultipleOutgoingTrainsition(s) + new NegativePatternCall(body, Tuples.flatTupleOf(var_s), HasMultipleOutgoingTrainsition.instance().getInternalQueryRepresentation()); + // neg find hasMultipleIncomingTrainsition(s) + new NegativePatternCall(body, Tuples.flatTupleOf(var_s), HasMultipleIncomingTrainsition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java new file mode 100644 index 00000000..10f0e056 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java @@ -0,0 +1,715 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // Exit
+ *         /////////
+ *         
+ *         {@literal @}Constraint(severity="error", message="error", key = {e})
+ *         pattern outgoingFromExit(t : Transition, e : Exit) {
+ *         	Exit.outgoingTransitions(e,t);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class OutgoingFromExit extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Transition fT; + + private Exit fE; + + private static List parameterNames = makeImmutableList("t", "e"); + + private Match(final Transition pT, final Exit pE) { + this.fT = pT; + this.fE = pE; + } + + @Override + public Object get(final String parameterName) { + if ("t".equals(parameterName)) return this.fT; + if ("e".equals(parameterName)) return this.fE; + return null; + } + + public Transition getT() { + return this.fT; + } + + public Exit getE() { + return this.fE; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("t".equals(parameterName) ) { + this.fT = (Transition) newValue; + return true; + } + if ("e".equals(parameterName) ) { + this.fE = (Exit) newValue; + return true; + } + return false; + } + + public void setT(final Transition pT) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT = pT; + } + + public void setE(final Exit pE) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fE = pE; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit"; + } + + @Override + public List parameterNames() { + return OutgoingFromExit.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fT, fE}; + } + + @Override + public OutgoingFromExit.Match toImmutable() { + return isMutable() ? newMatch(fT, fE) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"t\"=" + prettyPrintValue(fT) + ", "); + result.append("\"e\"=" + prettyPrintValue(fE)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fT, fE); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof OutgoingFromExit.Match)) { + OutgoingFromExit.Match other = (OutgoingFromExit.Match) obj; + return Objects.equals(fT, other.fT) && Objects.equals(fE, other.fE); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public OutgoingFromExit specification() { + return OutgoingFromExit.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static OutgoingFromExit.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static OutgoingFromExit.Match newMutableMatch(final Transition pT, final Exit pE) { + return new Mutable(pT, pE); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public static OutgoingFromExit.Match newMatch(final Transition pT, final Exit pE) { + return new Immutable(pT, pE); + } + + private static final class Mutable extends OutgoingFromExit.Match { + Mutable(final Transition pT, final Exit pE) { + super(pT, pE); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends OutgoingFromExit.Match { + Immutable(final Transition pT, final Exit pE) { + super(pT, pE); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // Exit
+   * /////////
+   * 
+   * {@literal @}Constraint(severity="error", message="error", key = {e})
+   * pattern outgoingFromExit(t : Transition, e : Exit) {
+   * 	Exit.outgoingTransitions(e,t);
+   * }
+   * 
+ * + * @see Match + * @see OutgoingFromExit + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static OutgoingFromExit.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static OutgoingFromExit.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_T = 0; + + private final static int POSITION_E = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(OutgoingFromExit.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Transition pT, final Exit pE) { + return rawStreamAllMatches(new Object[]{pT, pE}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Transition pT, final Exit pE) { + return rawStreamAllMatches(new Object[]{pT, pE}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Transition pT, final Exit pE) { + return rawGetOneArbitraryMatch(new Object[]{pT, pE}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Transition pT, final Exit pE) { + return rawHasMatch(new Object[]{pT, pE}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Transition pT, final Exit pE) { + return rawCountMatches(new Object[]{pT, pE}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Transition pT, final Exit pE, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pT, pE}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pE the fixed value of pattern parameter e, or null if not bound. + * @return the (partial) match object. + * + */ + public OutgoingFromExit.Match newMatch(final Transition pT, final Exit pE) { + return OutgoingFromExit.Match.newMatch(pT, pE); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft(final Object[] parameters) { + return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final OutgoingFromExit.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final Exit pE) { + return rawStreamAllValuesOft(new Object[]{null, pE}); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final OutgoingFromExit.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final Exit pE) { + return rawStreamAllValuesOft(new Object[]{null, pE}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfe(final Object[] parameters) { + return rawStreamAllValues(POSITION_E, parameters).map(Exit.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe() { + return rawStreamAllValuesOfe(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final OutgoingFromExit.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for e. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfe(final Transition pT) { + return rawStreamAllValuesOfe(new Object[]{pT, null}); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final OutgoingFromExit.Match partialMatch) { + return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for e. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfe(final Transition pT) { + return rawStreamAllValuesOfe(new Object[]{pT, null}).collect(Collectors.toSet()); + } + + @Override + protected OutgoingFromExit.Match tupleToMatch(final Tuple t) { + try { + return OutgoingFromExit.Match.newMatch((Transition) t.get(POSITION_T), (Exit) t.get(POSITION_E)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected OutgoingFromExit.Match arrayToMatch(final Object[] match) { + try { + return OutgoingFromExit.Match.newMatch((Transition) match[POSITION_T], (Exit) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected OutgoingFromExit.Match arrayToMatchMutable(final Object[] match) { + try { + return OutgoingFromExit.Match.newMutableMatch((Transition) match[POSITION_T], (Exit) match[POSITION_E]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return OutgoingFromExit.instance(); + } + } + + private OutgoingFromExit() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static OutgoingFromExit instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected OutgoingFromExit.Matcher instantiate(final ViatraQueryEngine engine) { + return OutgoingFromExit.Matcher.on(engine); + } + + @Override + public OutgoingFromExit.Matcher instantiate() { + return OutgoingFromExit.Matcher.create(); + } + + @Override + public OutgoingFromExit.Match newEmptyMatch() { + return OutgoingFromExit.Match.newEmptyMatch(); + } + + @Override + public OutgoingFromExit.Match newMatch(final Object... parameters) { + return OutgoingFromExit.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit (visibility: PUBLIC, simpleName: OutgoingFromExit, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit (visibility: PUBLIC, simpleName: OutgoingFromExit, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static OutgoingFromExit INSTANCE = new OutgoingFromExit(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static OutgoingFromExit.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Exit")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_t, parameter_e); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("t","e"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_t = body.getOrCreateVariableByName("t"); + PVariable var_e = body.getOrCreateVariableByName("e"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Exit"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_t, parameter_t), + new ExportedParameter(body, var_e, parameter_e) + )); + // Exit.outgoingTransitions(e,t) + new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Exit"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new Equality(body, var__virtual_0_, var_t); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("e") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java new file mode 100644 index 00000000..fbac352b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java @@ -0,0 +1,715 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // Final
+ *         /////////
+ *         
+ *         {@literal @}Constraint(severity="error", message="error", key = {f})
+ *         pattern outgoingFromFinal(t : Transition, f : FinalState) {
+ *         	FinalState.outgoingTransitions(f,t);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class OutgoingFromFinal extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Transition fT; + + private FinalState fF; + + private static List parameterNames = makeImmutableList("t", "f"); + + private Match(final Transition pT, final FinalState pF) { + this.fT = pT; + this.fF = pF; + } + + @Override + public Object get(final String parameterName) { + if ("t".equals(parameterName)) return this.fT; + if ("f".equals(parameterName)) return this.fF; + return null; + } + + public Transition getT() { + return this.fT; + } + + public FinalState getF() { + return this.fF; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("t".equals(parameterName) ) { + this.fT = (Transition) newValue; + return true; + } + if ("f".equals(parameterName) ) { + this.fF = (FinalState) newValue; + return true; + } + return false; + } + + public void setT(final Transition pT) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT = pT; + } + + public void setF(final FinalState pF) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fF = pF; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal"; + } + + @Override + public List parameterNames() { + return OutgoingFromFinal.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fT, fF}; + } + + @Override + public OutgoingFromFinal.Match toImmutable() { + return isMutable() ? newMatch(fT, fF) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"t\"=" + prettyPrintValue(fT) + ", "); + result.append("\"f\"=" + prettyPrintValue(fF)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fT, fF); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof OutgoingFromFinal.Match)) { + OutgoingFromFinal.Match other = (OutgoingFromFinal.Match) obj; + return Objects.equals(fT, other.fT) && Objects.equals(fF, other.fF); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public OutgoingFromFinal specification() { + return OutgoingFromFinal.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static OutgoingFromFinal.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static OutgoingFromFinal.Match newMutableMatch(final Transition pT, final FinalState pF) { + return new Mutable(pT, pF); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return the (partial) match object. + * + */ + public static OutgoingFromFinal.Match newMatch(final Transition pT, final FinalState pF) { + return new Immutable(pT, pF); + } + + private static final class Mutable extends OutgoingFromFinal.Match { + Mutable(final Transition pT, final FinalState pF) { + super(pT, pF); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends OutgoingFromFinal.Match { + Immutable(final Transition pT, final FinalState pF) { + super(pT, pF); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // Final
+   * /////////
+   * 
+   * {@literal @}Constraint(severity="error", message="error", key = {f})
+   * pattern outgoingFromFinal(t : Transition, f : FinalState) {
+   * 	FinalState.outgoingTransitions(f,t);
+   * }
+   * 
+ * + * @see Match + * @see OutgoingFromFinal + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static OutgoingFromFinal.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static OutgoingFromFinal.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_T = 0; + + private final static int POSITION_F = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(OutgoingFromFinal.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Transition pT, final FinalState pF) { + return rawStreamAllMatches(new Object[]{pT, pF}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Transition pT, final FinalState pF) { + return rawStreamAllMatches(new Object[]{pT, pF}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Transition pT, final FinalState pF) { + return rawGetOneArbitraryMatch(new Object[]{pT, pF}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Transition pT, final FinalState pF) { + return rawHasMatch(new Object[]{pT, pF}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Transition pT, final FinalState pF) { + return rawCountMatches(new Object[]{pT, pF}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Transition pT, final FinalState pF, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pT, pF}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pF the fixed value of pattern parameter f, or null if not bound. + * @return the (partial) match object. + * + */ + public OutgoingFromFinal.Match newMatch(final Transition pT, final FinalState pF) { + return OutgoingFromFinal.Match.newMatch(pT, pF); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft(final Object[] parameters) { + return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final OutgoingFromFinal.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final FinalState pF) { + return rawStreamAllValuesOft(new Object[]{null, pF}); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final OutgoingFromFinal.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final FinalState pF) { + return rawStreamAllValuesOft(new Object[]{null, pF}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for f. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOff(final Object[] parameters) { + return rawStreamAllValues(POSITION_F, parameters).map(FinalState.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for f. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOff() { + return rawStreamAllValuesOff(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for f. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOff() { + return rawStreamAllValuesOff(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for f. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOff(final OutgoingFromFinal.Match partialMatch) { + return rawStreamAllValuesOff(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for f. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOff(final Transition pT) { + return rawStreamAllValuesOff(new Object[]{pT, null}); + } + + /** + * Retrieve the set of values that occur in matches for f. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOff(final OutgoingFromFinal.Match partialMatch) { + return rawStreamAllValuesOff(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for f. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOff(final Transition pT) { + return rawStreamAllValuesOff(new Object[]{pT, null}).collect(Collectors.toSet()); + } + + @Override + protected OutgoingFromFinal.Match tupleToMatch(final Tuple t) { + try { + return OutgoingFromFinal.Match.newMatch((Transition) t.get(POSITION_T), (FinalState) t.get(POSITION_F)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected OutgoingFromFinal.Match arrayToMatch(final Object[] match) { + try { + return OutgoingFromFinal.Match.newMatch((Transition) match[POSITION_T], (FinalState) match[POSITION_F]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected OutgoingFromFinal.Match arrayToMatchMutable(final Object[] match) { + try { + return OutgoingFromFinal.Match.newMutableMatch((Transition) match[POSITION_T], (FinalState) match[POSITION_F]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return OutgoingFromFinal.instance(); + } + } + + private OutgoingFromFinal() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static OutgoingFromFinal instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected OutgoingFromFinal.Matcher instantiate(final ViatraQueryEngine engine) { + return OutgoingFromFinal.Matcher.on(engine); + } + + @Override + public OutgoingFromFinal.Matcher instantiate() { + return OutgoingFromFinal.Matcher.create(); + } + + @Override + public OutgoingFromFinal.Match newEmptyMatch() { + return OutgoingFromFinal.Match.newEmptyMatch(); + } + + @Override + public OutgoingFromFinal.Match newMatch(final Object... parameters) { + return OutgoingFromFinal.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal (visibility: PUBLIC, simpleName: OutgoingFromFinal, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal (visibility: PUBLIC, simpleName: OutgoingFromFinal, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static OutgoingFromFinal INSTANCE = new OutgoingFromFinal(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static OutgoingFromFinal.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final PParameter parameter_f = new PParameter("f", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "FinalState")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_t, parameter_f); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("t","f"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_t = body.getOrCreateVariableByName("t"); + PVariable var_f = body.getOrCreateVariableByName("f"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_f), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "FinalState"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_t, parameter_t), + new ExportedParameter(body, var_f, parameter_f) + )); + // FinalState.outgoingTransitions(f,t) + new TypeConstraint(body, Tuples.flatTupleOf(var_f), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "FinalState"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_f, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new Equality(body, var__virtual_0_, var_t); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("f") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java new file mode 100644 index 00000000..0d1fd0e6 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java @@ -0,0 +1,694 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern StateInRegion(region: Region, state: State) {
+ *         	Region.vertices(region,state);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class StateInRegion extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Region fRegion; + + private State fState; + + private static List parameterNames = makeImmutableList("region", "state"); + + private Match(final Region pRegion, final State pState) { + this.fRegion = pRegion; + this.fState = pState; + } + + @Override + public Object get(final String parameterName) { + if ("region".equals(parameterName)) return this.fRegion; + if ("state".equals(parameterName)) return this.fState; + return null; + } + + public Region getRegion() { + return this.fRegion; + } + + public State getState() { + return this.fState; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("region".equals(parameterName) ) { + this.fRegion = (Region) newValue; + return true; + } + if ("state".equals(parameterName) ) { + this.fState = (State) newValue; + return true; + } + return false; + } + + public void setRegion(final Region pRegion) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fRegion = pRegion; + } + + public void setState(final State pState) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fState = pState; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion"; + } + + @Override + public List parameterNames() { + return StateInRegion.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fRegion, fState}; + } + + @Override + public StateInRegion.Match toImmutable() { + return isMutable() ? newMatch(fRegion, fState) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"region\"=" + prettyPrintValue(fRegion) + ", "); + result.append("\"state\"=" + prettyPrintValue(fState)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fRegion, fState); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof StateInRegion.Match)) { + StateInRegion.Match other = (StateInRegion.Match) obj; + return Objects.equals(fRegion, other.fRegion) && Objects.equals(fState, other.fState); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public StateInRegion specification() { + return StateInRegion.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static StateInRegion.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static StateInRegion.Match newMutableMatch(final Region pRegion, final State pState) { + return new Mutable(pRegion, pState); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return the (partial) match object. + * + */ + public static StateInRegion.Match newMatch(final Region pRegion, final State pState) { + return new Immutable(pRegion, pState); + } + + private static final class Mutable extends StateInRegion.Match { + Mutable(final Region pRegion, final State pState) { + super(pRegion, pState); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends StateInRegion.Match { + Immutable(final Region pRegion, final State pState) { + super(pRegion, pState); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern StateInRegion(region: Region, state: State) {
+   * 	Region.vertices(region,state);
+   * }
+   * 
+ * + * @see Match + * @see StateInRegion + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static StateInRegion.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static StateInRegion.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_REGION = 0; + + private final static int POSITION_STATE = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(StateInRegion.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Region pRegion, final State pState) { + return rawStreamAllMatches(new Object[]{pRegion, pState}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Region pRegion, final State pState) { + return rawStreamAllMatches(new Object[]{pRegion, pState}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Region pRegion, final State pState) { + return rawGetOneArbitraryMatch(new Object[]{pRegion, pState}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Region pRegion, final State pState) { + return rawHasMatch(new Object[]{pRegion, pState}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Region pRegion, final State pState) { + return rawCountMatches(new Object[]{pRegion, pState}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Region pRegion, final State pState, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pRegion, pState}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pRegion the fixed value of pattern parameter region, or null if not bound. + * @param pState the fixed value of pattern parameter state, or null if not bound. + * @return the (partial) match object. + * + */ + public StateInRegion.Match newMatch(final Region pRegion, final State pState) { + return StateInRegion.Match.newMatch(pRegion, pState); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfregion(final Object[] parameters) { + return rawStreamAllValues(POSITION_REGION, parameters).map(Region.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfregion() { + return rawStreamAllValuesOfregion(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfregion() { + return rawStreamAllValuesOfregion(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for region. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfregion(final StateInRegion.Match partialMatch) { + return rawStreamAllValuesOfregion(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for region. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfregion(final State pState) { + return rawStreamAllValuesOfregion(new Object[]{null, pState}); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfregion(final StateInRegion.Match partialMatch) { + return rawStreamAllValuesOfregion(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for region. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfregion(final State pState) { + return rawStreamAllValuesOfregion(new Object[]{null, pState}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for state. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfstate(final Object[] parameters) { + return rawStreamAllValues(POSITION_STATE, parameters).map(State.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for state. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfstate() { + return rawStreamAllValuesOfstate(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for state. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfstate() { + return rawStreamAllValuesOfstate(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for state. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfstate(final StateInRegion.Match partialMatch) { + return rawStreamAllValuesOfstate(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for state. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfstate(final Region pRegion) { + return rawStreamAllValuesOfstate(new Object[]{pRegion, null}); + } + + /** + * Retrieve the set of values that occur in matches for state. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfstate(final StateInRegion.Match partialMatch) { + return rawStreamAllValuesOfstate(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for state. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfstate(final Region pRegion) { + return rawStreamAllValuesOfstate(new Object[]{pRegion, null}).collect(Collectors.toSet()); + } + + @Override + protected StateInRegion.Match tupleToMatch(final Tuple t) { + try { + return StateInRegion.Match.newMatch((Region) t.get(POSITION_REGION), (State) t.get(POSITION_STATE)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected StateInRegion.Match arrayToMatch(final Object[] match) { + try { + return StateInRegion.Match.newMatch((Region) match[POSITION_REGION], (State) match[POSITION_STATE]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected StateInRegion.Match arrayToMatchMutable(final Object[] match) { + try { + return StateInRegion.Match.newMutableMatch((Region) match[POSITION_REGION], (State) match[POSITION_STATE]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return StateInRegion.instance(); + } + } + + private StateInRegion() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static StateInRegion instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected StateInRegion.Matcher instantiate(final ViatraQueryEngine engine) { + return StateInRegion.Matcher.on(engine); + } + + @Override + public StateInRegion.Matcher instantiate() { + return StateInRegion.Matcher.create(); + } + + @Override + public StateInRegion.Match newEmptyMatch() { + return StateInRegion.Match.newEmptyMatch(); + } + + @Override + public StateInRegion.Match newMatch(final Object... parameters) { + return StateInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion (visibility: PUBLIC, simpleName: StateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion (visibility: PUBLIC, simpleName: StateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static StateInRegion INSTANCE = new StateInRegion(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static StateInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_region = new PParameter("region", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); + + private final PParameter parameter_state = new PParameter("state", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "State")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_region, parameter_state); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("region","state"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_region = body.getOrCreateVariableByName("region"); + PVariable var_state = body.getOrCreateVariableByName("state"); + new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_state), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "State"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_region, parameter_region), + new ExportedParameter(body, var_state, parameter_state) + )); + // Region.vertices(region,state) + new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_region, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_state); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java new file mode 100644 index 00000000..d59ab2d9 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java @@ -0,0 +1,551 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern synchHasNoIncoming(s : Synchronization) {
+ *         	neg find transition(_, _, s);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchHasNoIncoming extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private static List parameterNames = makeImmutableList("s"); + + private Match(final Synchronization pS) { + this.fS = pS; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming"; + } + + @Override + public List parameterNames() { + return SynchHasNoIncoming.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS}; + } + + @Override + public SynchHasNoIncoming.Match toImmutable() { + return isMutable() ? newMatch(fS) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchHasNoIncoming.Match)) { + SynchHasNoIncoming.Match other = (SynchHasNoIncoming.Match) obj; + return Objects.equals(fS, other.fS); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchHasNoIncoming specification() { + return SynchHasNoIncoming.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchHasNoIncoming.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchHasNoIncoming.Match newMutableMatch(final Synchronization pS) { + return new Mutable(pS); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchHasNoIncoming.Match newMatch(final Synchronization pS) { + return new Immutable(pS); + } + + private static final class Mutable extends SynchHasNoIncoming.Match { + Mutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchHasNoIncoming.Match { + Immutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern synchHasNoIncoming(s : Synchronization) {
+   * 	neg find transition(_, _, s);
+   * }
+   * 
+ * + * @see Match + * @see SynchHasNoIncoming + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchHasNoIncoming.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchHasNoIncoming.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchHasNoIncoming.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS) { + return rawGetOneArbitraryMatch(new Object[]{pS}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS) { + return rawHasMatch(new Object[]{pS}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS) { + return rawCountMatches(new Object[]{pS}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchHasNoIncoming.Match newMatch(final Synchronization pS) { + return SynchHasNoIncoming.Match.newMatch(pS); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + @Override + protected SynchHasNoIncoming.Match tupleToMatch(final Tuple t) { + try { + return SynchHasNoIncoming.Match.newMatch((Synchronization) t.get(POSITION_S)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchHasNoIncoming.Match arrayToMatch(final Object[] match) { + try { + return SynchHasNoIncoming.Match.newMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchHasNoIncoming.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchHasNoIncoming.Match.newMutableMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchHasNoIncoming.instance(); + } + } + + private SynchHasNoIncoming() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchHasNoIncoming instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchHasNoIncoming.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchHasNoIncoming.Matcher.on(engine); + } + + @Override + public SynchHasNoIncoming.Matcher instantiate() { + return SynchHasNoIncoming.Matcher.create(); + } + + @Override + public SynchHasNoIncoming.Match newEmptyMatch() { + return SynchHasNoIncoming.Match.newEmptyMatch(); + } + + @Override + public SynchHasNoIncoming.Match newMatch(final Object... parameters) { + return SynchHasNoIncoming.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming (visibility: PUBLIC, simpleName: SynchHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming (visibility: PUBLIC, simpleName: SynchHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchHasNoIncoming INSTANCE = new SynchHasNoIncoming(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchHasNoIncoming.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s) + )); + // neg find transition(_, _, s) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var___1_, var_s), Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java new file mode 100644 index 00000000..e3ff69bd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java @@ -0,0 +1,559 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         /////////
+ *         // Synchronization
+ *         /////////
+ *         
+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern synchHasNoOutgoing(s : Synchronization) {
+ *         	neg find transition(_, s, _);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchHasNoOutgoing extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private static List parameterNames = makeImmutableList("s"); + + private Match(final Synchronization pS) { + this.fS = pS; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing"; + } + + @Override + public List parameterNames() { + return SynchHasNoOutgoing.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS}; + } + + @Override + public SynchHasNoOutgoing.Match toImmutable() { + return isMutable() ? newMatch(fS) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchHasNoOutgoing.Match)) { + SynchHasNoOutgoing.Match other = (SynchHasNoOutgoing.Match) obj; + return Objects.equals(fS, other.fS); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchHasNoOutgoing specification() { + return SynchHasNoOutgoing.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchHasNoOutgoing.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchHasNoOutgoing.Match newMutableMatch(final Synchronization pS) { + return new Mutable(pS); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchHasNoOutgoing.Match newMatch(final Synchronization pS) { + return new Immutable(pS); + } + + private static final class Mutable extends SynchHasNoOutgoing.Match { + Mutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchHasNoOutgoing.Match { + Immutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * /////////
+   * // Synchronization
+   * /////////
+   * 
+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern synchHasNoOutgoing(s : Synchronization) {
+   * 	neg find transition(_, s, _);
+   * }
+   * 
+ * + * @see Match + * @see SynchHasNoOutgoing + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchHasNoOutgoing.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchHasNoOutgoing.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchHasNoOutgoing.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS) { + return rawGetOneArbitraryMatch(new Object[]{pS}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS) { + return rawHasMatch(new Object[]{pS}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS) { + return rawCountMatches(new Object[]{pS}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchHasNoOutgoing.Match newMatch(final Synchronization pS) { + return SynchHasNoOutgoing.Match.newMatch(pS); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + @Override + protected SynchHasNoOutgoing.Match tupleToMatch(final Tuple t) { + try { + return SynchHasNoOutgoing.Match.newMatch((Synchronization) t.get(POSITION_S)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchHasNoOutgoing.Match arrayToMatch(final Object[] match) { + try { + return SynchHasNoOutgoing.Match.newMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchHasNoOutgoing.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchHasNoOutgoing.Match.newMutableMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchHasNoOutgoing.instance(); + } + } + + private SynchHasNoOutgoing() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchHasNoOutgoing instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchHasNoOutgoing.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchHasNoOutgoing.Matcher.on(engine); + } + + @Override + public SynchHasNoOutgoing.Matcher instantiate() { + return SynchHasNoOutgoing.Matcher.create(); + } + + @Override + public SynchHasNoOutgoing.Match newEmptyMatch() { + return SynchHasNoOutgoing.Match.newEmptyMatch(); + } + + @Override + public SynchHasNoOutgoing.Match newMatch(final Object... parameters) { + return SynchHasNoOutgoing.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing (visibility: PUBLIC, simpleName: SynchHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing (visibility: PUBLIC, simpleName: SynchHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchHasNoOutgoing INSTANCE = new SynchHasNoOutgoing(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchHasNoOutgoing.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s) + )); + // neg find transition(_, s, _) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var___1_), Transition.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java new file mode 100644 index 00000000..228db3a0 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java @@ -0,0 +1,639 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         Simplifying model generation
+ *          
+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern synchThree(s: Synchronization) {
+ *         	Transition.target(t1,s);
+ *         	Transition.target(t2,s);
+ *         	Transition.target(t3,s);
+ *         	t1!=t2;
+ *         	t2!=t3;
+ *         	t1!=t3;
+ *         } or {
+ *         	Transition.source(t1,s);
+ *         	Transition.source(t2,s);
+ *         	Transition.source(t3,s);
+ *         	t1!=t2;
+ *         	t2!=t3;
+ *         	t1!=t3;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchThree extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private static List parameterNames = makeImmutableList("s"); + + private Match(final Synchronization pS) { + this.fS = pS; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree"; + } + + @Override + public List parameterNames() { + return SynchThree.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS}; + } + + @Override + public SynchThree.Match toImmutable() { + return isMutable() ? newMatch(fS) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchThree.Match)) { + SynchThree.Match other = (SynchThree.Match) obj; + return Objects.equals(fS, other.fS); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchThree specification() { + return SynchThree.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchThree.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchThree.Match newMutableMatch(final Synchronization pS) { + return new Mutable(pS); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchThree.Match newMatch(final Synchronization pS) { + return new Immutable(pS); + } + + private static final class Mutable extends SynchThree.Match { + Mutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchThree.Match { + Immutable(final Synchronization pS) { + super(pS); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * Simplifying model generation
+   *  
+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern synchThree(s: Synchronization) {
+   * 	Transition.target(t1,s);
+   * 	Transition.target(t2,s);
+   * 	Transition.target(t3,s);
+   * 	t1!=t2;
+   * 	t2!=t3;
+   * 	t1!=t3;
+   * } or {
+   * 	Transition.source(t1,s);
+   * 	Transition.source(t2,s);
+   * 	Transition.source(t3,s);
+   * 	t1!=t2;
+   * 	t2!=t3;
+   * 	t1!=t3;
+   * }
+   * 
+ * + * @see Match + * @see SynchThree + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchThree.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchThree.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchThree.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS) { + return rawStreamAllMatches(new Object[]{pS}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS) { + return rawGetOneArbitraryMatch(new Object[]{pS}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS) { + return rawHasMatch(new Object[]{pS}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS) { + return rawCountMatches(new Object[]{pS}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchThree.Match newMatch(final Synchronization pS) { + return SynchThree.Match.newMatch(pS); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + @Override + protected SynchThree.Match tupleToMatch(final Tuple t) { + try { + return SynchThree.Match.newMatch((Synchronization) t.get(POSITION_S)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchThree.Match arrayToMatch(final Object[] match) { + try { + return SynchThree.Match.newMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchThree.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchThree.Match.newMutableMatch((Synchronization) match[POSITION_S]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchThree.instance(); + } + } + + private SynchThree() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchThree instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchThree.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchThree.Matcher.on(engine); + } + + @Override + public SynchThree.Matcher instantiate() { + return SynchThree.Matcher.create(); + } + + @Override + public SynchThree.Match newEmptyMatch() { + return SynchThree.Match.newEmptyMatch(); + } + + @Override + public SynchThree.Match newMatch(final Object... parameters) { + return SynchThree.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree (visibility: PUBLIC, simpleName: SynchThree, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree (visibility: PUBLIC, simpleName: SynchThree, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchThree INSTANCE = new SynchThree(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchThree.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_t1 = body.getOrCreateVariableByName("t1"); + PVariable var_t2 = body.getOrCreateVariableByName("t2"); + PVariable var_t3 = body.getOrCreateVariableByName("t3"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s) + )); + // Transition.target(t1,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_s); + // Transition.target(t2,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t2, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_s); + // Transition.target(t3,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t3), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t3, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_2_, var_s); + // t1!=t2 + new Inequality(body, var_t1, var_t2); + // t2!=t3 + new Inequality(body, var_t2, var_t3); + // t1!=t3 + new Inequality(body, var_t1, var_t3); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_t1 = body.getOrCreateVariableByName("t1"); + PVariable var_t2 = body.getOrCreateVariableByName("t2"); + PVariable var_t3 = body.getOrCreateVariableByName("t3"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s) + )); + // Transition.source(t1,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_s); + // Transition.source(t2,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t2, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_s); + // Transition.source(t3,s) + new TypeConstraint(body, Tuples.flatTupleOf(var_t3), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t3, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_2_, var_s); + // t1!=t2 + new Inequality(body, var_t1, var_t2); + // t2!=t3 + new Inequality(body, var_t2, var_t3); + // t1!=t3 + new Inequality(body, var_t1, var_t3); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java new file mode 100644 index 00000000..dabbe8c5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java @@ -0,0 +1,888 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) {
+ *         	find transition(t1, v1, s);
+ *         	find transition(t2, v2, s);
+ *         	t1!=t2;
+ *         	Region.vertices(r, v1);
+ *         	Region.vertices(r, v2);
+ *         } or {
+ *         	find transition(t1, s, v1);
+ *         	find transition(t2, s, v2);
+ *         	t1!=t2;
+ *         	Region.vertices(r, v1);
+ *         	Region.vertices(r, v2);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchronizedIncomingInSameRegion extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private Vertex fV1; + + private Vertex fV2; + + private static List parameterNames = makeImmutableList("s", "v1", "v2"); + + private Match(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + this.fS = pS; + this.fV1 = pV1; + this.fV2 = pV2; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + if ("v1".equals(parameterName)) return this.fV1; + if ("v2".equals(parameterName)) return this.fV2; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + public Vertex getV1() { + return this.fV1; + } + + public Vertex getV2() { + return this.fV2; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + if ("v1".equals(parameterName) ) { + this.fV1 = (Vertex) newValue; + return true; + } + if ("v2".equals(parameterName) ) { + this.fV2 = (Vertex) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + public void setV1(final Vertex pV1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV1 = pV1; + } + + public void setV2(final Vertex pV2) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV2 = pV2; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion"; + } + + @Override + public List parameterNames() { + return SynchronizedIncomingInSameRegion.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS, fV1, fV2}; + } + + @Override + public SynchronizedIncomingInSameRegion.Match toImmutable() { + return isMutable() ? newMatch(fS, fV1, fV2) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS) + ", "); + result.append("\"v1\"=" + prettyPrintValue(fV1) + ", "); + result.append("\"v2\"=" + prettyPrintValue(fV2)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS, fV1, fV2); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchronizedIncomingInSameRegion.Match)) { + SynchronizedIncomingInSameRegion.Match other = (SynchronizedIncomingInSameRegion.Match) obj; + return Objects.equals(fS, other.fS) && Objects.equals(fV1, other.fV1) && Objects.equals(fV2, other.fV2); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchronizedIncomingInSameRegion specification() { + return SynchronizedIncomingInSameRegion.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchronizedIncomingInSameRegion.Match newEmptyMatch() { + return new Mutable(null, null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchronizedIncomingInSameRegion.Match newMutableMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return new Mutable(pS, pV1, pV2); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchronizedIncomingInSameRegion.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return new Immutable(pS, pV1, pV2); + } + + private static final class Mutable extends SynchronizedIncomingInSameRegion.Match { + Mutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + super(pS, pV1, pV2); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchronizedIncomingInSameRegion.Match { + Immutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + super(pS, pV1, pV2); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) {
+   * 	find transition(t1, v1, s);
+   * 	find transition(t2, v2, s);
+   * 	t1!=t2;
+   * 	Region.vertices(r, v1);
+   * 	Region.vertices(r, v2);
+   * } or {
+   * 	find transition(t1, s, v1);
+   * 	find transition(t2, s, v2);
+   * 	t1!=t2;
+   * 	Region.vertices(r, v1);
+   * 	Region.vertices(r, v2);
+   * }
+   * 
+ * + * @see Match + * @see SynchronizedIncomingInSameRegion + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchronizedIncomingInSameRegion.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchronizedIncomingInSameRegion.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static int POSITION_V1 = 1; + + private final static int POSITION_V2 = 2; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedIncomingInSameRegion.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawStreamAllMatches(new Object[]{pS, pV1, pV2}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawStreamAllMatches(new Object[]{pS, pV1, pV2}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawGetOneArbitraryMatch(new Object[]{pS, pV1, pV2}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawHasMatch(new Object[]{pS, pV1, pV2}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawCountMatches(new Object[]{pS, pV1, pV2}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS, pV1, pV2}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchronizedIncomingInSameRegion.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return SynchronizedIncomingInSameRegion.Match.newMatch(pS, pV1, pV2); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final Vertex pV1, final Vertex pV2) { + return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final Vertex pV1, final Vertex pV2) { + return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv1(final Object[] parameters) { + return rawStreamAllValues(POSITION_V1, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1() { + return rawStreamAllValuesOfv1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1() { + return rawStreamAllValuesOfv1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfv1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1(final Synchronization pS, final Vertex pV2) { + return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfv1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1(final Synchronization pS, final Vertex pV2) { + return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv2(final Object[] parameters) { + return rawStreamAllValues(POSITION_V2, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2() { + return rawStreamAllValuesOfv2(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2() { + return rawStreamAllValuesOfv2(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfv2(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2(final Synchronization pS, final Vertex pV1) { + return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2(final SynchronizedIncomingInSameRegion.Match partialMatch) { + return rawStreamAllValuesOfv2(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2(final Synchronization pS, final Vertex pV1) { + return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}).collect(Collectors.toSet()); + } + + @Override + protected SynchronizedIncomingInSameRegion.Match tupleToMatch(final Tuple t) { + try { + return SynchronizedIncomingInSameRegion.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V1), (Vertex) t.get(POSITION_V2)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedIncomingInSameRegion.Match arrayToMatch(final Object[] match) { + try { + return SynchronizedIncomingInSameRegion.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedIncomingInSameRegion.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchronizedIncomingInSameRegion.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchronizedIncomingInSameRegion.instance(); + } + } + + private SynchronizedIncomingInSameRegion() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchronizedIncomingInSameRegion instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchronizedIncomingInSameRegion.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchronizedIncomingInSameRegion.Matcher.on(engine); + } + + @Override + public SynchronizedIncomingInSameRegion.Matcher instantiate() { + return SynchronizedIncomingInSameRegion.Matcher.create(); + } + + @Override + public SynchronizedIncomingInSameRegion.Match newEmptyMatch() { + return SynchronizedIncomingInSameRegion.Match.newEmptyMatch(); + } + + @Override + public SynchronizedIncomingInSameRegion.Match newMatch(final Object... parameters) { + return SynchronizedIncomingInSameRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion (visibility: PUBLIC, simpleName: SynchronizedIncomingInSameRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion (visibility: PUBLIC, simpleName: SynchronizedIncomingInSameRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchronizedIncomingInSameRegion INSTANCE = new SynchronizedIncomingInSameRegion(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchronizedIncomingInSameRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final PParameter parameter_v1 = new PParameter("v1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final PParameter parameter_v2 = new PParameter("v2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s, parameter_v1, parameter_v2); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s","v1","v2"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v1 = body.getOrCreateVariableByName("v1"); + PVariable var_v2 = body.getOrCreateVariableByName("v2"); + PVariable var_t1 = body.getOrCreateVariableByName("t1"); + PVariable var_t2 = body.getOrCreateVariableByName("t2"); + PVariable var_r = body.getOrCreateVariableByName("r"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v1, parameter_v1), + new ExportedParameter(body, var_v2, parameter_v2) + )); + // find transition(t1, v1, s) + new PositivePatternCall(body, Tuples.flatTupleOf(var_t1, var_v1, var_s), Transition.instance().getInternalQueryRepresentation()); + // find transition(t2, v2, s) + new PositivePatternCall(body, Tuples.flatTupleOf(var_t2, var_v2, var_s), Transition.instance().getInternalQueryRepresentation()); + // t1!=t2 + new Inequality(body, var_t1, var_t2); + // Region.vertices(r, v1) + new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_v1); + // Region.vertices(r, v2) + new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_v2); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v1 = body.getOrCreateVariableByName("v1"); + PVariable var_v2 = body.getOrCreateVariableByName("v2"); + PVariable var_t1 = body.getOrCreateVariableByName("t1"); + PVariable var_t2 = body.getOrCreateVariableByName("t2"); + PVariable var_r = body.getOrCreateVariableByName("r"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v1, parameter_v1), + new ExportedParameter(body, var_v2, parameter_v2) + )); + // find transition(t1, s, v1) + new PositivePatternCall(body, Tuples.flatTupleOf(var_t1, var_s, var_v1), Transition.instance().getInternalQueryRepresentation()); + // find transition(t2, s, v2) + new PositivePatternCall(body, Tuples.flatTupleOf(var_t2, var_s, var_v2), Transition.instance().getInternalQueryRepresentation()); + // t1!=t2 + new Inequality(body, var_t1, var_t2); + // Region.vertices(r, v1) + new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_v1); + // Region.vertices(r, v2) + new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_v2); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java new file mode 100644 index 00000000..28eecf9c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java @@ -0,0 +1,744 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) {
+ *         	find transition(_, v, s);
+ *         	find child(c,v);
+ *         	neg find hasMultipleRegions(c);
+ *         } or {
+ *         	find transition(_, s, v);
+ *         	find child(c,v);
+ *         	neg find hasMultipleRegions(c);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchronizedRegionDoesNotHaveMultipleRegions extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private Vertex fV; + + private static List parameterNames = makeImmutableList("s", "v"); + + private Match(final Synchronization pS, final Vertex pV) { + this.fS = pS; + this.fV = pV; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + if ("v".equals(parameterName)) return this.fV; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + public Vertex getV() { + return this.fV; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + if ("v".equals(parameterName) ) { + this.fV = (Vertex) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + public void setV(final Vertex pV) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV = pV; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions"; + } + + @Override + public List parameterNames() { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS, fV}; + } + + @Override + public SynchronizedRegionDoesNotHaveMultipleRegions.Match toImmutable() { + return isMutable() ? newMatch(fS, fV) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS) + ", "); + result.append("\"v\"=" + prettyPrintValue(fV)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS, fV); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchronizedRegionDoesNotHaveMultipleRegions.Match)) { + SynchronizedRegionDoesNotHaveMultipleRegions.Match other = (SynchronizedRegionDoesNotHaveMultipleRegions.Match) obj; + return Objects.equals(fS, other.fS) && Objects.equals(fV, other.fV); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchronizedRegionDoesNotHaveMultipleRegions specification() { + return SynchronizedRegionDoesNotHaveMultipleRegions.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newMutableMatch(final Synchronization pS, final Vertex pV) { + return new Mutable(pS, pV); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Synchronization pS, final Vertex pV) { + return new Immutable(pS, pV); + } + + private static final class Mutable extends SynchronizedRegionDoesNotHaveMultipleRegions.Match { + Mutable(final Synchronization pS, final Vertex pV) { + super(pS, pV); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchronizedRegionDoesNotHaveMultipleRegions.Match { + Immutable(final Synchronization pS, final Vertex pV) { + super(pS, pV); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) {
+   * 	find transition(_, v, s);
+   * 	find child(c,v);
+   * 	neg find hasMultipleRegions(c);
+   * } or {
+   * 	find transition(_, s, v);
+   * 	find child(c,v);
+   * 	neg find hasMultipleRegions(c);
+   * }
+   * 
+ * + * @see Match + * @see SynchronizedRegionDoesNotHaveMultipleRegions + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static int POSITION_V = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS, final Vertex pV) { + return rawStreamAllMatches(new Object[]{pS, pV}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS, final Vertex pV) { + return rawStreamAllMatches(new Object[]{pS, pV}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV) { + return rawGetOneArbitraryMatch(new Object[]{pS, pV}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS, final Vertex pV) { + return rawHasMatch(new Object[]{pS, pV}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS, final Vertex pV) { + return rawCountMatches(new Object[]{pS, pV}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS, pV}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV the fixed value of pattern parameter v, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Synchronization pS, final Vertex pV) { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch(pS, pV); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final Vertex pV) { + return rawStreamAllValuesOfs(new Object[]{null, pV}); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final Vertex pV) { + return rawStreamAllValuesOfs(new Object[]{null, pV}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv(final Object[] parameters) { + return rawStreamAllValues(POSITION_V, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv() { + return rawStreamAllValuesOfv(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for v. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { + return rawStreamAllValuesOfv(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for v. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv(final Synchronization pS) { + return rawStreamAllValuesOfv(new Object[]{pS, null}); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { + return rawStreamAllValuesOfv(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv(final Synchronization pS) { + return rawStreamAllValuesOfv(new Object[]{pS, null}).collect(Collectors.toSet()); + } + + @Override + protected SynchronizedRegionDoesNotHaveMultipleRegions.Match tupleToMatch(final Tuple t) { + try { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedRegionDoesNotHaveMultipleRegions.Match arrayToMatch(final Object[] match) { + try { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedRegionDoesNotHaveMultipleRegions.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchronizedRegionDoesNotHaveMultipleRegions.instance(); + } + } + + private SynchronizedRegionDoesNotHaveMultipleRegions() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchronizedRegionDoesNotHaveMultipleRegions instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchronizedRegionDoesNotHaveMultipleRegions.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.on(engine); + } + + @Override + public SynchronizedRegionDoesNotHaveMultipleRegions.Matcher instantiate() { + return SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.create(); + } + + @Override + public SynchronizedRegionDoesNotHaveMultipleRegions.Match newEmptyMatch() { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newEmptyMatch(); + } + + @Override + public SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Object... parameters) { + return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions (visibility: PUBLIC, simpleName: SynchronizedRegionDoesNotHaveMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions (visibility: PUBLIC, simpleName: SynchronizedRegionDoesNotHaveMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchronizedRegionDoesNotHaveMultipleRegions INSTANCE = new SynchronizedRegionDoesNotHaveMultipleRegions(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchronizedRegionDoesNotHaveMultipleRegions.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s, parameter_v); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s","v"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v = body.getOrCreateVariableByName("v"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var_c = body.getOrCreateVariableByName("c"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v, parameter_v) + )); + // find transition(_, v, s) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v, var_s), Transition.instance().getInternalQueryRepresentation()); + // find child(c,v) + new PositivePatternCall(body, Tuples.flatTupleOf(var_c, var_v), Child.instance().getInternalQueryRepresentation()); + // neg find hasMultipleRegions(c) + new NegativePatternCall(body, Tuples.flatTupleOf(var_c), HasMultipleRegions.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v = body.getOrCreateVariableByName("v"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var_c = body.getOrCreateVariableByName("c"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v, parameter_v) + )); + // find transition(_, s, v) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var_v), Transition.instance().getInternalQueryRepresentation()); + // find child(c,v) + new PositivePatternCall(body, Tuples.flatTupleOf(var_c, var_v), Child.instance().getInternalQueryRepresentation()); + // neg find hasMultipleRegions(c) + new NegativePatternCall(body, Tuples.flatTupleOf(var_c), HasMultipleRegions.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java new file mode 100644 index 00000000..160c4aa0 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java @@ -0,0 +1,902 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(severity="error", message="error", key = {s})
+ *         pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) {
+ *         	find transition(_, v1, s);
+ *         	find transition(_, v2, s);
+ *         	CompositeElement.regions.vertices(r1, v1);
+ *         	CompositeElement.regions.vertices(r2, v2);
+ *         	r1 != r2;
+ *         } or {
+ *         	find transition(_, s, v1);
+ *         	find transition(_, s, v2);
+ *         	CompositeElement.regions.vertices(r1, v1);
+ *         	CompositeElement.regions.vertices(r2, v2);
+ *         	r1 != r2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class SynchronizedRegionsAreNotSiblings extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS; + + private Vertex fV1; + + private Vertex fV2; + + private static List parameterNames = makeImmutableList("s", "v1", "v2"); + + private Match(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + this.fS = pS; + this.fV1 = pV1; + this.fV2 = pV2; + } + + @Override + public Object get(final String parameterName) { + if ("s".equals(parameterName)) return this.fS; + if ("v1".equals(parameterName)) return this.fV1; + if ("v2".equals(parameterName)) return this.fV2; + return null; + } + + public Synchronization getS() { + return this.fS; + } + + public Vertex getV1() { + return this.fV1; + } + + public Vertex getV2() { + return this.fV2; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s".equals(parameterName) ) { + this.fS = (Synchronization) newValue; + return true; + } + if ("v1".equals(parameterName) ) { + this.fV1 = (Vertex) newValue; + return true; + } + if ("v2".equals(parameterName) ) { + this.fV2 = (Vertex) newValue; + return true; + } + return false; + } + + public void setS(final Synchronization pS) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS = pS; + } + + public void setV1(final Vertex pV1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV1 = pV1; + } + + public void setV2(final Vertex pV2) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fV2 = pV2; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings"; + } + + @Override + public List parameterNames() { + return SynchronizedRegionsAreNotSiblings.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS, fV1, fV2}; + } + + @Override + public SynchronizedRegionsAreNotSiblings.Match toImmutable() { + return isMutable() ? newMatch(fS, fV1, fV2) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s\"=" + prettyPrintValue(fS) + ", "); + result.append("\"v1\"=" + prettyPrintValue(fV1) + ", "); + result.append("\"v2\"=" + prettyPrintValue(fV2)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS, fV1, fV2); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof SynchronizedRegionsAreNotSiblings.Match)) { + SynchronizedRegionsAreNotSiblings.Match other = (SynchronizedRegionsAreNotSiblings.Match) obj; + return Objects.equals(fS, other.fS) && Objects.equals(fV1, other.fV1) && Objects.equals(fV2, other.fV2); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public SynchronizedRegionsAreNotSiblings specification() { + return SynchronizedRegionsAreNotSiblings.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static SynchronizedRegionsAreNotSiblings.Match newEmptyMatch() { + return new Mutable(null, null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static SynchronizedRegionsAreNotSiblings.Match newMutableMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return new Mutable(pS, pV1, pV2); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the (partial) match object. + * + */ + public static SynchronizedRegionsAreNotSiblings.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return new Immutable(pS, pV1, pV2); + } + + private static final class Mutable extends SynchronizedRegionsAreNotSiblings.Match { + Mutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + super(pS, pV1, pV2); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends SynchronizedRegionsAreNotSiblings.Match { + Immutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + super(pS, pV1, pV2); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(severity="error", message="error", key = {s})
+   * pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) {
+   * 	find transition(_, v1, s);
+   * 	find transition(_, v2, s);
+   * 	CompositeElement.regions.vertices(r1, v1);
+   * 	CompositeElement.regions.vertices(r2, v2);
+   * 	r1 != r2;
+   * } or {
+   * 	find transition(_, s, v1);
+   * 	find transition(_, s, v2);
+   * 	CompositeElement.regions.vertices(r1, v1);
+   * 	CompositeElement.regions.vertices(r2, v2);
+   * 	r1 != r2;
+   * }
+   * 
+ * + * @see Match + * @see SynchronizedRegionsAreNotSiblings + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static SynchronizedRegionsAreNotSiblings.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static SynchronizedRegionsAreNotSiblings.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S = 0; + + private final static int POSITION_V1 = 1; + + private final static int POSITION_V2 = 2; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedRegionsAreNotSiblings.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawStreamAllMatches(new Object[]{pS, pV1, pV2}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawStreamAllMatches(new Object[]{pS, pV1, pV2}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawGetOneArbitraryMatch(new Object[]{pS, pV1, pV2}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawHasMatch(new Object[]{pS, pV1, pV2}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return rawCountMatches(new Object[]{pS, pV1, pV2}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS, pV1, pV2}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS the fixed value of pattern parameter s, or null if not bound. + * @param pV1 the fixed value of pattern parameter v1, or null if not bound. + * @param pV2 the fixed value of pattern parameter v2, or null if not bound. + * @return the (partial) match object. + * + */ + public SynchronizedRegionsAreNotSiblings.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { + return SynchronizedRegionsAreNotSiblings.Match.newMatch(pS, pV1, pV2); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs(final Object[] parameters) { + return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs() { + return rawStreamAllValuesOfs(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for s. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs(final Vertex pV1, final Vertex pV2) { + return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs(final Vertex pV1, final Vertex pV2) { + return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv1(final Object[] parameters) { + return rawStreamAllValues(POSITION_V1, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1() { + return rawStreamAllValuesOfv1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1() { + return rawStreamAllValuesOfv1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfv1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv1(final Synchronization pS, final Vertex pV2) { + return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfv1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv1(final Synchronization pS, final Vertex pV2) { + return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfv2(final Object[] parameters) { + return rawStreamAllValues(POSITION_V2, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2() { + return rawStreamAllValuesOfv2(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2() { + return rawStreamAllValuesOfv2(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfv2(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfv2(final Synchronization pS, final Vertex pV1) { + return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { + return rawStreamAllValuesOfv2(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for v2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfv2(final Synchronization pS, final Vertex pV1) { + return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}).collect(Collectors.toSet()); + } + + @Override + protected SynchronizedRegionsAreNotSiblings.Match tupleToMatch(final Tuple t) { + try { + return SynchronizedRegionsAreNotSiblings.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V1), (Vertex) t.get(POSITION_V2)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedRegionsAreNotSiblings.Match arrayToMatch(final Object[] match) { + try { + return SynchronizedRegionsAreNotSiblings.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected SynchronizedRegionsAreNotSiblings.Match arrayToMatchMutable(final Object[] match) { + try { + return SynchronizedRegionsAreNotSiblings.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return SynchronizedRegionsAreNotSiblings.instance(); + } + } + + private SynchronizedRegionsAreNotSiblings() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static SynchronizedRegionsAreNotSiblings instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected SynchronizedRegionsAreNotSiblings.Matcher instantiate(final ViatraQueryEngine engine) { + return SynchronizedRegionsAreNotSiblings.Matcher.on(engine); + } + + @Override + public SynchronizedRegionsAreNotSiblings.Matcher instantiate() { + return SynchronizedRegionsAreNotSiblings.Matcher.create(); + } + + @Override + public SynchronizedRegionsAreNotSiblings.Match newEmptyMatch() { + return SynchronizedRegionsAreNotSiblings.Match.newEmptyMatch(); + } + + @Override + public SynchronizedRegionsAreNotSiblings.Match newMatch(final Object... parameters) { + return SynchronizedRegionsAreNotSiblings.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings (visibility: PUBLIC, simpleName: SynchronizedRegionsAreNotSiblings, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings (visibility: PUBLIC, simpleName: SynchronizedRegionsAreNotSiblings, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static SynchronizedRegionsAreNotSiblings INSTANCE = new SynchronizedRegionsAreNotSiblings(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static SynchronizedRegionsAreNotSiblings.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final PParameter parameter_v1 = new PParameter("v1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final PParameter parameter_v2 = new PParameter("v2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s, parameter_v1, parameter_v2); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s","v1","v2"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v1 = body.getOrCreateVariableByName("v1"); + PVariable var_v2 = body.getOrCreateVariableByName("v2"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + PVariable var_r1 = body.getOrCreateVariableByName("r1"); + PVariable var_r2 = body.getOrCreateVariableByName("r2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v1, parameter_v1), + new ExportedParameter(body, var_v2, parameter_v2) + )); + // find transition(_, v1, s) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v1, var_s), Transition.instance().getInternalQueryRepresentation()); + // find transition(_, v2, s) + new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_v2, var_s), Transition.instance().getInternalQueryRepresentation()); + // CompositeElement.regions.vertices(r1, v1) + new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_v1); + // CompositeElement.regions.vertices(r2, v2) + new TypeConstraint(body, Tuples.flatTupleOf(var_r2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r2, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_3_ = body.getOrCreateVariableByName(".virtual{3}"); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_, var__virtual_3_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_3_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_3_, var_v2); + // r1 != r2 + new Inequality(body, var_r1, var_r2); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_s = body.getOrCreateVariableByName("s"); + PVariable var_v1 = body.getOrCreateVariableByName("v1"); + PVariable var_v2 = body.getOrCreateVariableByName("v2"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); + PVariable var_r1 = body.getOrCreateVariableByName("r1"); + PVariable var_r2 = body.getOrCreateVariableByName("r2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s, parameter_s), + new ExportedParameter(body, var_v1, parameter_v1), + new ExportedParameter(body, var_v2, parameter_v2) + )); + // find transition(_, s, v1) + new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var_v1), Transition.instance().getInternalQueryRepresentation()); + // find transition(_, s, v2) + new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_s, var_v2), Transition.instance().getInternalQueryRepresentation()); + // CompositeElement.regions.vertices(r1, v1) + new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_v1); + // CompositeElement.regions.vertices(r2, v2) + new TypeConstraint(body, Tuples.flatTupleOf(var_r2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); + PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_r2, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); + PVariable var__virtual_3_ = body.getOrCreateVariableByName(".virtual{3}"); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_, var__virtual_3_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_3_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_3_, var_v2); + // r1 != r2 + new Inequality(body, var_r1, var_r2); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java new file mode 100644 index 00000000..185f348e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java @@ -0,0 +1,808 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern transition(t : Transition, src : Vertex, trg : Vertex) {
+ *         	Transition.source(t, src);
+ *         	Transition.target(t, trg);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class Transition extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition fT; + + private Vertex fSrc; + + private Vertex fTrg; + + private static List parameterNames = makeImmutableList("t", "src", "trg"); + + private Match(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + this.fT = pT; + this.fSrc = pSrc; + this.fTrg = pTrg; + } + + @Override + public Object get(final String parameterName) { + if ("t".equals(parameterName)) return this.fT; + if ("src".equals(parameterName)) return this.fSrc; + if ("trg".equals(parameterName)) return this.fTrg; + return null; + } + + public ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition getT() { + return this.fT; + } + + public Vertex getSrc() { + return this.fSrc; + } + + public Vertex getTrg() { + return this.fTrg; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("t".equals(parameterName) ) { + this.fT = (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) newValue; + return true; + } + if ("src".equals(parameterName) ) { + this.fSrc = (Vertex) newValue; + return true; + } + if ("trg".equals(parameterName) ) { + this.fTrg = (Vertex) newValue; + return true; + } + return false; + } + + public void setT(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fT = pT; + } + + public void setSrc(final Vertex pSrc) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fSrc = pSrc; + } + + public void setTrg(final Vertex pTrg) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fTrg = pTrg; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition"; + } + + @Override + public List parameterNames() { + return Transition.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fT, fSrc, fTrg}; + } + + @Override + public Transition.Match toImmutable() { + return isMutable() ? newMatch(fT, fSrc, fTrg) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"t\"=" + prettyPrintValue(fT) + ", "); + result.append("\"src\"=" + prettyPrintValue(fSrc) + ", "); + result.append("\"trg\"=" + prettyPrintValue(fTrg)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fT, fSrc, fTrg); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof Transition.Match)) { + Transition.Match other = (Transition.Match) obj; + return Objects.equals(fT, other.fT) && Objects.equals(fSrc, other.fSrc) && Objects.equals(fTrg, other.fTrg); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public Transition specification() { + return Transition.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static Transition.Match newEmptyMatch() { + return new Mutable(null, null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static Transition.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return new Mutable(pT, pSrc, pTrg); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return the (partial) match object. + * + */ + public static Transition.Match newMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return new Immutable(pT, pSrc, pTrg); + } + + private static final class Mutable extends Transition.Match { + Mutable(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + super(pT, pSrc, pTrg); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends Transition.Match { + Immutable(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + super(pT, pSrc, pTrg); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern transition(t : Transition, src : Vertex, trg : Vertex) {
+   * 	Transition.source(t, src);
+   * 	Transition.target(t, trg);
+   * }
+   * 
+ * + * @see Match + * @see Transition + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static Transition.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static Transition.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_T = 0; + + private final static int POSITION_SRC = 1; + + private final static int POSITION_TRG = 2; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Transition.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return rawStreamAllMatches(new Object[]{pT, pSrc, pTrg}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return rawStreamAllMatches(new Object[]{pT, pSrc, pTrg}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return rawGetOneArbitraryMatch(new Object[]{pT, pSrc, pTrg}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return rawHasMatch(new Object[]{pT, pSrc, pTrg}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return rawCountMatches(new Object[]{pT, pSrc, pTrg}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pT, pSrc, pTrg}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pT the fixed value of pattern parameter t, or null if not bound. + * @param pSrc the fixed value of pattern parameter src, or null if not bound. + * @param pTrg the fixed value of pattern parameter trg, or null if not bound. + * @return the (partial) match object. + * + */ + public Transition.Match newMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { + return Transition.Match.newMatch(pT, pSrc, pTrg); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOft(final Object[] parameters) { + return rawStreamAllValues(POSITION_T, parameters).map(ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft() { + return rawStreamAllValuesOft(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final Transition.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for t. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOft(final Vertex pSrc, final Vertex pTrg) { + return rawStreamAllValuesOft(new Object[]{null, pSrc, pTrg}); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final Transition.Match partialMatch) { + return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for t. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOft(final Vertex pSrc, final Vertex pTrg) { + return rawStreamAllValuesOft(new Object[]{null, pSrc, pTrg}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for src. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfsrc(final Object[] parameters) { + return rawStreamAllValues(POSITION_SRC, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for src. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfsrc() { + return rawStreamAllValuesOfsrc(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for src. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfsrc() { + return rawStreamAllValuesOfsrc(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for src. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfsrc(final Transition.Match partialMatch) { + return rawStreamAllValuesOfsrc(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for src. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfsrc(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pTrg) { + return rawStreamAllValuesOfsrc(new Object[]{pT, null, pTrg}); + } + + /** + * Retrieve the set of values that occur in matches for src. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfsrc(final Transition.Match partialMatch) { + return rawStreamAllValuesOfsrc(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for src. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfsrc(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pTrg) { + return rawStreamAllValuesOfsrc(new Object[]{pT, null, pTrg}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for trg. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOftrg(final Object[] parameters) { + return rawStreamAllValues(POSITION_TRG, parameters).map(Vertex.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for trg. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOftrg() { + return rawStreamAllValuesOftrg(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for trg. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOftrg() { + return rawStreamAllValuesOftrg(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for trg. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOftrg(final Transition.Match partialMatch) { + return rawStreamAllValuesOftrg(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for trg. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOftrg(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc) { + return rawStreamAllValuesOftrg(new Object[]{pT, pSrc, null}); + } + + /** + * Retrieve the set of values that occur in matches for trg. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOftrg(final Transition.Match partialMatch) { + return rawStreamAllValuesOftrg(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for trg. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOftrg(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc) { + return rawStreamAllValuesOftrg(new Object[]{pT, pSrc, null}).collect(Collectors.toSet()); + } + + @Override + protected Transition.Match tupleToMatch(final Tuple t) { + try { + return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) t.get(POSITION_T), (Vertex) t.get(POSITION_SRC), (Vertex) t.get(POSITION_TRG)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected Transition.Match arrayToMatch(final Object[] match) { + try { + return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) match[POSITION_T], (Vertex) match[POSITION_SRC], (Vertex) match[POSITION_TRG]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected Transition.Match arrayToMatchMutable(final Object[] match) { + try { + return Transition.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) match[POSITION_T], (Vertex) match[POSITION_SRC], (Vertex) match[POSITION_TRG]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return Transition.instance(); + } + } + + private Transition() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static Transition instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected Transition.Matcher instantiate(final ViatraQueryEngine engine) { + return Transition.Matcher.on(engine); + } + + @Override + public Transition.Matcher instantiate() { + return Transition.Matcher.create(); + } + + @Override + public Transition.Match newEmptyMatch() { + return Transition.Match.newEmptyMatch(); + } + + @Override + public Transition.Match newMatch(final Object... parameters) { + return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition (visibility: PUBLIC, simpleName: Transition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition (visibility: PUBLIC, simpleName: Transition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static Transition INSTANCE = new Transition(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static Transition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); + + private final PParameter parameter_src = new PParameter("src", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final PParameter parameter_trg = new PParameter("trg", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_t, parameter_src, parameter_trg); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("t","src","trg"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_t = body.getOrCreateVariableByName("t"); + PVariable var_src = body.getOrCreateVariableByName("src"); + PVariable var_trg = body.getOrCreateVariableByName("trg"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_src), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_trg), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_t, parameter_t), + new ExportedParameter(body, var_src, parameter_src), + new ExportedParameter(body, var_trg, parameter_trg) + )); + // Transition.source(t, src) + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_0_, var_src); + // Transition.target(t, trg) + new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_t, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); + new Equality(body, var__virtual_1_, var_trg); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java new file mode 100644 index 00000000..4595f6bc --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java @@ -0,0 +1,714 @@ +/** + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         Simplifying model generation
+ *          
+ *         {@literal @}Constraint(severity="error", message="error", key = {s1,s2})
+ *         pattern twoSynch(s1 : Synchronization, s2 : Synchronization) {
+ *         	Synchronization(s1);
+ *         	Synchronization(s2);
+ *         	s1 != s2;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class TwoSynch extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Synchronization fS1; + + private Synchronization fS2; + + private static List parameterNames = makeImmutableList("s1", "s2"); + + private Match(final Synchronization pS1, final Synchronization pS2) { + this.fS1 = pS1; + this.fS2 = pS2; + } + + @Override + public Object get(final String parameterName) { + if ("s1".equals(parameterName)) return this.fS1; + if ("s2".equals(parameterName)) return this.fS2; + return null; + } + + public Synchronization getS1() { + return this.fS1; + } + + public Synchronization getS2() { + return this.fS2; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("s1".equals(parameterName) ) { + this.fS1 = (Synchronization) newValue; + return true; + } + if ("s2".equals(parameterName) ) { + this.fS2 = (Synchronization) newValue; + return true; + } + return false; + } + + public void setS1(final Synchronization pS1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS1 = pS1; + } + + public void setS2(final Synchronization pS2) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fS2 = pS2; + } + + @Override + public String patternName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch"; + } + + @Override + public List parameterNames() { + return TwoSynch.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fS1, fS2}; + } + + @Override + public TwoSynch.Match toImmutable() { + return isMutable() ? newMatch(fS1, fS2) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"s1\"=" + prettyPrintValue(fS1) + ", "); + result.append("\"s2\"=" + prettyPrintValue(fS2)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fS1, fS2); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof TwoSynch.Match)) { + TwoSynch.Match other = (TwoSynch.Match) obj; + return Objects.equals(fS1, other.fS1) && Objects.equals(fS2, other.fS2); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public TwoSynch specification() { + return TwoSynch.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static TwoSynch.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static TwoSynch.Match newMutableMatch(final Synchronization pS1, final Synchronization pS2) { + return new Mutable(pS1, pS2); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return the (partial) match object. + * + */ + public static TwoSynch.Match newMatch(final Synchronization pS1, final Synchronization pS2) { + return new Immutable(pS1, pS2); + } + + private static final class Mutable extends TwoSynch.Match { + Mutable(final Synchronization pS1, final Synchronization pS2) { + super(pS1, pS2); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends TwoSynch.Match { + Immutable(final Synchronization pS1, final Synchronization pS2) { + super(pS1, pS2); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * Simplifying model generation
+   *  
+   * {@literal @}Constraint(severity="error", message="error", key = {s1,s2})
+   * pattern twoSynch(s1 : Synchronization, s2 : Synchronization) {
+   * 	Synchronization(s1);
+   * 	Synchronization(s2);
+   * 	s1 != s2;
+   * }
+   * 
+ * + * @see Match + * @see TwoSynch + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static TwoSynch.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static TwoSynch.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_S1 = 0; + + private final static int POSITION_S2 = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(TwoSynch.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Synchronization pS1, final Synchronization pS2) { + return rawStreamAllMatches(new Object[]{pS1, pS2}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Synchronization pS1, final Synchronization pS2) { + return rawStreamAllMatches(new Object[]{pS1, pS2}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Synchronization pS1, final Synchronization pS2) { + return rawGetOneArbitraryMatch(new Object[]{pS1, pS2}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Synchronization pS1, final Synchronization pS2) { + return rawHasMatch(new Object[]{pS1, pS2}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Synchronization pS1, final Synchronization pS2) { + return rawCountMatches(new Object[]{pS1, pS2}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Synchronization pS1, final Synchronization pS2, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pS1, pS2}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pS1 the fixed value of pattern parameter s1, or null if not bound. + * @param pS2 the fixed value of pattern parameter s2, or null if not bound. + * @return the (partial) match object. + * + */ + public TwoSynch.Match newMatch(final Synchronization pS1, final Synchronization pS2) { + return TwoSynch.Match.newMatch(pS1, pS2); + } + + /** + * Retrieve the set of values that occur in matches for s1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs1(final Object[] parameters) { + return rawStreamAllValues(POSITION_S1, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs1() { + return rawStreamAllValuesOfs1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs1() { + return rawStreamAllValuesOfs1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for s1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs1(final TwoSynch.Match partialMatch) { + return rawStreamAllValuesOfs1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for s1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs1(final Synchronization pS2) { + return rawStreamAllValuesOfs1(new Object[]{null, pS2}); + } + + /** + * Retrieve the set of values that occur in matches for s1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs1(final TwoSynch.Match partialMatch) { + return rawStreamAllValuesOfs1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs1(final Synchronization pS2) { + return rawStreamAllValuesOfs1(new Object[]{null, pS2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s2. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfs2(final Object[] parameters) { + return rawStreamAllValues(POSITION_S2, parameters).map(Synchronization.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for s2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs2() { + return rawStreamAllValuesOfs2(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs2() { + return rawStreamAllValuesOfs2(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for s2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs2(final TwoSynch.Match partialMatch) { + return rawStreamAllValuesOfs2(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for s2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfs2(final Synchronization pS1) { + return rawStreamAllValuesOfs2(new Object[]{pS1, null}); + } + + /** + * Retrieve the set of values that occur in matches for s2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs2(final TwoSynch.Match partialMatch) { + return rawStreamAllValuesOfs2(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for s2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfs2(final Synchronization pS1) { + return rawStreamAllValuesOfs2(new Object[]{pS1, null}).collect(Collectors.toSet()); + } + + @Override + protected TwoSynch.Match tupleToMatch(final Tuple t) { + try { + return TwoSynch.Match.newMatch((Synchronization) t.get(POSITION_S1), (Synchronization) t.get(POSITION_S2)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected TwoSynch.Match arrayToMatch(final Object[] match) { + try { + return TwoSynch.Match.newMatch((Synchronization) match[POSITION_S1], (Synchronization) match[POSITION_S2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected TwoSynch.Match arrayToMatchMutable(final Object[] match) { + try { + return TwoSynch.Match.newMutableMatch((Synchronization) match[POSITION_S1], (Synchronization) match[POSITION_S2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return TwoSynch.instance(); + } + } + + private TwoSynch() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static TwoSynch instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected TwoSynch.Matcher instantiate(final ViatraQueryEngine engine) { + return TwoSynch.Matcher.on(engine); + } + + @Override + public TwoSynch.Matcher instantiate() { + return TwoSynch.Matcher.create(); + } + + @Override + public TwoSynch.Match newEmptyMatch() { + return TwoSynch.Match.newEmptyMatch(); + } + + @Override + public TwoSynch.Match newMatch(final Object... parameters) { + return TwoSynch.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch (visibility: PUBLIC, simpleName: TwoSynch, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch (visibility: PUBLIC, simpleName: TwoSynch, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static TwoSynch INSTANCE = new TwoSynch(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static TwoSynch.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_s1 = new PParameter("s1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final PParameter parameter_s2 = new PParameter("s2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_s1, parameter_s2); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("s1","s2"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_s1 = body.getOrCreateVariableByName("s1"); + PVariable var_s2 = body.getOrCreateVariableByName("s2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_s1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_s2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_s1, parameter_s1), + new ExportedParameter(body, var_s2, parameter_s2) + )); + // Synchronization(s1) + new TypeConstraint(body, Tuples.flatTupleOf(var_s1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + // Synchronization(s2) + new TypeConstraint(body, Tuples.flatTupleOf(var_s2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); + // s1 != s2 + new Inequality(body, var_s1, var_s2); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("s1"), + new ParameterReference("s2") + })); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql deleted file mode 100644 index 9af35b50..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/Ecore.vql +++ /dev/null @@ -1,29 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries - -import epackage "http://www.eclipse.org/emf/2002/Ecore" - -pattern directSupertype(a: EClass, b:EClass) { - EClass.eSuperTypes(a,b); -} - -@Constraint(key={a}, severity="error", message="error") -pattern loopInInheritence(a: EClass) { - find directSupertype+(a,a); -} - -pattern opposite(a:EReference, b: EReference) { - EReference.eOpposite(a,b); -} -@Constraint(key={a}, severity="error", message="error") -pattern oppositeDifferentClass(a:EReference) { - EReference.eOpposite(a,b); - EReference.eContainingClass(a,aContaining); - EReference.eType(b,bTarget); - aContaining != bTarget; -} - -@Constraint(key={a}, severity="error", message="error") -pattern nonSymmetricOpposite(a:EReference, b:EReference) { - find opposite(a,b); - neg find opposite(b,a); -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java index 1fed3a2d..b2e5af29 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/Function.java @@ -53,7 +53,7 @@ public interface Function extends FunctionalElement { * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunction_Type() * @model required="true" transient="true" changeable="false" volatile="true" derived="true" - * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.xyz.type'" + * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type'" * @generated */ FunctionType getType(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java index c3ed76d6..acfffbc0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/FunctionalElement.java @@ -63,7 +63,7 @@ public interface FunctionalElement extends EObject { * @see #setModel(FunctionalArchitectureModel) * @see ca.mcgill.ecse.dslreasoner.standalone.test.fam.famPackage#getFunctionalElement_Model() * @model required="true" transient="true" volatile="true" derived="true" - * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.xyz.model'" + * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model'" * @generated */ FunctionalArchitectureModel getModel(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java index 74efeeeb..e928e04e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/impl/famPackageImpl.java @@ -561,13 +561,13 @@ public class famPackageImpl extends EPackageImpl implements famPackage { (getFunctionalElement_Model(), source, new String[] { - "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.xyz.model" + "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model" }); addAnnotation (getFunction_Type(), source, new String[] { - "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.xyz.type" + "patternFQN", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type" }); } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql deleted file mode 100644 index 02d34dcd..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql +++ /dev/null @@ -1,103 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries - -import "FamMetamodel" - -@Constraint(message="terminatorAndInformation", severity="error", key={T}) -pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { - FunctionalOutput.outgoingLinks(Out,I); - FunctionalOutput.terminator(Out,T); -} or { - InformationLink.to(I,In); - FunctionalInput.terminator(In,T); -} - -@QueryBasedFeature -pattern type(This : Function, Target : FunctionType) = { - find rootElements(_Model, This); - Target == FunctionType::Root; -} or { - neg find parent(_Child, This); - neg find rootElements(_Model, This); - Target == FunctionType::Leaf; -} or { - find parent(This, _Par); - find parent(_Child, This); - Target == FunctionType::Intermediate; -} - -pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { - FunctionalArchitectureModel.rootElements(Model, Root); -} - -pattern parent(Func : Function, Par : Function) = { - Function.parent(Func, Par); -} - -@QueryBasedFeature -pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { - FunctionalElement(This); - FunctionalArchitectureModel(Target); -} - -/* -@Constraint(message="noRoot", severity="error", key={fam}) -pattern noRoot(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasRoot(_); -} -@Constraint(message="noIntermediate", severity="error", key={fam}) -pattern noInt(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasInt(_); -} -@Constraint(message="noLeaf", severity="error", key={fam}) -pattern noLeaf(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasLeaf(_); -} -*/ - -/* -@QueryBasedFeature -pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { - find parent+(This, Parent); - find rootElements(Target, Parent); -} or { - find rootElements(Target, This); -} - -pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { - FunctionalInterface.data(FI, FD); -} - -@QueryBasedFeature -pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.outputs(This, Output); - InformationLink.from(Target, Output); -} - -@QueryBasedFeature -pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.inputs(This, Input); - InformationLink.to(Target, Input); -} - -@QueryBasedFeature -pattern connects(This : FunctionalElement, Target : FunctionalElement) = { - FunctionalElement.outgoingLinks(This,Link); - FunctionalElement.incomingLinks(Target,Link); -}*/ - -/*pattern frequency(a: Function, b : EInt) { - Function.minimumFrequency(a,b); -}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql deleted file mode 100644 index 269a4242..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/queries/FileSystem.vql +++ /dev/null @@ -1,24 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries - -import epackage "FileSystemMetamodel" - -pattern patternContent(o1: FSObject, o2: FSObject) { - Dir.contents(o1,o2); -} - -@QueryBasedFeature -pattern live(this: FileSystem, l: FSObject) { - FileSystem.root(this,l); -} or { - FileSystem.root(this,root); - find patternContent+(root,l); -} - -@Constraint(key={child}, severity="error", message="error") -pattern contentInNotLive(parent : Dir, child: FSObject) { - Dir.contents(parent,child); - neg find live(_,parent); -} or { - Dir.contents(parent,child); - neg find live(_,child); -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql deleted file mode 100644 index 2e498670..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql +++ /dev/null @@ -1,270 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries - -import epackage "YakinduMetamodel" - -///////// -// Entry -///////// - -pattern entryInRegion_M0(r1 : Region, e1 : Entry) { - Region.vertices(r1, e1); -} -pattern entryInRegion_M1(r1 : Region, e1) { - Region.vertices(r1, e1); -} -pattern entryInRegion_M2(r1 : Region, e1: Entry) { - // For positive constraint - Region(r1);Entry(e1); -} - - -//@Constraint(severity="error", message="error", key = {r1}) -pattern noEntryInRegion_M0(r1 : Region) { - neg find entryInRegion_M0(r1, _); -} -pattern noEntryInRegion_M1(r1 : Region) { - neg find entryInRegion_M1(r1, _); -} -pattern noEntryInRegion_M2(r1 : Region) { - neg find entryInRegion_M2(r1, _); -} -pattern noEntryInRegion_M3(r1 : Region) { - find entryInRegion_M0(r1, _); -} -pattern noEntryInRegion_M4(r1 : Region) { - find entryInRegion_M1(r1, _); -} -pattern noEntryInRegion_M5(r1 : Region) { - find entryInRegion_M2(r1, _); -} - -//@Constraint(severity="error", message="error", key = {r}) -pattern multipleEntryInRegion_M0(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M1(r : Region) { - find entryInRegion_M1(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M2(r : Region) { - find entryInRegion_M2(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M3(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M1(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M4(r : Region) { - find entryInRegion_M2(r, e1); - find entryInRegion_M2(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M5(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M0(r, e2); -} - - -pattern transition_M0(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Transition.target(t, trg); -} -pattern transition_M1(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Vertex(trg); -} -pattern transition_M2(t : Transition, src : Vertex, trg : Vertex) { - Vertex(src); - Transition.target(t, trg); -} -pattern transition_M3(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t_x, src); - Transition.target(t, trg); -} -pattern transition_M4(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Transition.target(t_x, trg); -} - -//@Constraint(severity="error", message="error", key = {e}) -pattern incomingToEntry_M0(t : Transition, e : Entry) { - find transition_M0(t, _, e); -} -pattern incomingToEntry_1(t : Transition, e) { - find transition_M0(t, _, e); -} -pattern incomingToEntry_2(t : Transition, e : Entry) { - find transition_M1(t, _, e); -} -pattern incomingToEntry_3(t : Transition, e : Entry) { - find transition_M2(t, _, e); -} -pattern incomingToEntry_4(t : Transition, e : Entry) { - find transition_M3(t, _, e); -} -pattern incomingToEntry_5(t : Transition, e : Entry) { - find transition_M4(t, _, e); -} - -pattern noOutgoingTransitionFromEntry_M0(e : Entry) { - neg find transition_M0(_, e, _); -} - -pattern noOutgoingTransitionFromEntry_M1(e) { - Vertex(e); - neg find transition_M0(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M2(e : Entry) { - neg find transition_M1(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M3(e : Entry) { - neg find transition_M2(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M4(e : Entry) { - neg find transition_M3(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M5(e : Entry) { - neg find transition_M4(_, e, _); -} - - -//@Constraint(severity="error", message="error", key = {e}) -pattern multipleTransitionFromEntry_M0(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M1(e, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M2(e : Entry, t1 : Transition, t2: Transition) { - Transition(t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M3(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Transition(t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M4(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); -} - -///////// -// Exit -///////// - -//@Constraint(severity="error", message="error", key = {e}) -pattern outgoingFromExit_M0(t : Transition, e : Exit) { - Exit.outgoingTransitions(e,t); -} -pattern outgoingFromExit_M1(t : Transition, e) { - Vertex.outgoingTransitions(e,t); -} -pattern outgoingFromExit_M2(t : Transition, e : Exit) { - Transition(t); - Exit(e); -} - -///////// -// Final -///////// - -//@Constraint(severity="error", message="error", key = {f}) -pattern outgoingFromFinal_M0(t : Transition, f : FinalState) { - FinalState.outgoingTransitions(f,t); -} -pattern outgoingFromFinal_M1(t : Transition, f) { - Vertex.outgoingTransitions(f,t); -} -pattern outgoingFromFinal_M2(t : Transition, f : FinalState) { - Transition(t); - FinalState(f); -} - -///////// -// State vs Region -///////// - -//@Constraint(severity="error", message="error", key = {region}) -pattern noStateInRegion_M0(region: Region) { - neg find StateInRegion_M0(region,_); -} -pattern noStateInRegion_M1(region: Region) { - neg find StateInRegion_M1(region,_); -} -pattern noStateInRegion_M2(region: Region) { - neg find StateInRegion_M2(region,_); -} -pattern noStateInRegion_M3(region: Region) { - find StateInRegion_M0(region,_); -} - -pattern StateInRegion_M0(region: Region, state: State) { - Region.vertices(region,state); -} -pattern StateInRegion_M1(region: Region, state) { - Region.vertices(region,state); -} -pattern StateInRegion_M2(region: Region, state:State) { - Region(region);State(state); -} - -///////// -// Choice -///////// - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoOutgoing_M0(c : Choice) { - neg find transition_M0(_, c, _); -} -pattern choiceHasNoOutgoing_M1(c:Vertex) { - neg find transition_M0(_, c, _); -} -pattern choiceHasNoOutgoing_M2(c : Choice) { - neg find transition_M1(_, c, _); -} -pattern choiceHasNoOutgoing_M3(c : Choice) { - neg find transition_M2(_, c, _); -} -pattern choiceHasNoOutgoing_M4(c : Choice) { - neg find transition_M3(_, c, _); -} -pattern choiceHasNoOutgoing_M5(c : Choice) { - neg find transition_M4(_, c, _); -} -pattern choiceHasNoOutgoing_M6(c : Choice) { - find transition_M0(_, c, _); -} - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoIncoming_M0(c: Choice) { - neg find transition_M0(_, _, c); -} -pattern choiceHasNoIncoming_M1(c:Vertex) { - neg find transition_M0(_, _, c); -} -pattern choiceHasNoIncoming_M2(c: Choice) { - neg find transition_M1(_, _, c); -} -pattern choiceHasNoIncoming_M3(c: Choice) { - neg find transition_M2(_, _, c); -} -pattern choiceHasNoIncoming_M4(c: Choice) { - neg find transition_M3(_, _, c); -} -pattern choiceHasNoIncoming_M5(c: Choice) { - neg find transition_M4(_, _, c); -} -pattern choiceHasNoIncoming_M6(c: Choice) { - find transition_M0(_, _, c); -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql deleted file mode 100644 index 597b1691..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql +++ /dev/null @@ -1,227 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries - -import epackage "YakinduMetamodel" - -///////// -// Entry -///////// - -pattern entryInRegion(r1 : Region, e1 : Entry) { - Region.vertices(r1, e1); -} - -@Constraint(severity="error", message="error", key = {r1}) -pattern noEntryInRegion(r1 : Region) { - neg find entryInRegion(r1, _); -} - -@Constraint(severity="error", message="error", key = {r}) -pattern multipleEntryInRegion(r : Region) { - find entryInRegion(r, e1); - find entryInRegion(r, e2); - e1 != e2; -} - -pattern transition(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Transition.target(t, trg); -} - -@Constraint(severity="error", message="error", key = {e}) -pattern incomingToEntry(t : Transition, e : Entry) { - find transition(t, _, e); -} - -@Constraint(severity="error", message="error", key = {e}) -pattern noOutgoingTransitionFromEntry(e : Entry) { - neg find transition(_, e, _); -} - -@Constraint(severity="error", message="error", key = {e}) -pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} - -///////// -// Exit -///////// - -@Constraint(severity="error", message="error", key = {e}) -pattern outgoingFromExit(t : Transition, e : Exit) { - Exit.outgoingTransitions(e,t); -} - -///////// -// Final -///////// - -@Constraint(severity="error", message="error", key = {f}) -pattern outgoingFromFinal(t : Transition, f : FinalState) { - FinalState.outgoingTransitions(f,t); -} - -///////// -// State vs Region -///////// - -@Constraint(severity="error", message="error", key = {region}) -pattern noStateInRegion(region: Region) { - neg find StateInRegion(region,_); -} -pattern StateInRegion(region: Region, state: State) { - Region.vertices(region,state); -} - -///////// -// Choice -///////// - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoOutgoing(c : Choice) { - neg find transition(_, c, _); -} - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoIncoming(c: Choice) { - neg find transition(_, _, c); -} - -///////// -// Synchronization -///////// - -@Constraint(severity="error", message="error", key = {s}) -pattern synchHasNoOutgoing(s : Synchronization) { - neg find transition(_, s, _); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern synchHasNoIncoming(s : Synchronization) { - neg find transition(_, _, s); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) { - find transition(t1, v1, s); - find transition(t2, v2, s); - t1!=t2; - Region.vertices(r, v1); - Region.vertices(r, v2); -} or { - find transition(t1, s, v1); - find transition(t2, s, v2); - t1!=t2; - Region.vertices(r, v1); - Region.vertices(r, v2); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern notSynchronizingStates(s : Synchronization) { - neg find hasMultipleOutgoingTrainsition(s); - neg find hasMultipleIncomingTrainsition(s); -} - -pattern hasMultipleOutgoingTrainsition(v : Synchronization) { - find transition(_, v, trg1); - find transition(_, v, trg2); - trg1 != trg2; -} - -pattern hasMultipleIncomingTrainsition(v : Synchronization) { - find transition(_, src1, v); - find transition(_, src2, v); - src1 != src2; -} - -@Constraint(severity="error", message="error", key = {s}) -pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) { - find transition(_, v1, s); - find transition(_, v2, s); - CompositeElement.regions.vertices(r1, v1); - CompositeElement.regions.vertices(r2, v2); - r1 != r2; -} or { - find transition(_, s, v1); - find transition(_, s, v2); - CompositeElement.regions.vertices(r1, v1); - CompositeElement.regions.vertices(r2, v2); - r1 != r2; -} - -/////////////////////////////// -// Extra -// -//@Constraint(severity="error", message="error", key = {s}) -//pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) { -// find transition(_, v, s); -// neg find child(_,v); -//} or { -// find transition(_, s, v); -// neg find child(_,v); -//} - -pattern child(parent: CompositeElement, child: Vertex) { - CompositeElement.regions.vertices(parent, child); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) { - find transition(_, v, s); - find child(c,v); - neg find hasMultipleRegions(c); -} or { - find transition(_, s, v); - find child(c,v); - neg find hasMultipleRegions(c); -} - - -pattern hasMultipleRegions(composite: CompositeElement) { - CompositeElement.regions(composite,region1); - CompositeElement.regions(composite,region2); - region1 != region2; -} - -/** - * Simplifying model generation - */ -@Constraint(severity="error", message="error", key = {s}) -pattern synchThree(s: Synchronization) { - Transition.target(t1,s); - Transition.target(t2,s); - Transition.target(t3,s); - t1!=t2; - t2!=t3; - t1!=t3; -} or { - Transition.source(t1,s); - Transition.source(t2,s); - Transition.source(t3,s); - t1!=t2; - t2!=t3; - t1!=t3; -} - -/** - * Simplifying model generation - */ -@Constraint(severity="error", message="error", key = {s1,s2}) -pattern twoSynch(s1 : Synchronization, s2 : Synchronization) { - Synchronization(s1); - Synchronization(s2); - s1 != s2; -} - -/** - * Model generation task: at least one synch - */ -//@Constraint(severity="error", message="error", key = {s}) -//pattern noSynch(s:Statechart) { -// Statechart(s); -// neg find synch(_); -//} -//pattern synch(s:Synchronization) { -// Synchronization(s); -//} \ No newline at end of file -- cgit v1.2.3-54-g00ecf From fcb7e3a8e29d6def26b06decc504767c5864e5ca Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Sun, 17 Feb 2019 15:11:07 -0500 Subject: Commit before merge --- .../.classpath | 1 + .../.gitignore | 3 + .../META-INF/MANIFEST.MF | 3 +- .../build.properties | 3 - .../configs/ecore.vsconfig | 34 + .../configs/fam.vsconfig | 25 + .../configs/fileSystem.vsconfig | 25 + .../configs/yakindu.vsconfig | 25 + .../configurations/ecore.vsconfig | 34 - .../configurations/fam.vsconfig | 25 - .../configurations/fileSystem.vsconfig | 25 - .../configurations/yakindu.vsconfig | 25 - .../functionalPlugin.txt | 145 + .../metamodels/fam.ecore | 12 +- .../outputs/fam/debug/errors.txt | 458 +- .../fam/debug/generated3valued.vql_deactivated | 48584 ++++++------------- .../outputs/fam/debug/generation.logicproblem | 1969 +- .../outputs/fam/debug/init.partialmodel | 396 +- .../outputs/fam/debug/problem.als | 32 +- .../outputs/fam/log.txt | 2 +- .../outputs/fam/models/1.gml | 10018 +--- .../outputs/fam/models/1.png | Bin 159195 -> 68150 bytes .../outputs/fam/models/1.xmi | 19 +- .../outputs/fam/models/2.gml | 7091 +-- .../outputs/fam/models/2.png | Bin 177546 -> 64057 bytes .../outputs/fam/models/2.xmi | 19 +- .../outputs/fam/models/3.gml | 5921 ++- .../outputs/fam/models/3.png | Bin 177661 -> 64831 bytes .../outputs/fam/models/3.xmi | 20 +- .../outputs/fam/models/4.gml | 7403 ++- .../outputs/fam/models/4.png | Bin 189772 -> 80996 bytes .../outputs/fam/models/4.xmi | 17 +- .../outputs/fam/models/5.gml | 7507 ++- .../outputs/fam/models/5.png | Bin 194199 -> 66383 bytes .../outputs/fam/models/5.xmi | 16 +- .../outputs/fam/statistics.csv | 68 +- .../outputs/yakindu/debug/errors.txt | 66 +- .../yakindu/debug/generated3valued.vql_deactivated | 14693 +++--- .../outputs/yakindu/debug/generation.logicproblem | 1456 +- .../outputs/yakindu/debug/init.partialmodel | 49 +- .../outputs/yakindu/log.txt | 2 +- .../outputs/yakindu/models/1.gml | 11023 ++++- .../outputs/yakindu/models/1.png | Bin 33827 -> 127573 bytes .../outputs/yakindu/models/1.xmi | 22 +- .../outputs/yakindu/models/2.gml | 10733 +++- .../outputs/yakindu/models/2.png | Bin 29697 -> 116286 bytes .../outputs/yakindu/models/2.xmi | 21 +- .../outputs/yakindu/statistics.csv | 32 +- .../plugin.xml | 15 +- .../test/ecore/queries/ecorePatterns.vql | 14 +- .../standalone/test/fam/queries/famPatterns.vql | 103 - .../standalone/test/fam/queries/famSPatterns.vql | 13 + .../standalone/test/fam/queries/famXPatterns.vql | 103 + .../test/fam/queries/TerminatorAndInformation.java | 2 +- .../standalone/test/yakindu/queries/.gitignore | 24 + .../standalone/test/TestExecutionICSE.xtend | 22 + .../standalone/test/filesystem/FileSystem.java | 1 - .../test/filesystem/impl/FileSystemImpl.java | 19 +- .../filesystem/impl/filesystemPackageImpl.java | 18 - 59 files changed, 65914 insertions(+), 62442 deletions(-) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/ecore.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fileSystem.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/yakindu.vsconfig delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/TestExecutionICSE.xtend (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath index dbb1533f..5d01c425 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.classpath @@ -1,6 +1,7 @@ + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore index ae3c1726..245e4e4c 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/.gitignore @@ -1 +1,4 @@ /bin/ +/xtend-gen/* +/src-gen/* +/outputs/* \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF index 61135ac9..0b81cb7f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF @@ -25,7 +25,8 @@ Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, org.eclipse.viatra.query.runtime;bundle-version="2.1.0", org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", - org.eclipse.xtext.xbase.lib;bundle-version="2.12.0" + org.eclipse.xtext.xbase.lib;bundle-version="2.12.0", + hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0" Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.standalone.test Bundle-ActivationPolicy: lazy diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties index 876d970c..e765de8d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/build.properties @@ -1,8 +1,5 @@ bin.includes = META-INF/,\ - plugin.xml,\ - plugin.properties -jars.compile.order = . source.. = src/,\ src-gen/,\ queries/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/ecore.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/ecore.vsconfig new file mode 100644 index 00000000..7f9d9caf --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/ecore.vsconfig @@ -0,0 +1,34 @@ +import epackage "http://www.eclipse.org/emf/2002/Ecore" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.EcorePatterns" + +metamodel allSupported { package ecore excluding { + EClassifier.instanceClass,EClassifier.defaultValue,EEnumLiteral.instance,EStructuralFeature.defaultValue, + EJavaClass, EJavaObject, EJavaObject, + EPackage.eFactoryInstance, EFactory, EFactory.ePackage + } +} + +generate { + metamodel = allSupported + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries} + partial-model = { "platform:/resource/Ecore-Plugin/InitialPackage.ecore" } + solver = ViatraSolver + scope = { + #node += 5, + #string += { "A", "B" }, + #int += {0,1,-1} + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 3 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/ecore/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/ecore/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/ecore/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/ecore/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig new file mode 100644 index 00000000..8137ddf7 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig @@ -0,0 +1,25 @@ +import epackage "FamMetamodel" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns" + +generate { + metamodel = { package fam } +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} +// partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} + solver = ViatraSolver + scope = { + #node = 10 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 5 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fileSystem.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fileSystem.vsconfig new file mode 100644 index 00000000..ea95336b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fileSystem.vsconfig @@ -0,0 +1,25 @@ +import epackage "FileSystemMetamodel" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries.FileSystemPatterns" + +generate { + metamodel = { package filesystem } + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries} + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi"} + solver = ViatraSolver + scope = { + # node = 10 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 5 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fileSystem/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fileSystem/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fileSystem/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fileSystem/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/yakindu.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/yakindu.vsconfig new file mode 100644 index 00000000..ff2038e0 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/yakindu.vsconfig @@ -0,0 +1,25 @@ +import epackage "YakinduMetamodel" +import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.YakinduPatterns" + +generate { + metamodel = { package yakindu } + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries } + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi"} + solver = ViatraSolver + scope = { + #node = 10 + } + + config = { + runtime = 10000, + log-level = normal + } + + number = 5 + runs = 1 + + debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug" + log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt" + output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models" + statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv" +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig deleted file mode 100644 index 9360ab61..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/ecore.vsconfig +++ /dev/null @@ -1,34 +0,0 @@ -import epackage "http://www.eclipse.org/emf/2002/Ecore" -import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.EcorePatterns" - -metamodel allSupported { package ecore excluding { - EClassifier.instanceClass,EClassifier.defaultValue,EEnumLiteral.instance,EStructuralFeature.defaultValue, - EJavaClass, EJavaObject, EJavaObject, - EPackage.eFactoryInstance, EFactory, EFactory.ePackage - } -} - -generate { - metamodel = allSupported -// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries} - partial-model = { "platform:/resource/Ecore-Plugin/InitialPackage.ecore" } - solver = ViatraSolver - scope = { - #node += 5, - #string += { "A", "B" }, - #int += {0,1,-1} - } - - config = { - runtime = 10000, - log-level = normal - } - - number = 3 - runs = 1 - - debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" - log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt" - output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models" - statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv" -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig deleted file mode 100644 index d376dce8..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fam.vsconfig +++ /dev/null @@ -1,25 +0,0 @@ -import epackage "FamMetamodel" -import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns" - -generate { - metamodel = { package fam } - constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} - partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} - solver = ViatraSolver - scope = { - #node = 5 - } - - config = { - runtime = 10000, - log-level = normal - } - - number = 2 - runs = 1 - - debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug" - log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt" - output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models" - statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv" -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig deleted file mode 100644 index 0e510a55..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/fileSystem.vsconfig +++ /dev/null @@ -1,25 +0,0 @@ -import epackage "FileSystemMetamodel" -import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries.FileSystemPatterns" - -generate { - metamodel = { package filesystem } - constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries} - partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/filesystemInstance.xmi"} - solver = ViatraSolver - scope = { - #node = 5 - } - - config = { - runtime = 10000, - log-level = normal - } - - number = 2 - runs = 1 - - debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug" - log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt" - output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models" - statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv" -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig deleted file mode 100644 index 423bf80e..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configurations/yakindu.vsconfig +++ /dev/null @@ -1,25 +0,0 @@ -import epackage "YakinduMetamodel" -import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.YakinduPatterns" - -generate { - metamodel = { package yakindu } - constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries } - partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/yakinduInstance.xmi"} - solver = ViatraSolver - scope = { - #node = 6 - } - - config = { - runtime = 10000, - log-level = normal - } - - number = 2 - runs = 1 - - debug = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug" - log = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt" - output = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models" - statistics = "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv" -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt new file mode 100644 index 00000000..ca86fe6b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt @@ -0,0 +1,145 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore index d9c8bfef..05023c15 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore @@ -8,11 +8,7 @@ - -

- - + volatile="true" transient="true" derived="true"/> @@ -24,11 +20,7 @@ - -
- - + changeable="false" volatile="true" transient="true" derived="true"/> (FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) @@ -26,122 +67,108 @@ Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalo hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.builder.Alloy2LogicMapper.transformOutput(Alloy2LogicMapper.java:53) + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.AlloySolver.solve(AlloySolver.java:66) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.xyz.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.xyz.terminatorAndInformation contains errors. - org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) - org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) - org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:56) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) @@ -182,34 +209,6 @@ Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalo hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Unsupported attribute type: EJavaClass of org.eclipse.emf.ecore.impl.EcorePackageImpl@eddc9bb (name: ecore) (nsURI: http://www.eclipse.org/emf/2002/Ecore, nsPrefix: ecore)::EClassifier.instanceClass - hu.bme.mit.inf.dslreasoner.ecore2logic.EAttributeMapper_RelationsOverTypes.TypeOfRange(EAttributeMapper_RelationsOverTypes.java:237) - hu.bme.mit.inf.dslreasoner.ecore2logic.EAttributeMapper_RelationsOverTypes.transformEAttributes(EAttributeMapper_RelationsOverTypes.java:70) - hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.transformEAttributes(Ecore2Logic.java:140) - hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.transformMetamodel(Ecore2Logic.java:83) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:189) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): - hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) - org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) - com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) - com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) - com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) - com.google.common.collect.Iterators.addAll(Iterators.java:366) - com.google.common.collect.Iterables.addAll(Iterables.java:332) - com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) - org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) - hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) - hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) - hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) @@ -234,36 +233,49 @@ Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalo hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) - hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) - hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NullPointerException): - hu.bme.mit.inf.dlsreasoner.alloy.reasoner.builder.Alloy2LogicMapper.transformOutput(Alloy2LogicMapper.java:53) - hu.bme.mit.inf.dlsreasoner.alloy.reasoner.AlloySolver.solve(AlloySolver.java:66) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType @@ -274,36 +286,148 @@ Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalo hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"! Reason: Unknown constant type: class ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.transformPattern(RelationDefinitionIndexer.java:205) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.RelationDefinitionIndexer.generateRelationDefinitions(RelationDefinitionIndexer.java:66) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternGenerator.transformBaseProperties(PatternGenerator.java:423) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns.PatternProvider.generateQueries(PatternProvider.java:59) - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.ModelGenerationMethodProvider.createModelGenerationMethod(ModelGenerationMethodProvider.java:57) - hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner.ViatraReasoner.solve(ViatraReasoner.java:96) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:316) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Unable to translate query "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.oppositeDifferentClass". -Reason: IllegalArgumentException, Inconsistent types: [EStructuralFeature class, EModelElement class, ENamedElement class, EReference class, EObject class, ETypedElement class] - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:166) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Unable to translate query "ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries.oppositeDifferentClass". -Reason: IllegalArgumentException, Inconsistent types: [EStructuralFeature class, EModelElement class, ENamedElement class, EReference class, EObject class, ETypedElement class] - hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:166) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Query ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type contains errors. + org.eclipse.viatra.query.runtime.matchers.util.Preconditions.checkState(Preconditions.java:144) + org.eclipse.viatra.query.patternlanguage.emf.specification.GenericEMFPatternPQuery.getDisjunctBodies(GenericEMFPatternPQuery.java:161) + org.eclipse.viatra.query.runtime.matchers.psystem.rewriters.PDisjunctionRewriter.rewrite(PDisjunctionRewriter.java:26) + hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic.transformQueries(Viatra2Logic.java:111) hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:196) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:132) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:343) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is not translated to logic! + hu.bme.mit.inf.dslreasoner.ecore2logic.EClassMapper_AllElementAsObject.TypeofEClass(EClassMapper_AllElementAsObject.java:63) + hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.TypeofEClass(Ecore2Logic.java:96) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation.transform(InstanceModel2PartialInterpretation.java:99) + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic.transform(InstanceModel2Logic.java:19) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:192) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated index f02c64b0..7899a25f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated @@ -105,22 +105,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -148,23 +148,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -193,20 +193,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -234,21 +234,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -277,20 +277,20 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -319,20 +319,20 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -360,23 +360,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -405,22 +405,22 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -449,24 +449,24 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -536,21 +536,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -610,7 +610,7 @@ private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model(problem,interpretation,source,target); } /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) @@ -619,7 +619,7 @@ private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model(problem,interpretation,source,target); } /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) @@ -1102,27 +1102,44 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []type attribute Function(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} ////////// // 1.3 Relation Definition Indexers ////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -1154,7 +1171,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); var_virtual1 == var_T; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -1186,7 +1203,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -1218,108 +1235,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); var_virtual1 == var_T; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -1333,7 +1250,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); var_virtual0 == var_Root; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -1347,7 +1264,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); find mayEquivalent(problem, interpretation, var_virtual0, var_Root); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -1361,8 +1278,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); var_virtual0 == var_Root; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -1376,7 +1293,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); var_virtual0 == var_Par; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -1390,7 +1307,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); find mayEquivalent(problem, interpretation, var_virtual0, var_Par); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -1404,8 +1321,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); var_virtual0 == var_Par; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -1417,7 +1334,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -1429,7 +1346,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -1472,10 +1389,10 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } ////////// @@ -1492,14 +1409,23 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } ////////// @@ -1509,16 +1435,12 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_term ////////// private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ find interpretation(problem,interpretation); find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -1530,19 +1452,23 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -1553,33 +1479,49 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -1613,151 +1555,135 @@ pattern createObject_FunctionalInput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -1765,84 +1691,84 @@ pattern createObject_Function_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); -} -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); -} -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } ////////// @@ -1894,7 +1820,8 @@ pattern refineRelation_type_attribute_Function( find mustInstanceOfFunctionType_enum(problem,interpretation,to); find mayInRelationtype_attribute_Function(problem,interpretation,from,to); neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); -}import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" @@ -2000,23 +1927,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2044,23 +1971,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2088,21 +2015,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2130,20 +2057,20 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); @@ -2172,21 +2099,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2214,21 +2141,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2256,22 +2183,22 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); @@ -2300,23 +2227,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -2344,24 +2271,24 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); @@ -2432,21 +2359,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -2506,7 +2433,7 @@ private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model(problem,interpretation,source,target); } /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) @@ -2515,7 +2442,7 @@ private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model(problem,interpretation,source,target); } /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) @@ -2998,27 +2925,44 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []type attribute Function(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} ////////// // 1.3 Relation Definition Indexers ////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -3050,7 +2994,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); var_virtual1 == var_T; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -3082,7 +3026,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -3114,108 +3058,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); var_virtual1 == var_T; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -3229,7 +3073,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); var_virtual0 == var_Root; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -3243,7 +3087,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); find mayEquivalent(problem, interpretation, var_virtual0, var_Root); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( problem:LogicProblem, interpretation:PartialInterpretation, var_Model, var_Root) { @@ -3257,8 +3101,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); var_virtual0 == var_Root; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -3272,7 +3116,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); var_virtual0 == var_Par; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -3286,7 +3130,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); find mayEquivalent(problem, interpretation, var_virtual0, var_Par); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( problem:LogicProblem, interpretation:PartialInterpretation, var_Func, var_Par) { @@ -3300,8 +3144,8 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); var_virtual0 == var_Par; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries model +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -3313,7 +3157,7 @@ private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_tes find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -3325,7 +3169,7 @@ private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_model( problem:LogicProblem, interpretation:PartialInterpretation, var_This, var_Target) { @@ -3368,10 +3212,10 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } ////////// @@ -3388,14 +3232,23 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } ////////// @@ -3406,11 +3259,11 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_term private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -3418,11 +3271,11 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -3430,15 +3283,15 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -3449,63 +3302,45 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInterface_class( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -3555,6 +3390,66 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -3585,48 +3480,6 @@ pattern createObject_FAMTerminator_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -3661,83 +3514,83 @@ pattern createObject_FunctionalOutput_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } @@ -3898,22 +3751,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3942,10 +3795,10 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -3953,10 +3806,10 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -3986,20 +3839,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4028,20 +3881,20 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4070,20 +3923,20 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4112,20 +3965,20 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4153,23 +4006,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4197,22 +4050,22 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); @@ -4241,25 +4094,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -4330,9 +4183,9 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -4340,9 +4193,9 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -4399,21 +4252,38 @@ private pattern mayInRelationinterface_reference_FunctionalElement( /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ - private pattern mustInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ - private pattern mayInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ @@ -4895,504 +4765,189 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []type attribute Function(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} ////////// // 1.3 Relation Definition Indexers ////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_I); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -}or{ + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_In); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Root); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Par); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or - - { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or - - { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or - - { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or - - { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or - - { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); - find mustInstanceOfInformationLink_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -} -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -5442,105 +4997,135 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -5548,84 +5133,84 @@ pattern createObject_InformationLink_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } ////////// @@ -5784,23 +5369,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -5828,23 +5413,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -5872,21 +5457,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -5914,21 +5499,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -5956,21 +5541,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -5999,20 +5584,20 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6040,23 +5625,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6084,23 +5669,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6128,25 +5713,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6216,21 +5801,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -6286,21 +5871,38 @@ private pattern mayInRelationinterface_reference_FunctionalElement( /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ - private pattern mustInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ - private pattern mayInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ @@ -6782,346 +6384,43 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []type attribute Function(source,target) - */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_I); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_In); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Root); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Par); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } +////////// +// 1.3 Relation Definition Indexers +////////// + ////////// // 1.4 Containment Indexer ////////// @@ -7158,6 +6457,15 @@ private pattern mustTransitiveContains(source,target) { ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); @@ -7167,6 +6475,15 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries @@ -7180,19 +6497,19 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -7200,7 +6517,7 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -7208,11 +6525,11 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -7223,33 +6540,33 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -7283,33 +6600,45 @@ pattern createObject_FunctionalOutput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -7343,15 +6672,33 @@ pattern createObject_InformationLink_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -7401,118 +6748,88 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInterface_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); } ////////// @@ -7672,22 +6989,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7716,22 +7033,22 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7760,20 +7077,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7802,9 +7119,9 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); @@ -7812,9 +7129,9 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); @@ -7843,21 +7160,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7885,21 +7202,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7928,22 +7245,22 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -7971,23 +7288,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -8015,25 +7332,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -8104,20 +7421,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -8799,39 +8116,39 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -8842,6 +8159,36 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -8872,181 +8219,151 @@ pattern createObject_InformationLink_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -9054,84 +8371,84 @@ pattern createObject_FAMTerminator_class( ////////// // 4.2 Type refinement ////////// +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); -} -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); -} -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } ////////// @@ -9290,23 +8607,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9334,23 +8651,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9378,21 +8695,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9420,21 +8737,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9462,21 +8779,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9504,21 +8821,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9546,22 +8863,22 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); @@ -9590,23 +8907,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9634,25 +8951,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9722,21 +9039,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -10418,39 +9735,39 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -10461,135 +9778,123 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -10639,33 +9944,45 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -10673,84 +9990,84 @@ pattern createObject_FAMTerminator_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// @@ -10909,23 +10226,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -10953,23 +10270,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -10997,21 +10314,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11039,21 +10356,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11081,21 +10398,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11123,21 +10440,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11165,23 +10482,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11209,23 +10526,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11253,25 +10570,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -11341,21 +10658,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -12037,15 +11354,15 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -12053,23 +11370,23 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -12080,79 +11397,15 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -12186,75 +11439,49 @@ pattern createObject_FAMTerminator_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -12288,88 +11515,178 @@ pattern createObject_FunctionalInterface_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); -} -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } ////////// @@ -12528,23 +11845,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12572,22 +11889,22 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -12616,21 +11933,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12658,21 +11975,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12700,21 +12017,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12742,21 +12059,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12784,23 +12101,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12828,23 +12145,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12872,25 +12189,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12960,21 +12277,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -13656,39 +12973,39 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -13699,211 +13016,211 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -13911,84 +13228,84 @@ pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); -} -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); -} -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } ////////// @@ -14147,23 +13464,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14191,23 +13508,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14235,21 +13550,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14277,21 +13592,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14319,21 +13634,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14361,21 +13676,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14403,23 +13718,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14447,23 +13762,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14491,25 +13806,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -14535,69 +13850,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -14649,21 +13901,38 @@ private pattern mayInRelationinterface_reference_FunctionalElement( /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ - private pattern mustInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ - private pattern mayInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ @@ -15145,91 +14414,44 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []type attribute Function(source,target) - */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_I); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_In); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, var_T, var_I) { @@ -15261,228 +14483,69 @@ private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_ find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); var_virtual1 == var_T; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + var_T, var_I) { find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); }or{ find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + var_T, var_I) { find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Root); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Par); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } ////////// @@ -15515,12 +14578,26 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 3. Unfinishedness Indexers ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); @@ -15530,10 +14607,24 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 4. Refinement Indexers @@ -15547,11 +14638,11 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -15559,15 +14650,11 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -15575,104 +14662,82 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -15706,91 +14771,109 @@ pattern createObject_FunctionalInterface_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -15798,84 +14881,84 @@ pattern createObject_InformationLink_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); } ////////// @@ -16034,22 +15117,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); @@ -16078,23 +15161,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16122,20 +15203,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); @@ -16164,21 +15245,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16206,21 +15287,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16248,21 +15329,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16290,23 +15371,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16334,23 +15415,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16378,25 +15459,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -16422,69 +15503,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -17162,23 +16180,15 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -17186,7 +16196,7 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -17194,72 +16204,74 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -17323,63 +16335,61 @@ pattern createObject_FAMTerminator_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -17417,84 +16427,84 @@ pattern createObject_FunctionalInterface_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } ////////// @@ -17653,22 +16663,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); @@ -17697,22 +16707,22 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -17741,21 +16751,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -17783,20 +16793,20 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); @@ -17826,9 +16836,9 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); @@ -17836,9 +16846,9 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); @@ -17867,21 +16877,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -17909,23 +16919,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -17953,23 +16963,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -17997,25 +17007,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18085,20 +17095,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -18781,39 +17791,39 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -18824,154 +17834,6 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalOutput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -19002,6 +17864,124 @@ pattern createObject_InformationLink_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -19032,87 +18012,117 @@ pattern createObject_FunctionalInterface_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } @@ -19272,23 +18282,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19316,23 +18326,23 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19360,21 +18370,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19402,21 +18412,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19444,21 +18454,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19486,21 +18496,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19528,23 +18538,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19572,23 +18582,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19616,25 +18626,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -19705,20 +18715,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(pro find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -20323,6 +19333,103 @@ private pattern mayInRelationtype_attribute_Function( ////////// // 1.3 Relation Definition Indexers ////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} ////////// // 1.4 Containment Indexer @@ -20354,6 +19461,11 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 3. Unfinishedness Indexers @@ -20391,6 +19503,11 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 4. Refinement Indexers @@ -20400,39 +19517,39 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -20443,33 +19560,45 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -20519,6 +19648,96 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -20549,190 +19768,88 @@ pattern createObject_FunctionalOutput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); -} -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } ////////// @@ -20891,23 +20008,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -20935,23 +20052,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -20979,21 +20094,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21021,21 +20136,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21063,21 +20178,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21105,21 +20220,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21147,23 +20262,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21191,23 +20306,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21235,25 +20350,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -21279,69 +20394,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -21393,21 +20445,38 @@ private pattern mayInRelationinterface_reference_FunctionalElement( /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ - private pattern mustInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ - private pattern mayInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model(problem,interpretation,source,target); - } +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ @@ -21889,346 +20958,43 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []type attribute Function(source,target) - */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type(problem,interpretation,source,target); - } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_I); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_In); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Root); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Par); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_model( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } +////////// +// 1.3 Relation Definition Indexers +////////// + ////////// // 1.4 Containment Indexer ////////// @@ -22259,17 +21025,21 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); -} ////////// // 3. Unfinishedness Indexers ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); @@ -22279,15 +21049,19 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_terminatorAndInformation(problem,interpretation,var_T,var_I); -} ////////// // 4. Refinement Indexers @@ -22297,11 +21071,7 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_term private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -22309,11 +21079,11 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -22321,52 +21091,90 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -22416,75 +21224,63 @@ pattern createObject_Function_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -22518,118 +21314,88 @@ pattern createObject_FunctionalOutput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); -} -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } ////////// @@ -22788,23 +21554,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -22832,23 +21598,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -22876,21 +21640,21 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -22918,21 +21682,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -22960,21 +21724,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -23002,21 +21766,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -23044,23 +21808,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -23088,23 +21852,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -23132,25 +21896,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -23176,69 +21940,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -23290,21 +21991,38 @@ private pattern mayInRelationinterface_reference_FunctionalElement( /** * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ - private pattern mustInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model(problem,interpretation,source,target); - } +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} /** - * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ - private pattern mayInRelationmodel_reference_FunctionalElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model(problem,interpretation,source,target); - } +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ @@ -23786,346 +22504,43 @@ private pattern mayInRelationinterface_reference_FunctionalData( /** * Matcher for detecting tuples t where []type attribute Function(source,target) */ - private pattern mustInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []type attribute Function(source,target) - */ - private pattern mayInRelationtype_attribute_Function( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type(problem,interpretation,source,target); - } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz terminatorAndInformation -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_I); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mayInstanceOfInformationLink_class(problem,interpretation,var_I); - find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_In); - find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - find mayEquivalent(problem, interpretation, var_virtual1, var_T); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation( - problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); - find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); - var_virtual0 == var_I; - find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - // T is exported - // I is exported - find mustInstanceOfInformationLink_class(problem,interpretation,var_I); - find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); - var_virtual0 == var_In; - find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); - find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); - find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); - var_virtual1 == var_T; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz type -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - find mayEquivalent(problem, interpretation, var_Target, var_virtual0); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_type( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Root_FunctionType;DefinedElement.name(const_Root_FunctionType,"Root FunctionType"); //LogicProblem.elements(problem,const_Root_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements(problem,interpretation,_var__Model,var_This); - var_virtual0 == const_Leaf_FunctionType;DefinedElement.name(const_Leaf_FunctionType,"Leaf FunctionType"); //LogicProblem.elements(problem,const_Leaf_FunctionType); - var_Target == var_virtual0; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_This); - // type constraint is enforced by construction - // This is exported - // Target is exported - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,var_This,_var__Par); - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent(problem,interpretation,_var__Child,var_This); - var_virtual0 == const_Intermediate_FunctionType;DefinedElement.name(const_Intermediate_FunctionType,"Intermediate FunctionType"); //LogicProblem.elements(problem,const_Intermediate_FunctionType); - var_Target == var_virtual0; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz rootElements -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Root); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_rootElements( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Model, var_Root) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInstanceOfFunction_class(problem,interpretation,var_Root); - // Model is exported - // Root is exported - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); - find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Root; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz parent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mayInstanceOfFunction_class(problem,interpretation,var_Func); - find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_Par); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_parent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_Func, var_Par) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInstanceOfFunction_class(problem,interpretation,var_Par); - // Func is exported - // Par is exported - find mustInstanceOfFunction_class(problem,interpretation,var_Func); - find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); - find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); - var_virtual0 == var_Par; -} -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test xyz model -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( - problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mayInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_model( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - var_This, var_Target) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); - // This is exported - // Target is exported - find mustInstanceOfFunctionalElement_class(problem,interpretation,var_This); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Target); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } +////////// +// 1.3 Relation Definition Indexers +////////// + ////////// // 1.4 Containment Indexer ////////// @@ -24156,17 +22571,21 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem,interpretation,var_T,var_I); -} ////////// // 3. Unfinishedness Indexers ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); @@ -24176,15 +22595,19 @@ pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicPr check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, - var_T, var_I) -{ - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_xyz_terminatorAndInformation(problem,interpretation,var_T,var_I); -} ////////// // 4. Refinement Indexers @@ -24196,29 +22619,17 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find interpretation(problem,interpretation); find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -24230,98 +22641,74 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -24355,63 +22742,61 @@ pattern createObject_FunctionalOutput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -24445,88 +22830,118 @@ pattern createObject_FunctionalInput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); -} -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } ////////// @@ -24686,22 +23101,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24729,23 +23144,21 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24773,20 +23186,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); @@ -24815,21 +23228,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24857,21 +23270,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24899,21 +23312,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24941,23 +23354,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -24985,23 +23398,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -25029,25 +23442,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -25073,69 +23486,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -25813,11 +24163,7 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -25829,19 +24175,19 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -25849,11 +24195,7 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); } pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( @@ -25932,33 +24274,75 @@ pattern createObject_FAMTerminator_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -25992,75 +24376,33 @@ pattern createObject_FunctionalInterface_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_InformationLink_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -26072,79 +24414,79 @@ pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:Partial find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } @@ -26282,1130 +24624,620 @@ private pattern isPrimitive(element: PrimitiveElement) { // 1.1.2 domain-specific Type Indexers ////////// /** - * An element must be an instance of type "EAttribute class". + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); + Type.name(type,"FunctionalElement class"); } /** - * An element may be an instance of type "EAttribute class". + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * An element must be an instance of type "EAnnotation class". + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); + Type.name(type,"FunctionalArchitectureModel class"); } /** - * An element may be an instance of type "EAnnotation class". + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClass class". + * An element must be an instance of type "Function class". */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); + Type.name(type,"Function class"); } /** - * An element may be an instance of type "EClass class". + * An element may be an instance of type "Function class". */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClassifier class". + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); + Type.name(type,"FAMTerminator class"); } /** - * An element may be an instance of type "EClassifier class". + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * An element must be an instance of type "EDataType class". + * An element must be an instance of type "InformationLink class". */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); + Type.name(type,"InformationLink class"); } /** - * An element may be an instance of type "EDataType class". + * An element may be an instance of type "InformationLink class". */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnum class". + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); + Type.name(type,"FunctionalInterface class"); } /** - * An element may be an instance of type "EEnum class". + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnumLiteral class". + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); + Type.name(type,"FunctionalInput class"); } /** - * An element may be an instance of type "EEnumLiteral class". + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * An element must be an instance of type "EModelElement class". + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); + Type.name(type,"FunctionalOutput class"); } /** - * An element may be an instance of type "EModelElement class". + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * An element must be an instance of type "ENamedElement class". + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); + Type.name(type,"FunctionalData class"); } /** - * An element may be an instance of type "ENamedElement class". + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * An element must be an instance of type "EObject class". + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); + Type.name(type,"FunctionType enum"); } /** - * An element may be an instance of type "EObject class". + * An element may be an instance of type "FunctionType enum". */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } /** - * An element must be an instance of type "EOperation class". + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); } /** - * An element may be an instance of type "EOperation class". + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } /** - * An element must be an instance of type "EPackage class". + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); } /** - * An element may be an instance of type "EPackage class". + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * An element must be an instance of type "EParameter class". + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EParameter class". + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EReference class". + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EReference class". + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EStructuralFeature class". + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EStructuralFeature class". + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypedElement class". - */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } - /** - * An element may be an instance of type "ETypedElement class". + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStringToStringMapEntry class". - */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); -} - -/** - * An element may be an instance of type "EStringToStringMapEntry class". - */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EGenericType class". - */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); -} - -/** - * An element may be an instance of type "EGenericType class". - */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypeParameter class". - */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); -} - -/** - * An element may be an instance of type "ETypeParameter class". - */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class UndefinedPart". - */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class UndefinedPart". - */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) - */ -private pattern mustInRelationeAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationeAttributeType_reference_EAttribute( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27414,33 +25246,34 @@ private pattern mayInRelationeAttributeType_reference_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationdetails_reference_EAnnotation( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationdetails_reference_EAnnotation( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27449,34 +25282,38 @@ private pattern mayInRelationdetails_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationeModelElement_reference_EAnnotation( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationeModelElement_reference_EAnnotation( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27485,38 +25322,42 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationcontents_reference_EAnnotation( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationcontents_reference_EAnnotation( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27525,65 +25366,38 @@ private pattern mayInRelationcontents_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) - */ -private pattern mustInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) - */ -private pattern mayInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); -} or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationeSuperTypes_reference_EClass( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationeSuperTypes_reference_EClass( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27592,29 +25406,33 @@ private pattern mayInRelationeSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationeOperations_reference_EClass( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationeOperations_reference_EClass( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27623,11 +25441,11 @@ private pattern mayInRelationeOperations_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -27635,181 +25453,26 @@ private pattern mayInRelationeOperations_reference_EClass( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) - */ -private pattern mustInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) - */ -private pattern mayInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) - */ -private pattern mustInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) - */ -private pattern mayInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) - */ -private pattern mustInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) - */ -private pattern mayInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationeAllOperations_reference_EClass( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationeAllOperations_reference_EClass( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27818,29 +25481,42 @@ private pattern mayInRelationeAllOperations_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27849,29 +25525,33 @@ private pattern mayInRelationeAllStructuralFeatures_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27880,29 +25560,38 @@ private pattern mayInRelationeAllSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationeIDAttribute_reference_EClass( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationeIDAttribute_reference_EClass( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27911,46 +25600,15 @@ private pattern mayInRelationeIDAttribute_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -27958,26 +25616,26 @@ private pattern mayInRelationeStructuralFeatures_reference_EClass( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -27986,34 +25644,38 @@ private pattern mayInRelationeGenericSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -28022,895 +25684,1060 @@ private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) - */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) - */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) - */ -private pattern mustInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) - */ -private pattern mayInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) - */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) - */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) - */ -private pattern mustInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) - */ -private pattern mayInRelationeAnnotations_reference_EModelElement( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EOperation( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EOperation( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EOperation( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EOperation( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) - */ -private pattern mustInRelationeParameters_reference_EOperation( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) - */ -private pattern mayInRelationeParameters_reference_EOperation( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeExceptions_reference_EOperation( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeExceptions_reference_EOperation( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); -} or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) - */ -private pattern mustInRelationeClassifiers_reference_EPackage( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) - */ -private pattern mayInRelationeClassifiers_reference_EPackage( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) - */ -private pattern mustInRelationeSubpackages_reference_EPackage( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) - */ -private pattern mayInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) - */ -private pattern mustInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) - */ -private pattern mayInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) - */ -private pattern mustInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) - */ -private pattern mayInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) - */ -private pattern mustInRelationeReferenceType_reference_EReference( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) - */ -private pattern mayInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); } or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); } -/** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) - */ -private pattern mustInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -/** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) - */ -private pattern mayInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + * An element must be an instance of type "Function class". */ -private pattern mustInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); } + /** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); } + /** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + * An element may be an instance of type "InformationLink class". */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); } + /** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); } + /** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mustInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); } + /** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); } + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationeLowerBound_reference_EGenericType( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationeLowerBound_reference_EGenericType( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -28919,38 +26746,42 @@ private pattern mayInRelationeLowerBound_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -28959,33 +26790,33 @@ private pattern mayInRelationeTypeParameter_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationeClassifier_reference_EGenericType( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationeClassifier_reference_EGenericType( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -28994,33 +26825,38 @@ private pattern mayInRelationeClassifier_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationeBounds_reference_ETypeParameter( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationeBounds_reference_ETypeParameter( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29029,34 +26865,34 @@ private pattern mayInRelationeBounds_reference_ETypeParameter( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationiD_attribute_EAttribute( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationiD_attribute_EAttribute( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29065,33 +26901,38 @@ private pattern mayInRelationiD_attribute_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationsource_attribute_EAnnotation( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationsource_attribute_EAnnotation( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29100,33 +26941,42 @@ private pattern mayInRelationsource_attribute_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationabstract_attribute_EClass( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationabstract_attribute_EClass( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29135,33 +26985,38 @@ private pattern mayInRelationabstract_attribute_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationinterface_attribute_EClass( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationinterface_attribute_EClass( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29170,33 +27025,33 @@ private pattern mayInRelationinterface_attribute_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29205,33 +27060,38 @@ private pattern mayInRelationinstanceClassName_attribute_EClassifier( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29240,33 +27100,42 @@ private pattern mayInRelationinstanceTypeName_attribute_EClassifier( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationserializable_attribute_EDataType( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationserializable_attribute_EDataType( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29275,33 +27144,33 @@ private pattern mayInRelationserializable_attribute_EDataType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29310,68 +27179,38 @@ private pattern mayInRelationvalue_attribute_EEnumLiteral( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationname_attribute_ENamedElement( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationname_attribute_ENamedElement( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29380,33 +27219,42 @@ private pattern mayInRelationname_attribute_ENamedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationnsURI_attribute_EPackage( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationnsURI_attribute_EPackage( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29415,33 +27263,38 @@ private pattern mayInRelationnsURI_attribute_EPackage( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationnsPrefix_attribute_EPackage( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationnsPrefix_attribute_EPackage( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -29450,2286 +27303,2026 @@ private pattern mayInRelationnsPrefix_attribute_EPackage( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); } -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) - */ -private pattern mayInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationderived_attribute_EStructuralFeature( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationderived_attribute_EStructuralFeature( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) - */ -private pattern mustInRelationordered_attribute_ETypedElement( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) - */ -private pattern mayInRelationordered_attribute_ETypedElement( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) - */ -private pattern mustInRelationunique_attribute_ETypedElement( + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) - */ -private pattern mayInRelationunique_attribute_ETypedElement( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + * An element must be an instance of type "Function class". */ -private pattern mustInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); } + /** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + * An element must be an instance of type "InformationLink class". */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); } + /** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + * An element may be an instance of type "InformationLink class". */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); } -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); } -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); } -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_EAttribute_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EAnnotation_class( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EReference_class( +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EObject_class_by_contents_reference_EAnnotation( +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EObject_class( +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EParameter_class( +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EPackage_class_UndefinedPart( +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } -pattern createObject_EEnum_class( +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } -pattern createObject_EEnumLiteral_class( +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern createObject_EGenericType_class( +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } -pattern createObject_EOperation_class( +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } -pattern createObject_EDataType_class( +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } -pattern createObject_EClass_class( +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } ////////// -// 4.2 Type refinement +// 1.3 Relation Definition Indexers ////////// -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} ////////// -// 4.3 Relation refinement +// 1.4 Containment Indexer ////////// -pattern refineRelation_eAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_references_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); } -pattern refineRelation_eSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -pattern refineRelation_eAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eExceptions_reference_EOperation( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eOpposite_reference_EReference( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eReferenceType_reference_EReference( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eKeys_reference_EReference( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eType_reference_ETypedElement( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eRawType_reference_EGenericType( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eTypeParameter_reference_EGenericType( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_eClassifier_reference_EGenericType( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_iD_attribute_EAttribute( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_source_attribute_EAnnotation( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_abstract_attribute_EClass( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_interface_attribute_EClass( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_instanceClassName_attribute_EClassifier( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_instanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_serializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_value_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineRelation_literal_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_name_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_nsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_nsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } -pattern refineRelation_containment_attribute_EReference( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -pattern refineRelation_container_attribute_EReference( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -pattern refineRelation_resolveProxies_attribute_EReference( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_changeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_volatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_transient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_required_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_key_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" @@ -31837,22 +29430,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); @@ -31881,22 +29474,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -32010,8 +29601,8 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); @@ -32020,8 +29611,8 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); @@ -32051,9 +29642,9 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); @@ -32061,9 +29652,9 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); @@ -32095,8 +29686,8 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); @@ -32106,8 +29697,8 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); @@ -32137,23 +29728,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -32181,24 +29772,24 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); @@ -32225,69 +29816,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -32965,11 +30493,11 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -32977,36 +30505,74 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, @@ -33098,121 +30664,75 @@ pattern createObject_FAMTerminator_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -33220,14 +30740,25 @@ pattern createObject_FunctionalOutput_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } @@ -33235,10 +30766,10 @@ pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation: find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } @@ -33248,55 +30779,44 @@ pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:Pa find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); -} -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } @@ -33456,23 +30976,23 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33501,22 +31021,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33545,20 +31063,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33586,21 +31104,21 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33629,20 +31147,20 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33670,21 +31188,21 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33712,23 +31230,23 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33756,23 +31274,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33800,25 +31318,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -33844,69 +31362,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -34507,6 +31962,103 @@ private pattern mayInRelationtype_attribute_Function( ////////// // 1.3 Relation Definition Indexers ////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} ////////// // 1.4 Containment Indexer @@ -34538,6 +32090,11 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 3. Unfinishedness Indexers @@ -34575,6 +32132,11 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 4. Refinement Indexers @@ -34584,11 +32146,11 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -34596,64 +32158,72 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -34687,91 +32257,105 @@ pattern createObject_FunctionalOutput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); - find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); - find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_InformationLink_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); - find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -34805,118 +32389,88 @@ pattern createObject_FunctionalInput_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FAMTerminator_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunction_class(problem,interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunction_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } ////////// @@ -35053,1130 +32607,436 @@ private pattern isPrimitive(element: PrimitiveElement) { // 1.1.2 domain-specific Type Indexers ////////// /** - * An element must be an instance of type "EAttribute class". + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); + Type.name(type,"FunctionalElement class"); } /** - * An element may be an instance of type "EAttribute class". + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * An element must be an instance of type "EAnnotation class". + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); + Type.name(type,"FunctionalArchitectureModel class"); } /** - * An element may be an instance of type "EAnnotation class". + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClass class". + * An element must be an instance of type "Function class". */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); + Type.name(type,"Function class"); } /** - * An element may be an instance of type "EClass class". + * An element may be an instance of type "Function class". */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClassifier class". + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); + Type.name(type,"FAMTerminator class"); } /** - * An element may be an instance of type "EClassifier class". + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * An element must be an instance of type "EDataType class". + * An element must be an instance of type "InformationLink class". */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); + Type.name(type,"InformationLink class"); } /** - * An element may be an instance of type "EDataType class". + * An element may be an instance of type "InformationLink class". */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnum class". + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); + Type.name(type,"FunctionalInterface class"); } /** - * An element may be an instance of type "EEnum class". + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnumLiteral class". + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); + Type.name(type,"FunctionalInput class"); } /** - * An element may be an instance of type "EEnumLiteral class". + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * An element must be an instance of type "EModelElement class". + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); + Type.name(type,"FunctionalOutput class"); } /** - * An element may be an instance of type "EModelElement class". + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * An element must be an instance of type "ENamedElement class". + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); + Type.name(type,"FunctionalData class"); } /** - * An element may be an instance of type "ENamedElement class". + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EObject class". - */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); -} - -/** - * An element may be an instance of type "EObject class". - */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EOperation class". - */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); -} - -/** - * An element may be an instance of type "EOperation class". - */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class". - */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); -} - -/** - * An element may be an instance of type "EPackage class". - */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EParameter class". - */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); -} - -/** - * An element may be an instance of type "EParameter class". - */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EReference class". - */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); -} - -/** - * An element may be an instance of type "EReference class". - */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStructuralFeature class". - */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); -} - -/** - * An element may be an instance of type "EStructuralFeature class". - */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypedElement class". - */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); -} - -/** - * An element may be an instance of type "ETypedElement class". - */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStringToStringMapEntry class". - */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); -} - -/** - * An element may be an instance of type "EStringToStringMapEntry class". - */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EGenericType class". - */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); -} - -/** - * An element may be an instance of type "EGenericType class". - */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypeParameter class". - */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); -} - -/** - * An element may be an instance of type "ETypeParameter class". - */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * An element must be an instance of type "EPackage class UndefinedPart". + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); + Type.name(type,"FunctionType enum"); } /** - * An element may be an instance of type "EPackage class UndefinedPart". + * An element may be an instance of type "FunctionType enum". */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers ////////// /** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationeAttributeType_reference_EAttribute( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationeAttributeType_reference_EAttribute( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36185,33 +33045,42 @@ private pattern mayInRelationeAttributeType_reference_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationdetails_reference_EAnnotation( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationdetails_reference_EAnnotation( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36220,34 +33089,33 @@ private pattern mayInRelationdetails_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationeModelElement_reference_EAnnotation( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationeModelElement_reference_EAnnotation( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36256,11 +33124,11 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents @@ -36268,26 +33136,26 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationcontents_reference_EAnnotation( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationcontents_reference_EAnnotation( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36296,34 +33164,34 @@ private pattern mayInRelationcontents_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationreferences_reference_EAnnotation( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationreferences_reference_EAnnotation( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36332,29 +33200,38 @@ private pattern mayInRelationreferences_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationeSuperTypes_reference_EClass( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationeSuperTypes_reference_EClass( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36363,29 +33240,42 @@ private pattern mayInRelationeSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationeOperations_reference_EClass( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationeOperations_reference_EClass( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36394,38 +33284,38 @@ private pattern mayInRelationeOperations_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationeAllAttributes_reference_EClass( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationeAllAttributes_reference_EClass( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36434,29 +33324,33 @@ private pattern mayInRelationeAllAttributes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationeAllReferences_reference_EClass( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationeAllReferences_reference_EClass( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36465,29 +33359,38 @@ private pattern mayInRelationeAllReferences_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationeReferences_reference_EClass( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationeReferences_reference_EClass( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36496,29 +33399,42 @@ private pattern mayInRelationeReferences_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationeAttributes_reference_EClass( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationeAttributes_reference_EClass( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36527,29 +33443,33 @@ private pattern mayInRelationeAttributes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationeAllContainments_reference_EClass( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationeAllContainments_reference_EClass( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36558,60 +33478,38 @@ private pattern mayInRelationeAllContainments_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) - */ -private pattern mustInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) - */ -private pattern mayInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36620,29 +33518,42 @@ private pattern mayInRelationeAllStructuralFeatures_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36651,29 +33562,38 @@ private pattern mayInRelationeAllSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationeIDAttribute_reference_EClass( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationeIDAttribute_reference_EClass( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -36682,780 +33602,1094 @@ private pattern mayInRelationeIDAttribute_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -/** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); -} or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) - */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) - */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) - */ -private pattern mustInRelationeLiterals_reference_EEnum( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) - */ -private pattern mayInRelationeLiterals_reference_EEnum( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) - */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) - */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) - */ -private pattern mustInRelationeAnnotations_reference_EModelElement( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) - */ -private pattern mayInRelationeAnnotations_reference_EModelElement( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EOperation( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EOperation( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EOperation( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EOperation( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) - */ -private pattern mustInRelationeParameters_reference_EOperation( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) - */ -private pattern mayInRelationeParameters_reference_EOperation( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); -} or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) - */ -private pattern mustInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) - */ -private pattern mayInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) - */ -private pattern mustInRelationeSubpackages_reference_EPackage( +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) - */ -private pattern mayInRelationeSubpackages_reference_EPackage( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) - */ -private pattern mustInRelationeSuperPackage_reference_EPackage( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) - */ -private pattern mayInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + LogicProblem.elements(problem,element); } or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) - */ -private pattern mustInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); } -/** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) - */ -private pattern mayInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); } or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); } -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37464,38 +34698,42 @@ private pattern mayInRelationeContainingClass_reference_EStructuralFeature( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); + neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationeType_reference_ETypedElement( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationeType_reference_ETypedElement( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37504,33 +34742,33 @@ private pattern mayInRelationeType_reference_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationeGenericType_reference_ETypedElement( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationeGenericType_reference_ETypedElement( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37539,38 +34777,38 @@ private pattern mayInRelationeGenericType_reference_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationeUpperBound_reference_EGenericType( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationeUpperBound_reference_EGenericType( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37579,38 +34817,34 @@ private pattern mayInRelationeUpperBound_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37619,34 +34853,38 @@ private pattern mayInRelationeTypeArguments_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationeRawType_reference_EGenericType( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationeRawType_reference_EGenericType( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37655,33 +34893,42 @@ private pattern mayInRelationeRawType_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationeLowerBound_reference_EGenericType( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationeLowerBound_reference_EGenericType( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37690,38 +34937,38 @@ private pattern mayInRelationeLowerBound_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37730,33 +34977,33 @@ private pattern mayInRelationeTypeParameter_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationeClassifier_reference_EGenericType( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationeClassifier_reference_EGenericType( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37765,69 +35012,38 @@ private pattern mayInRelationeClassifier_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) - */ -private pattern mustInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) - */ -private pattern mayInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationiD_attribute_EAttribute( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationiD_attribute_EAttribute( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37836,33 +35052,42 @@ private pattern mayInRelationiD_attribute_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationsource_attribute_EAnnotation( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationsource_attribute_EAnnotation( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37871,33 +35096,33 @@ private pattern mayInRelationsource_attribute_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationabstract_attribute_EClass( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationabstract_attribute_EClass( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37906,33 +35131,38 @@ private pattern mayInRelationabstract_attribute_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationinterface_attribute_EClass( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationinterface_attribute_EClass( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37941,33 +35171,42 @@ private pattern mayInRelationinterface_attribute_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -37976,33 +35215,38 @@ private pattern mayInRelationinstanceClassName_attribute_EClassifier( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -38011,733 +35255,1094 @@ private pattern mayInRelationinstanceTypeName_attribute_EClassifier( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) - */ -private pattern mustInRelationserializable_attribute_EDataType( + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) - */ -private pattern mayInRelationserializable_attribute_EDataType( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -/** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) - */ -private pattern mustInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } -/** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) - */ -private pattern mayInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) - */ -private pattern mustInRelationnsURI_attribute_EPackage( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) - */ -private pattern mayInRelationnsURI_attribute_EPackage( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) - */ -private pattern mustInRelationnsPrefix_attribute_EPackage( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) - */ -private pattern mayInRelationnsPrefix_attribute_EPackage( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) - */ -private pattern mayInRelationresolveProxies_attribute_EReference( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) - */ -private pattern mustInRelationordered_attribute_ETypedElement( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) - */ -private pattern mayInRelationordered_attribute_ETypedElement( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) - */ -private pattern mustInRelationunique_attribute_ETypedElement( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) - */ -private pattern mayInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); } or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); } -/** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); } or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); } -/** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -/** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationrequired_attribute_ETypedElement( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationrequired_attribute_ETypedElement( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -38746,33 +36351,42 @@ private pattern mayInRelationrequired_attribute_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -38781,33 +36395,33 @@ private pattern mayInRelationkey_attribute_EStringToStringMapEntry( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -38816,740 +36430,814 @@ private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } -pattern createObject_EAnnotation_class( +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } -pattern createObject_EClass_class( +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_EEnum_class( +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_EReference_class( +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern createObject_EOperation_class( +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class( +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EPackage_class_UndefinedPart( +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EStringToStringMapEntry_class( +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } -pattern createObject_EObject_class_by_contents_reference_EAnnotation( +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EObject_class( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EGenericType_class( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EParameter_class( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EAttribute_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EEnumLiteral_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_EDataType_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -39557,1010 +37245,195 @@ pattern createObject_EDataType_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); -} - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_eAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineRelation_references_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineRelation_eSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineRelation_eAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineRelation_eAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -pattern refineRelation_eReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } -pattern refineRelation_eAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); } -pattern refineRelation_eAllContainments_reference_EClass( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -pattern refineRelation_eAllOperations_reference_EClass( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -pattern refineRelation_eAllStructuralFeatures_reference_EClass( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -pattern refineRelation_eAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); } -pattern refineRelation_eIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + LogicProblem.elements(problem,element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); } -pattern refineRelation_eExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); } -pattern refineRelation_eOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -pattern refineRelation_eReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_eRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_iD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_source_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_abstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_interface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_instanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_instanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_serializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_literal_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_name_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); -} -pattern refineRelation_nsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_nsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_containment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_container_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_resolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_changeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_volatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_transient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_required_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_key_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); -} - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; -} - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); -} - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); LogicProblem.types(problem,type); TypeDefinition.elements(type,element); @@ -40586,1130 +37459,436 @@ private pattern isPrimitive(element: PrimitiveElement) { // 1.1.2 domain-specific Type Indexers ////////// /** - * An element must be an instance of type "EAttribute class". + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); + Type.name(type,"FunctionalElement class"); } /** - * An element may be an instance of type "EAttribute class". + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * An element must be an instance of type "EAnnotation class". + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); + Type.name(type,"FunctionalArchitectureModel class"); } /** - * An element may be an instance of type "EAnnotation class". + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClass class". + * An element must be an instance of type "Function class". */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); + Type.name(type,"Function class"); } /** - * An element may be an instance of type "EClass class". + * An element may be an instance of type "Function class". */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClassifier class". + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); + Type.name(type,"FAMTerminator class"); } /** - * An element may be an instance of type "EClassifier class". + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * An element must be an instance of type "EDataType class". + * An element must be an instance of type "InformationLink class". */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); + Type.name(type,"InformationLink class"); } /** - * An element may be an instance of type "EDataType class". + * An element may be an instance of type "InformationLink class". */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnum class". + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); + Type.name(type,"FunctionalInterface class"); } /** - * An element may be an instance of type "EEnum class". + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnumLiteral class". + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); + Type.name(type,"FunctionalInput class"); } /** - * An element may be an instance of type "EEnumLiteral class". + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class". - */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); -} - -/** - * An element may be an instance of type "EModelElement class". - */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class". - */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); -} - -/** - * An element may be an instance of type "ENamedElement class". - */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EObject class". - */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); -} - -/** - * An element may be an instance of type "EObject class". - */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EOperation class". - */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); -} - -/** - * An element may be an instance of type "EOperation class". - */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class". - */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); -} - -/** - * An element may be an instance of type "EPackage class". - */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EParameter class". - */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); -} - -/** - * An element may be an instance of type "EParameter class". - */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EReference class". - */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); -} - -/** - * An element may be an instance of type "EReference class". - */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStructuralFeature class". - */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); -} - -/** - * An element may be an instance of type "EStructuralFeature class". - */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypedElement class". - */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); -} - -/** - * An element may be an instance of type "ETypedElement class". - */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStringToStringMapEntry class". - */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); -} - -/** - * An element may be an instance of type "EStringToStringMapEntry class". - */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EGenericType class". - */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); -} - -/** - * An element may be an instance of type "EGenericType class". - */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypeParameter class". - */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); -} - -/** - * An element may be an instance of type "ETypeParameter class". - */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * An element must be an instance of type "EModelElement class UndefinedPart". + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); + Type.name(type,"FunctionalOutput class"); } /** - * An element may be an instance of type "EModelElement class UndefinedPart". + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * An element must be an instance of type "ENamedElement class UndefinedPart". + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); + Type.name(type,"FunctionalData class"); } /** - * An element may be an instance of type "ENamedElement class UndefinedPart". + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * An element must be an instance of type "EPackage class UndefinedPart". + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); + Type.name(type,"FunctionType enum"); } /** - * An element may be an instance of type "EPackage class UndefinedPart". + * An element may be an instance of type "FunctionType enum". */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers ////////// /** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationeAttributeType_reference_EAttribute( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationeAttributeType_reference_EAttribute( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41718,33 +37897,42 @@ private pattern mayInRelationeAttributeType_reference_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationdetails_reference_EAnnotation( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationdetails_reference_EAnnotation( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41753,34 +37941,33 @@ private pattern mayInRelationdetails_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationeModelElement_reference_EAnnotation( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationeModelElement_reference_EAnnotation( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41789,11 +37976,11 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents @@ -41801,26 +37988,26 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationcontents_reference_EAnnotation( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationcontents_reference_EAnnotation( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41829,34 +38016,34 @@ private pattern mayInRelationcontents_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationreferences_reference_EAnnotation( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationreferences_reference_EAnnotation( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41865,29 +38052,38 @@ private pattern mayInRelationreferences_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationeSuperTypes_reference_EClass( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationeSuperTypes_reference_EClass( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41896,29 +38092,42 @@ private pattern mayInRelationeSuperTypes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationeOperations_reference_EClass( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationeOperations_reference_EClass( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41927,38 +38136,38 @@ private pattern mayInRelationeOperations_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationeAllAttributes_reference_EClass( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationeAllAttributes_reference_EClass( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41967,29 +38176,33 @@ private pattern mayInRelationeAllAttributes_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationeAllReferences_reference_EClass( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationeAllReferences_reference_EClass( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -41998,29 +38211,38 @@ private pattern mayInRelationeAllReferences_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationeReferences_reference_EClass( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationeReferences_reference_EClass( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42029,366 +38251,42 @@ private pattern mayInRelationeReferences_reference_EClass( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) - */ -private pattern mustInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) - */ -private pattern mayInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) - */ -private pattern mustInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) - */ -private pattern mayInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); -} or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); -} or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) - */ -private pattern mustInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) - */ -private pattern mayInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); -} or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) - */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) - */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42397,34 +38295,33 @@ private pattern mayInRelationeTypeParameters_reference_EClassifier( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationeLiterals_reference_EEnum( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationeLiterals_reference_EEnum( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42433,11 +38330,11 @@ private pattern mayInRelationeLiterals_reference_EEnum( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -42445,26 +38342,26 @@ private pattern mayInRelationeLiterals_reference_EEnum( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42473,51 +38370,15 @@ private pattern mayInRelationeEnum_reference_EEnumLiteral( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) - */ -private pattern mustInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) - */ -private pattern mayInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -42525,26 +38386,26 @@ private pattern mayInRelationeAnnotations_reference_EModelElement( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationeContainingClass_reference_EOperation( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationeContainingClass_reference_EOperation( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42553,11 +38414,11 @@ private pattern mayInRelationeContainingClass_reference_EOperation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents @@ -42565,26 +38426,26 @@ private pattern mayInRelationeContainingClass_reference_EOperation( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationeTypeParameters_reference_EOperation( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationeTypeParameters_reference_EOperation( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -42593,14513 +38454,2305 @@ private pattern mayInRelationeTypeParameters_reference_EOperation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) - */ -private pattern mustInRelationeParameters_reference_EOperation( + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) - */ -private pattern mayInRelationeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeExceptions_reference_EOperation( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); -} or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -/** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -/** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) - */ -private pattern mustInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); } -/** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) - */ -private pattern mayInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) - */ -private pattern mustInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -/** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) - */ -private pattern mayInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } -/** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) - */ -private pattern mustInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) - */ -private pattern mayInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) - */ -private pattern mustInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) - */ -private pattern mayInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); } -/** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) - */ -private pattern mustInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) - */ -private pattern mayInRelationeReferenceType_reference_EReference( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) - */ -private pattern mustInRelationeKeys_reference_EReference( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) - */ -private pattern mayInRelationeKeys_reference_EReference( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) - */ -private pattern mustInRelationeType_reference_ETypedElement( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) - */ -private pattern mayInRelationeType_reference_ETypedElement( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) - */ -private pattern mustInRelationeGenericType_reference_ETypedElement( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) - */ -private pattern mayInRelationeGenericType_reference_ETypedElement( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) - */ -private pattern mustInRelationeUpperBound_reference_EGenericType( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) - */ -private pattern mayInRelationeUpperBound_reference_EGenericType( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) - */ -private pattern mustInRelationeRawType_reference_EGenericType( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) - */ -private pattern mayInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) - */ -private pattern mustInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) - */ -private pattern mayInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) - */ -private pattern mustInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) - */ -private pattern mayInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) - */ -private pattern mustInRelationeBounds_reference_ETypeParameter( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) - */ -private pattern mayInRelationeBounds_reference_ETypeParameter( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) - */ -private pattern mustInRelationiD_attribute_EAttribute( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) - */ -private pattern mayInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); } or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) - */ -private pattern mustInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); } -/** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) - */ -private pattern mayInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); } or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); } -/** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) - */ -private pattern mustInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -/** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) - */ -private pattern mayInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) + * An element must be an instance of type "Function class". */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); } + /** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) - */ -private pattern mustInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) - */ -private pattern mayInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) - */ -private pattern mustInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) - */ -private pattern mayInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) - */ -private pattern mustInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) - */ -private pattern mayInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) + * An element must be an instance of type "InformationLink class". */ -private pattern mayInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); } -/** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); } + /** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + * An element may be an instance of type "InformationLink class". */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); } -/** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); } + /** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalInput class". */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); } -/** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); } + /** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mayInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); } -/** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) - */ -private pattern mustInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); } + /** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) - */ -private pattern mustInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalData class". */ -private pattern mayInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) - */ -private pattern mustInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) - */ -private pattern mayInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) - */ -private pattern mustInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) - */ -private pattern mayInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) -{ - find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -} -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class_by_contents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EReference_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EDataType_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); -} -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); -} - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_eAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_references_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_eSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); -} -pattern refineRelation_eOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_eRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_iD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_source_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_abstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_interface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_instanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_instanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_serializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_literal_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_name_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); -} -pattern refineRelation_nsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_nsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_containment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_container_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_resolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_changeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_volatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_transient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_required_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_key_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); -} - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; -} - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); -} - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { - find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); -} - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); -} - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "EAttribute class". - */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); -} - -/** - * An element may be an instance of type "EAttribute class". - */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EAnnotation class". - */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); -} - -/** - * An element may be an instance of type "EAnnotation class". - */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EClass class". - */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); -} - -/** - * An element may be an instance of type "EClass class". - */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EClassifier class". - */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); -} - -/** - * An element may be an instance of type "EClassifier class". - */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EDataType class". - */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); -} - -/** - * An element may be an instance of type "EDataType class". - */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EEnum class". - */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); -} - -/** - * An element may be an instance of type "EEnum class". - */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EEnumLiteral class". - */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); -} - -/** - * An element may be an instance of type "EEnumLiteral class". - */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class". - */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); -} - -/** - * An element may be an instance of type "EModelElement class". - */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class". - */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); -} - -/** - * An element may be an instance of type "ENamedElement class". - */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EObject class". - */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); -} - -/** - * An element may be an instance of type "EObject class". - */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EOperation class". - */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); -} - -/** - * An element may be an instance of type "EOperation class". - */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class". - */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); -} - -/** - * An element may be an instance of type "EPackage class". - */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EParameter class". - */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); -} - -/** - * An element may be an instance of type "EParameter class". - */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EReference class". - */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); -} - -/** - * An element may be an instance of type "EReference class". - */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStructuralFeature class". - */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); -} - -/** - * An element may be an instance of type "EStructuralFeature class". - */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypedElement class". - */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); -} - -/** - * An element may be an instance of type "ETypedElement class". - */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStringToStringMapEntry class". - */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); -} - -/** - * An element may be an instance of type "EStringToStringMapEntry class". - */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EGenericType class". - */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); -} - -/** - * An element may be an instance of type "EGenericType class". - */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypeParameter class". - */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); -} - -/** - * An element may be an instance of type "ETypeParameter class". - */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class UndefinedPart". - */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class UndefinedPart". - */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) - */ -private pattern mustInRelationeAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) - */ -private pattern mayInRelationeAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) - */ -private pattern mustInRelationdetails_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) - */ -private pattern mayInRelationdetails_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) - */ -private pattern mustInRelationeModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) - */ -private pattern mayInRelationeModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) - */ -private pattern mustInRelationcontents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) - */ -private pattern mayInRelationcontents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) - */ -private pattern mustInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) - */ -private pattern mayInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); -} or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) - */ -private pattern mustInRelationeOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) - */ -private pattern mayInRelationeOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) - */ -private pattern mustInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) - */ -private pattern mayInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) - */ -private pattern mustInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) - */ -private pattern mayInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) - */ -private pattern mustInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) - */ -private pattern mayInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) - */ -private pattern mustInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) - */ -private pattern mayInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); -} or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); -} or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) - */ -private pattern mustInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) - */ -private pattern mayInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); -} or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) - */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) - */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) - */ -private pattern mustInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) - */ -private pattern mayInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) - */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) - */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) - */ -private pattern mustInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) - */ -private pattern mayInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) - */ -private pattern mustInRelationeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) - */ -private pattern mayInRelationeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); -} or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) - */ -private pattern mustInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) - */ -private pattern mayInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) - */ -private pattern mustInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) - */ -private pattern mayInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) - */ -private pattern mustInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) - */ -private pattern mayInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) - */ -private pattern mustInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) - */ -private pattern mayInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) - */ -private pattern mustInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) - */ -private pattern mayInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) - */ -private pattern mustInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) - */ -private pattern mayInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) - */ -private pattern mustInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) - */ -private pattern mayInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) - */ -private pattern mustInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) - */ -private pattern mayInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) - */ -private pattern mustInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) - */ -private pattern mayInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) - */ -private pattern mustInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) - */ -private pattern mayInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) - */ -private pattern mustInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) - */ -private pattern mayInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) - */ -private pattern mustInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) - */ -private pattern mayInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) - */ -private pattern mustInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) - */ -private pattern mayInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) - */ -private pattern mustInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) - */ -private pattern mayInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) - */ -private pattern mustInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) - */ -private pattern mayInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) - */ -private pattern mustInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) - */ -private pattern mayInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) - */ -private pattern mustInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) - */ -private pattern mayInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) - */ -private pattern mustInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) - */ -private pattern mayInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) - */ -private pattern mustInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) - */ -private pattern mayInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) - */ -private pattern mustInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) - */ -private pattern mayInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) - */ -private pattern mustInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) - */ -private pattern mayInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) - */ -private pattern mayInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) - */ -private pattern mustInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) - */ -private pattern mayInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) - */ -private pattern mustInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) - */ -private pattern mayInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) - */ -private pattern mustInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) - */ -private pattern mayInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) - */ -private pattern mustInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) - */ -private pattern mayInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) -{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -} -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EDataType_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class_by_contents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EReference_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); -} -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); -} - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_eAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_references_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_eSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); -} -pattern refineRelation_eExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); -} -pattern refineRelation_eOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); -} -pattern refineRelation_eType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_eRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_iD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_source_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_abstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_interface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_instanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_instanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); -} -pattern refineRelation_serializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_literal_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); -} -pattern refineRelation_name_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); -} -pattern refineRelation_nsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_nsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); -} -pattern refineRelation_containment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_container_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_resolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); -} -pattern refineRelation_changeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_volatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_transient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); -} -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_required_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); -} -pattern refineRelation_key_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -pattern refineRelation_value_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); -} - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; -} - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); -} - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { - find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); -} - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); -} - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "EAttribute class". - */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); -} - -/** - * An element may be an instance of type "EAttribute class". - */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EAnnotation class". - */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); -} - -/** - * An element may be an instance of type "EAnnotation class". - */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EClass class". - */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); -} - -/** - * An element may be an instance of type "EClass class". - */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EClassifier class". - */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); -} - -/** - * An element may be an instance of type "EClassifier class". - */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EDataType class". - */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); -} - -/** - * An element may be an instance of type "EDataType class". - */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EEnum class". - */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); -} - -/** - * An element may be an instance of type "EEnum class". - */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EEnumLiteral class". - */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); -} - -/** - * An element may be an instance of type "EEnumLiteral class". - */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class". - */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); -} - -/** - * An element may be an instance of type "EModelElement class". - */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class". - */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); -} - -/** - * An element may be an instance of type "ENamedElement class". - */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EObject class". - */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); -} - -/** - * An element may be an instance of type "EObject class". - */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EOperation class". - */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); -} - -/** - * An element may be an instance of type "EOperation class". - */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class". - */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); -} - -/** - * An element may be an instance of type "EPackage class". - */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EParameter class". - */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); -} - -/** - * An element may be an instance of type "EParameter class". - */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EReference class". - */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); -} - -/** - * An element may be an instance of type "EReference class". - */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStructuralFeature class". - */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); -} - -/** - * An element may be an instance of type "EStructuralFeature class". - */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypedElement class". - */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); -} - -/** - * An element may be an instance of type "ETypedElement class". - */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EStringToStringMapEntry class". - */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); -} - -/** - * An element may be an instance of type "EStringToStringMapEntry class". - */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EGenericType class". - */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); -} - -/** - * An element may be an instance of type "EGenericType class". - */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } -/** - * An element must be an instance of type "ETypeParameter class". - */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); -} - -/** - * An element may be an instance of type "ETypeParameter class". - */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "EModelElement class UndefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); -} - -/** - * An element may be an instance of type "ENamedElement class UndefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class UndefinedPart". - */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); -} - -/** - * An element may be an instance of type "EPackage class UndefinedPart". - */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) - */ -private pattern mustInRelationeAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) - */ -private pattern mayInRelationeAttributeType_reference_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) - */ -private pattern mustInRelationdetails_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) - */ -private pattern mayInRelationdetails_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) - */ -private pattern mustInRelationeModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) - */ -private pattern mayInRelationeModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) - */ -private pattern mustInRelationcontents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) - */ -private pattern mayInRelationcontents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) - */ -private pattern mustInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) - */ -private pattern mayInRelationreferences_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); -} or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) - */ -private pattern mustInRelationeOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) - */ -private pattern mayInRelationeOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAllAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) - */ -private pattern mustInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) - */ -private pattern mayInRelationeAllReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) - */ -private pattern mustInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) - */ -private pattern mayInRelationeReferences_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAttributes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) - */ -private pattern mustInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) - */ -private pattern mayInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) - */ -private pattern mustInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) - */ -private pattern mayInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); -} or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); -} or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) - */ -private pattern mustInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) - */ -private pattern mayInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); -} or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) - */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) - */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) - */ -private pattern mustInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) - */ -private pattern mayInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) - */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) - */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) - */ -private pattern mustInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) - */ -private pattern mayInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) - */ -private pattern mustInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) - */ -private pattern mayInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) - */ -private pattern mustInRelationeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) - */ -private pattern mayInRelationeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); -} or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) - */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) - */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) - */ -private pattern mustInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) - */ -private pattern mayInRelationeClassifiers_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) - */ -private pattern mustInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) - */ -private pattern mayInRelationeSubpackages_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) - */ -private pattern mustInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) - */ -private pattern mayInRelationeSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) - */ -private pattern mustInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) - */ -private pattern mayInRelationeOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) - */ -private pattern mustInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) - */ -private pattern mayInRelationeReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) - */ -private pattern mustInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) - */ -private pattern mayInRelationeKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) - */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) - */ -private pattern mustInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) - */ -private pattern mayInRelationeType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) - */ -private pattern mustInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) - */ -private pattern mayInRelationeGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) - */ -private pattern mustInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) - */ -private pattern mayInRelationeUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) - */ -private pattern mustInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) - */ -private pattern mayInRelationeRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) - */ -private pattern mustInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) - */ -private pattern mayInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) - */ -private pattern mustInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) - */ -private pattern mayInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) - */ -private pattern mustInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) - */ -private pattern mayInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) - */ -private pattern mustInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) - */ -private pattern mayInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) - */ -private pattern mustInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) - */ -private pattern mayInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) - */ -private pattern mustInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) - */ -private pattern mayInRelationabstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) - */ -private pattern mustInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) - */ -private pattern mayInRelationinterface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) - */ -private pattern mustInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) - */ -private pattern mayInRelationserializable_attribute_EDataType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) - */ -private pattern mustInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) - */ -private pattern mayInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) - */ -private pattern mustInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) - */ -private pattern mayInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) - */ -private pattern mustInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) - */ -private pattern mayInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) - */ -private pattern mayInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) - */ -private pattern mustInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) - */ -private pattern mayInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) - */ -private pattern mustInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) - */ -private pattern mayInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) - */ -private pattern mustInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) - */ -private pattern mayInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) - */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) - */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) - */ -private pattern mustInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) - */ -private pattern mayInRelationmany_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) - */ -private pattern mustInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) - */ -private pattern mayInRelationrequired_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) - */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) -{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -} -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EClass_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); } -pattern createObject_EOperation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_EReference_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } -pattern createObject_EObject_class_by_contents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_EObject_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); } -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_EEnumLiteral_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); } -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class( + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EDataType_class( +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } -pattern createObject_EGenericType_class( +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } -pattern createObject_EStringToStringMapEntry_class( +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_ETypeParameter_class( +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_eAttributeType_reference_EAttribute( +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_references_reference_EAnnotation( +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern refineRelation_eSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllAttributes_reference_EClass( +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern refineRelation_eAllReferences_reference_EClass( +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eReferences_reference_EClass( +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } -pattern refineRelation_eAttributes_reference_EClass( +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllContainments_reference_EClass( +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } -pattern refineRelation_eAllOperations_reference_EClass( +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllStructuralFeatures_reference_EClass( +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } -pattern refineRelation_eAllSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eIDAttribute_reference_EClass( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eExceptions_reference_EOperation( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -pattern refineRelation_eOpposite_reference_EReference( + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -pattern refineRelation_eReferenceType_reference_EReference( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); } -pattern refineRelation_eKeys_reference_EReference( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_T, var_I) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; } -pattern refineRelation_eType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) { + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_iD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_source_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_abstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_interface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_instanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -pattern refineRelation_instanceTypeName_attribute_EClassifier( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_serializable_attribute_EDataType( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_value_attribute_EEnumLiteral( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_literal_attribute_EEnumLiteral( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_name_attribute_ENamedElement( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_nsURI_attribute_EPackage( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_nsPrefix_attribute_EPackage( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_containment_attribute_EReference( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_container_attribute_EReference( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_resolveProxies_attribute_EReference( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_changeable_attribute_EStructuralFeature( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_volatile_attribute_EStructuralFeature( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_transient_attribute_EStructuralFeature( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } -pattern refineRelation_required_attribute_ETypedElement( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -pattern refineRelation_key_attribute_EStringToStringMapEntry( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -pattern refineRelation_value_attribute_EStringToStringMapEntry( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" @@ -57207,22 +40860,22 @@ private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, inter { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); @@ -57251,22 +40904,20 @@ private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProb { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); @@ -57295,20 +40946,20 @@ private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); @@ -57337,9 +40988,9 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); @@ -57347,9 +40998,9 @@ private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpret } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); @@ -57379,21 +41030,21 @@ private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or @@ -57421,20 +41072,20 @@ private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, int { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); @@ -57463,22 +41114,22 @@ private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); @@ -57507,23 +41158,23 @@ private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or @@ -57551,25 +41202,25 @@ private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpre { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or @@ -57595,69 +41246,6 @@ private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpr */ private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find mustInstanceOfFunctionType_enum(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class DefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); -} - -/** - * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". - */ -private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } ////////// // 1.2 Relation Declaration Indexers @@ -58258,6 +41846,103 @@ private pattern mayInRelationtype_attribute_Function( ////////// // 1.3 Relation Definition Indexers ////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} ////////// // 1.4 Containment Indexer @@ -58289,6 +41974,11 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 3. Unfinishedness Indexers @@ -58326,6 +42016,11 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} ////////// // 4. Refinement Indexers @@ -58335,15 +42030,15 @@ pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustInstanceOfInformationLink_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunction_class(problem,interpretation,root); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -58351,19 +42046,15 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfInformationLink_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustInstanceOfFunction_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -58371,158 +42062,184 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); find mustExist(problem, interpretation, root); -}or{ +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ find interpretation(problem,interpretation); - find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalOutput_class( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); - find mustInstanceOfFunctionalData_class(problem,interpretation,container); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); - find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FAMTerminator_class( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); - find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); - find mustInstanceOfFunctionalElement_class(problem,interpretation,container); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); - find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInterface_class( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); - find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); - find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); - find mustInstanceOfFunction_class(problem,interpretation,container); - find mayInstanceOfFunction_class(problem,interpretation,newObject); - find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Function_class( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); - find mayInstanceOfFunction_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -58556,118 +42273,88 @@ pattern createObject_InformationLink_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); - find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FunctionalInput_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); - find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); -} -pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); - neg find mustInstanceOfInformationLink_class(problem,interpretation,element); -} -pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunction_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); - neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); neg find mustInstanceOfInformationLink_class(problem,interpretation,element); - neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } ////////// @@ -58804,1130 +42491,869 @@ private pattern isPrimitive(element: PrimitiveElement) { // 1.1.2 domain-specific Type Indexers ////////// /** - * An element must be an instance of type "EAttribute class". + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAttribute class"); +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAttribute class"); + Type.name(type,"FunctionalElement class"); } /** - * An element may be an instance of type "EAttribute class". + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInstanceOfEAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEAttribute_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAttribute_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * An element must be an instance of type "EAnnotation class". + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EAnnotation class"); +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EAnnotation class"); + Type.name(type,"FunctionalArchitectureModel class"); } /** - * An element may be an instance of type "EAnnotation class". + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInstanceOfEAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEAnnotation_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEAnnotation_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClass class". + * An element must be an instance of type "Function class". */ -private pattern mustInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClass class"); +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClass_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClass class"); + Type.name(type,"Function class"); } /** - * An element may be an instance of type "EClass class". + * An element may be an instance of type "Function class". */ -private pattern mayInstanceOfEClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEClass_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClass_class(problem,interpretation,element); } +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * An element must be an instance of type "EClassifier class". + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EClassifier class"); +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EClassifier class"); + Type.name(type,"FAMTerminator class"); } /** - * An element may be an instance of type "EClassifier class". + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInstanceOfEClassifier_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEClassifier_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEClassifier_class(problem,interpretation,element); } +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * An element must be an instance of type "EDataType class". + * An element must be an instance of type "InformationLink class". */ -private pattern mustInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EDataType class"); +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EDataType class"); + Type.name(type,"InformationLink class"); } /** - * An element may be an instance of type "EDataType class". + * An element may be an instance of type "InformationLink class". */ -private pattern mayInstanceOfEDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEDataType_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEDataType_class(problem,interpretation,element); } +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnum class". + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnum class"); +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnum class"); + Type.name(type,"FunctionalInterface class"); } /** - * An element may be an instance of type "EEnum class". + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInstanceOfEEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnum_class(problem, interpretation); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnum_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * An element must be an instance of type "EEnumLiteral class". + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EEnumLiteral class"); +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EEnumLiteral class"); + Type.name(type,"FunctionalInput class"); } /** - * An element may be an instance of type "EEnumLiteral class". + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInstanceOfEEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEEnumLiteral_class(problem, interpretation); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * An element must be an instance of type "EModelElement class". + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class"); +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class"); + Type.name(type,"FunctionalOutput class"); } /** - * An element may be an instance of type "EModelElement class". + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInstanceOfEModelElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfEModelElement_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * An element must be an instance of type "ENamedElement class". + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class"); +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class"); + Type.name(type,"FunctionalData class"); } /** - * An element may be an instance of type "ENamedElement class". + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInstanceOfENamedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class(problem, interpretation); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfENamedElement_class(problem,interpretation,element); } +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * An element must be an instance of type "EObject class". + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EObject class"); +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewEObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EObject class"); + Type.name(type,"FunctionType enum"); } /** - * An element may be an instance of type "EObject class". - */ -private pattern mayInstanceOfEObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EOperation class". + * An element may be an instance of type "FunctionType enum". */ -private pattern mustInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EOperation class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EOperation class"); -} +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * An element may be an instance of type "EOperation class". + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewEOperation_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEOperation_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class". - */ -private pattern mustInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EPackage class". + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEPackage_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class(problem,interpretation,element); } + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EParameter class". + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EParameter class". + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewEParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEParameter_class(problem,interpretation,element); } + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EReference class". + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EReference class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEReference_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EReference class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EReference class". + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInstanceOfEReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEReference_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEReference_class(problem,interpretation,element); } + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EStructuralFeature class". + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStructuralFeature class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStructuralFeature class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EStructuralFeature class". + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInstanceOfEStructuralFeature_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find scopeDisallowsNewEStructuralFeature_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); } + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} /** - * An element must be an instance of type "ETypedElement class". + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypedElement class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypedElement class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "ETypedElement class". + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInstanceOfETypedElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find scopeDisallowsNewETypedElement_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypedElement_class(problem,interpretation,element); } + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EStringToStringMapEntry class". + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EStringToStringMapEntry class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EStringToStringMapEntry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EStringToStringMapEntry class". + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInstanceOfEStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEStringToStringMapEntry_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); } + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} /** - * An element must be an instance of type "EGenericType class". + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EGenericType class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EGenericType class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EGenericType class". + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInstanceOfEGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEGenericType_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEGenericType_class(problem,interpretation,element); } + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} /** - * An element must be an instance of type "ETypeParameter class". + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ETypeParameter class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ETypeParameter class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "ETypeParameter class". + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInstanceOfETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewETypeParameter_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfETypeParameter_class(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class DefinedPart". - */ -private pattern mustInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class DefinedPart"); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } - /** - * An element may be an instance of type "EModelElement class DefinedPart". - */ -private pattern mayInstanceOfEModelElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EModelElement class UndefinedPart". + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EModelElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EModelElement class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EModelElement class UndefinedPart". + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInstanceOfEModelElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); - neg find scopeDisallowsNewEModelElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mustInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class DefinedPart"); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } - -/** - * An element may be an instance of type "ENamedElement class DefinedPart". - */ -private pattern mayInstanceOfENamedElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,element); } /** - * An element must be an instance of type "ENamedElement class UndefinedPart". + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"ENamedElement class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"ENamedElement class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "ENamedElement class UndefinedPart". + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInstanceOfENamedElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find scopeDisallowsNewENamedElement_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "EPackage class DefinedPart". - */ -private pattern mustInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class DefinedPart"); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } - -/** - * An element may be an instance of type "EPackage class DefinedPart". - */ -private pattern mayInstanceOfEPackage_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,element); } /** - * An element must be an instance of type "EPackage class UndefinedPart". + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"EPackage class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"EPackage class UndefinedPart"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "EPackage class UndefinedPart". + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInstanceOfEPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find scopeDisallowsNewEPackage_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} /** - * Matcher for detecting tuples t where []eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationeAttributeType_reference_EAttribute( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eAttributeType reference EAttribute(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationeAttributeType_reference_EAttribute( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -59936,33 +43362,38 @@ private pattern mayInRelationeAttributeType_reference_EAttribute( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - find mayInstanceOfEDataType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []details reference EAnnotation(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationdetails_reference_EAnnotation( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"details reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>details reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationdetails_reference_EAnnotation( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -59971,34 +43402,42 @@ private pattern mayInRelationdetails_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationeModelElement_reference_EAnnotation( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eModelElement reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eModelElement reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationeModelElement_reference_EAnnotation( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60007,11 +43446,11 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEModelElement_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents @@ -60019,26 +43458,26 @@ private pattern mayInRelationeModelElement_reference_EAnnotation( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationcontents_reference_EAnnotation( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference EAnnotation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>contents reference EAnnotation(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationcontents_reference_EAnnotation( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60047,798 +43486,987 @@ private pattern mayInRelationcontents_reference_EAnnotation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []references reference EAnnotation(source,target) - */ -private pattern mustInRelationreferences_reference_EAnnotation( + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>references reference EAnnotation(source,target) - */ -private pattern mayInRelationreferences_reference_EAnnotation( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - find mayInstanceOfEObject_class(problem,interpretation,target); -} or { - find mustInRelationreferences_reference_EAnnotation(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeSuperTypes_reference_EClass( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeSuperTypes_reference_EClass( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eOperations reference EClass(source,target) - */ -private pattern mustInRelationeOperations_reference_EClass( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eOperations reference EClass(source,target) - */ -private pattern mayInRelationeOperations_reference_EClass( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eAllAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAllAttributes_reference_EClass( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eAllAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAllAttributes_reference_EClass( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eAllReferences reference EClass(source,target) - */ -private pattern mustInRelationeAllReferences_reference_EClass( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eAllReferences reference EClass(source,target) - */ -private pattern mayInRelationeAllReferences_reference_EClass( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllReferences_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eReferences reference EClass(source,target) - */ -private pattern mustInRelationeReferences_reference_EClass( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eReferences reference EClass(source,target) - */ -private pattern mayInRelationeReferences_reference_EClass( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeReferences_reference_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eAttributes reference EClass(source,target) - */ -private pattern mustInRelationeAttributes_reference_EClass( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>eAttributes reference EClass(source,target) - */ -private pattern mayInRelationeAttributes_reference_EClass( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); -} or { - find mustInRelationeAttributes_reference_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []eAllContainments reference EClass(source,target) - */ -private pattern mustInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eAllContainments reference EClass(source,target) - */ -private pattern mayInRelationeAllContainments_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); -} or { - find mustInRelationeAllContainments_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eAllOperations reference EClass(source,target) - */ -private pattern mustInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eAllOperations reference EClass(source,target) - */ -private pattern mayInRelationeAllOperations_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); -} or { - find mustInRelationeAllOperations_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mustInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>eAllStructuralFeatures reference EClass(source,target) - */ -private pattern mayInRelationeAllStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); -} or { - find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []eAllSuperTypes reference EClass(source,target) - */ -private pattern mustInRelationeAllSuperTypes_reference_EClass( +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eAllSuperTypes reference EClass(source,target) - */ -private pattern mayInRelationeAllSuperTypes_reference_EClass( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); -} or { - find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []eIDAttribute reference EClass(source,target) - */ -private pattern mustInRelationeIDAttribute_reference_EClass( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>eIDAttribute reference EClass(source,target) - */ -private pattern mayInRelationeIDAttribute_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []eStructuralFeatures reference EClass(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eStructuralFeatures reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>eStructuralFeatures reference EClass(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationeStructuralFeatures_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEStructuralFeature_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eGenericSuperTypes reference EClass(source,target) + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where <>eGenericSuperTypes reference EClass(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInRelationeGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eAllGenericSuperTypes reference EClass(source,target) + * An element must be an instance of type "Function class". */ -private pattern mustInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>eAllGenericSuperTypes reference EClass(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationeAllGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []ePackage reference EClassifier(source,target) + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ePackage reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); } + /** - * Matcher for detecting tuples t where <>ePackage reference EClassifier(source,target) + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInRelationePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationePackage_reference_EClassifier(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eTypeParameters reference EClassifier(source,target) + * An element must be an instance of type "InformationLink class". */ -private pattern mustInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); } + /** - * Matcher for detecting tuples t where <>eTypeParameters reference EClassifier(source,target) + * An element may be an instance of type "InformationLink class". */ -private pattern mayInRelationeTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eLiterals reference EEnum(source,target) + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLiterals reference EEnum"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); } + /** - * Matcher for detecting tuples t where <>eLiterals reference EEnum(source,target) + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInRelationeLiterals_reference_EEnum( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnum_class(problem,interpretation,source); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eEnum reference EEnumLiteral(source,target) + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eEnum reference EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); } + /** - * Matcher for detecting tuples t where <>eEnum reference EEnumLiteral(source,target) + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInRelationeEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - find mayInstanceOfEEnum_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeEnum_reference_EEnumLiteral(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eAnnotations reference EModelElement(source,target) + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAnnotations reference EModelElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); } + /** - * Matcher for detecting tuples t where <>eAnnotations reference EModelElement(source,target) + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInRelationeAnnotations_reference_EModelElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEModelElement_class(problem,interpretation,source); - find mayInstanceOfEAnnotation_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeModelElement_reference_EAnnotation(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eContainingClass reference EOperation(source,target) + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); } + /** - * Matcher for detecting tuples t where <>eContainingClass reference EOperation(source,target) + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInRelationeContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationeContainingClass_reference_EOperation(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []eTypeParameters reference EOperation(source,target) + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameters reference EOperation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } + /** - * Matcher for detecting tuples t where <>eTypeParameters reference EOperation(source,target) + * An element may be an instance of type "FunctionType enum". */ -private pattern mayInRelationeTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); -} +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * Matcher for detecting tuples t where []eParameters reference EOperation(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationeParameters_reference_EOperation( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eParameters reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eParameters reference EOperation(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationeParameters_reference_EOperation( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60847,11 +44475,15 @@ private pattern mayInRelationeParameters_reference_EOperation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEParameter_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -60859,26 +44491,26 @@ private pattern mayInRelationeParameters_reference_EOperation( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eExceptions reference EOperation(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationeExceptions_reference_EOperation( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eExceptions reference EOperation(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationeExceptions_reference_EOperation( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60887,29 +44519,33 @@ private pattern mayInRelationeExceptions_reference_EOperation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find mustInRelationeExceptions_reference_EOperation(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eGenericExceptions reference EOperation(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationeGenericExceptions_reference_EOperation( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericExceptions reference EOperation"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eGenericExceptions reference EOperation(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationeGenericExceptions_reference_EOperation( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60918,34 +44554,38 @@ private pattern mayInRelationeGenericExceptions_reference_EOperation( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEOperation_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eClassifiers reference EPackage(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationeClassifiers_reference_EPackage( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifiers reference EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eClassifiers reference EPackage(source,target) + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mayInRelationeClassifiers_reference_EPackage( +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60954,38 +44594,34 @@ private pattern mayInRelationeClassifiers_reference_EPackage( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationePackage_reference_EClassifier(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eSubpackages reference EPackage(source,target) + * Matcher for detecting tuples t where []subElements reference Function(source,target) */ -private pattern mustInRelationeSubpackages_reference_EPackage( +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSubpackages reference EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eSubpackages reference EPackage(source,target) + * Matcher for detecting tuples t where <>subElements reference Function(source,target) */ -private pattern mayInRelationeSubpackages_reference_EPackage( +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -60994,11 +44630,11 @@ private pattern mayInRelationeSubpackages_reference_EPackage( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference to the target, // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,target,_); + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents @@ -61006,26 +44642,26 @@ private pattern mayInRelationeSubpackages_reference_EPackage( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eSuperPackage reference EPackage(source,target) + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) */ -private pattern mustInRelationeSuperPackage_reference_EPackage( +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperPackage reference EPackage"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eSuperPackage reference EPackage(source,target) + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) */ -private pattern mayInRelationeSuperPackage_reference_EPackage( +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61034,38 +44670,42 @@ private pattern mayInRelationeSuperPackage_reference_EPackage( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - find mayInstanceOfEPackage_class(problem,interpretation,target); + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeSuperPackage_reference_EPackage(problem,interpretation,source,target); + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eOperation reference EParameter(source,target) + * Matcher for detecting tuples t where []from reference InformationLink(source,target) */ -private pattern mustInRelationeOperation_reference_EParameter( +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOperation reference EParameter"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eOperation reference EParameter(source,target) + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) */ -private pattern mayInRelationeOperation_reference_EParameter( +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61074,11 +44714,11 @@ private pattern mayInRelationeOperation_reference_EParameter( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEParameter_class(problem,interpretation,source); - find mayInstanceOfEOperation_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents @@ -61086,61 +44726,26 @@ private pattern mayInRelationeOperation_reference_EParameter( // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeOperation_reference_EParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []eOpposite reference EReference(source,target) - */ -private pattern mustInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eOpposite reference EReference(source,target) - */ -private pattern mayInRelationeOpposite_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEReference_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationeOpposite_reference_EReference(problem,interpretation,source,target); + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eReferenceType reference EReference(source,target) + * Matcher for detecting tuples t where []to reference InformationLink(source,target) */ -private pattern mustInRelationeReferenceType_reference_EReference( +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eReferenceType reference EReference(source,target) + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) */ -private pattern mayInRelationeReferenceType_reference_EReference( +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61149,33 +44754,33 @@ private pattern mayInRelationeReferenceType_reference_EReference( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeReferenceType_reference_EReference(problem,interpretation,source,target); + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eKeys reference EReference(source,target) + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) */ -private pattern mustInRelationeKeys_reference_EReference( +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eKeys reference EReference(source,target) + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) */ -private pattern mayInRelationeKeys_reference_EReference( +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61184,29 +44789,38 @@ private pattern mayInRelationeKeys_reference_EReference( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - find mayInstanceOfEAttribute_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationeKeys_reference_EReference(problem,interpretation,source,target); + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eContainingClass reference EStructuralFeature(source,target) + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) */ -private pattern mustInRelationeContainingClass_reference_EStructuralFeature( +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eContainingClass reference EStructuralFeature"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eContainingClass reference EStructuralFeature(source,target) + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) */ -private pattern mayInRelationeContainingClass_reference_EStructuralFeature( +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61215,38 +44829,42 @@ private pattern mayInRelationeContainingClass_reference_EStructuralFeature( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - find mayInstanceOfEClass_class(problem,interpretation,target); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeContainingClass_reference_EStructuralFeature(problem,interpretation,source,target); + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eType reference ETypedElement(source,target) + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) */ -private pattern mustInRelationeType_reference_ETypedElement( +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eType reference ETypedElement(source,target) + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) */ -private pattern mayInRelationeType_reference_ETypedElement( +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61255,33 +44873,33 @@ private pattern mayInRelationeType_reference_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); } or { - find mustInRelationeType_reference_ETypedElement(problem,interpretation,source,target); + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eGenericType reference ETypedElement(source,target) + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mustInRelationeGenericType_reference_ETypedElement( +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eGenericType reference ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eGenericType reference ETypedElement(source,target) + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) */ -private pattern mayInRelationeGenericType_reference_ETypedElement( +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61290,38 +44908,38 @@ private pattern mayInRelationeGenericType_reference_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eUpperBound reference EGenericType(source,target) + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) */ -private pattern mustInRelationeUpperBound_reference_EGenericType( +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eUpperBound reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eUpperBound reference EGenericType(source,target) + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) */ -private pattern mayInRelationeUpperBound_reference_EGenericType( +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61330,38 +44948,42 @@ private pattern mayInRelationeUpperBound_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); // The reference is containment, then a new reference cannot be create if: // 1. Multiple parents neg find mustContains4(problem,interpretation,_,target); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eTypeArguments reference EGenericType(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) */ -private pattern mustInRelationeTypeArguments_reference_EGenericType( +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeArguments reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eTypeArguments reference EGenericType(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) */ -private pattern mayInRelationeTypeArguments_reference_EGenericType( +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61370,34 +44992,38 @@ private pattern mayInRelationeTypeArguments_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); + neg find mustContains4(problem,interpretation,source,_); // 2. Circle in the containment hierarchy neg find mustTransitiveContains(source,target); } or { - find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []eRawType reference EGenericType(source,target) + * Matcher for detecting tuples t where []type attribute Function(source,target) */ -private pattern mustInRelationeRawType_reference_EGenericType( +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>eRawType reference EGenericType(source,target) + * Matcher for detecting tuples t where <>type attribute Function(source,target) */ -private pattern mayInRelationeRawType_reference_EGenericType( +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -61406,1054 +45032,987 @@ private pattern mayInRelationeRawType_reference_EGenericType( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationeRawType_reference_EGenericType(problem,interpretation,source,target); + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); } -/** - * Matcher for detecting tuples t where []eLowerBound reference EGenericType(source,target) - */ -private pattern mustInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eLowerBound reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); } -/** - * Matcher for detecting tuples t where <>eLowerBound reference EGenericType(source,target) - */ -private pattern mayInRelationeLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -/** - * Matcher for detecting tuples t where []eTypeParameter reference EGenericType(source,target) - */ -private pattern mustInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eTypeParameter reference EGenericType(source,target) - */ -private pattern mayInRelationeTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfETypeParameter_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []eClassifier reference EGenericType(source,target) - */ -private pattern mustInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>eClassifier reference EGenericType(source,target) - */ -private pattern mayInRelationeClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEGenericType_class(problem,interpretation,source); - find mayInstanceOfEClassifier_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); check(numberOfExistingReferences < 1); -} or { - find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,source,target); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where []eBounds reference ETypeParameter(source,target) - */ -private pattern mustInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eBounds reference ETypeParameter"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -/** - * Matcher for detecting tuples t where <>eBounds reference ETypeParameter(source,target) - */ -private pattern mayInRelationeBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypeParameter_class(problem,interpretation,source); - find mayInstanceOfEGenericType_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []iD attribute EAttribute(source,target) - */ -private pattern mustInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); -} -/** - * Matcher for detecting tuples t where <>iD attribute EAttribute(source,target) - */ -private pattern mayInRelationiD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAttribute_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationiD_attribute_EAttribute(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []source attribute EAnnotation(source,target) - */ -private pattern mustInRelationsource_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -/** - * Matcher for detecting tuples t where <>source attribute EAnnotation(source,target) - */ -private pattern mayInRelationsource_attribute_EAnnotation( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEAnnotation_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationsource_attribute_EAnnotation(problem,interpretation,source,target); -} -/** - * Matcher for detecting tuples t where []abstract attribute EClass(source,target) - */ -private pattern mustInRelationabstract_attribute_EClass( + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>abstract attribute EClass(source,target) - */ -private pattern mayInRelationabstract_attribute_EClass( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationabstract_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationabstract_attribute_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []interface attribute EClass(source,target) - */ -private pattern mustInRelationinterface_attribute_EClass( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>interface attribute EClass(source,target) - */ -private pattern mayInRelationinterface_attribute_EClass( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClass_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinterface_attribute_EClass(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinterface_attribute_EClass(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []instanceClassName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceClassName_attribute_EClassifier( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>instanceClassName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceClassName_attribute_EClassifier( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []instanceTypeName attribute EClassifier(source,target) - */ -private pattern mustInRelationinstanceTypeName_attribute_EClassifier( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>instanceTypeName attribute EClassifier(source,target) - */ -private pattern mayInRelationinstanceTypeName_attribute_EClassifier( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEClassifier_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []serializable attribute EDataType(source,target) - */ -private pattern mustInRelationserializable_attribute_EDataType( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>serializable attribute EDataType(source,target) - */ -private pattern mayInRelationserializable_attribute_EDataType( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEDataType_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationserializable_attribute_EDataType(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []value attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationvalue_attribute_EEnumLiteral( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>value attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationvalue_attribute_EEnumLiteral( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,source,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []literal attribute EEnumLiteral(source,target) - */ -private pattern mustInRelationliteral_attribute_EEnumLiteral( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>literal attribute EEnumLiteral(source,target) - */ -private pattern mayInRelationliteral_attribute_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEEnumLiteral_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []name attribute ENamedElement(source,target) - */ -private pattern mustInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>name attribute ENamedElement(source,target) - */ -private pattern mayInRelationname_attribute_ENamedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfENamedElement_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationname_attribute_ENamedElement(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []nsURI attribute EPackage(source,target) - */ -private pattern mustInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>nsURI attribute EPackage(source,target) - */ -private pattern mayInRelationnsURI_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsURI_attribute_EPackage(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []nsPrefix attribute EPackage(source,target) - */ -private pattern mustInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where <>nsPrefix attribute EPackage(source,target) - */ -private pattern mayInRelationnsPrefix_attribute_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEPackage_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,source,target); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } -/** - * Matcher for detecting tuples t where []containment attribute EReference(source,target) - */ -private pattern mustInRelationcontainment_attribute_EReference( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>containment attribute EReference(source,target) - */ -private pattern mayInRelationcontainment_attribute_EReference( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationcontainment_attribute_EReference(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where []container attribute EReference(source,target) - */ -private pattern mustInRelationcontainer_attribute_EReference( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } -/** - * Matcher for detecting tuples t where <>container attribute EReference(source,target) - */ -private pattern mayInRelationcontainer_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.elements(problem,element); } or { - find mustInRelationcontainer_attribute_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); } -/** - * Matcher for detecting tuples t where []resolveProxies attribute EReference(source,target) - */ -private pattern mustInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); } -/** - * Matcher for detecting tuples t where <>resolveProxies attribute EReference(source,target) - */ -private pattern mayInRelationresolveProxies_attribute_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEReference_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); } or { - find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,source,target); + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); } + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// /** - * Matcher for detecting tuples t where []changeable attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalElement class". */ -private pattern mustInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); } + /** - * Matcher for detecting tuples t where <>changeable attribute EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalElement class". */ -private pattern mayInRelationchangeable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []volatile attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalArchitectureModel class". */ -private pattern mustInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); } + /** - * Matcher for detecting tuples t where <>volatile attribute EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalArchitectureModel class". */ -private pattern mayInRelationvolatile_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []transient attribute EStructuralFeature(source,target) + * An element must be an instance of type "Function class". */ -private pattern mustInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); } + /** - * Matcher for detecting tuples t where <>transient attribute EStructuralFeature(source,target) + * An element may be an instance of type "Function class". */ -private pattern mayInRelationtransient_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []defaultValueLiteral attribute EStructuralFeature(source,target) + * An element must be an instance of type "FAMTerminator class". */ -private pattern mustInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); } + /** - * Matcher for detecting tuples t where <>defaultValueLiteral attribute EStructuralFeature(source,target) + * An element may be an instance of type "FAMTerminator class". */ -private pattern mayInRelationdefaultValueLiteral_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []unsettable attribute EStructuralFeature(source,target) + * An element must be an instance of type "InformationLink class". */ -private pattern mustInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); } + /** - * Matcher for detecting tuples t where <>unsettable attribute EStructuralFeature(source,target) + * An element may be an instance of type "InformationLink class". */ -private pattern mayInRelationunsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []derived attribute EStructuralFeature(source,target) + * An element must be an instance of type "FunctionalInterface class". */ -private pattern mustInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); } + /** - * Matcher for detecting tuples t where <>derived attribute EStructuralFeature(source,target) + * An element may be an instance of type "FunctionalInterface class". */ -private pattern mayInRelationderived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStructuralFeature_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []ordered attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalInput class". */ -private pattern mustInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); } + /** - * Matcher for detecting tuples t where <>ordered attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalInput class". */ -private pattern mayInRelationordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationordered_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []unique attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalOutput class". */ -private pattern mustInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); } + /** - * Matcher for detecting tuples t where <>unique attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalOutput class". */ -private pattern mayInRelationunique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationunique_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []lowerBound attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionalData class". */ -private pattern mustInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); } + /** - * Matcher for detecting tuples t where <>lowerBound attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionalData class". */ -private pattern mayInRelationlowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); } or { - find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,source,target); -} + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } /** - * Matcher for detecting tuples t where []upperBound attribute ETypedElement(source,target) + * An element must be an instance of type "FunctionType enum". */ -private pattern mustInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); } + /** - * Matcher for detecting tuples t where <>upperBound attribute ETypedElement(source,target) + * An element may be an instance of type "FunctionType enum". */ -private pattern mayInRelationupperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - IntegerElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,source,target); -} +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// /** - * Matcher for detecting tuples t where []many attribute ETypedElement(source,target) + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) */ -private pattern mustInRelationmany_attribute_ETypedElement( +private pattern mustInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>many attribute ETypedElement(source,target) + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) */ -private pattern mayInRelationmany_attribute_ETypedElement( +private pattern mayInRelationinterface_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -62462,33 +46021,42 @@ private pattern mayInRelationmany_attribute_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationmany_attribute_ETypedElement(problem,interpretation,source,target); + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []required attribute ETypedElement(source,target) + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) */ -private pattern mustInRelationrequired_attribute_ETypedElement( +private pattern mustInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>required attribute ETypedElement(source,target) + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) */ -private pattern mayInRelationrequired_attribute_ETypedElement( +private pattern mayInRelationmodel_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -62497,33 +46065,33 @@ private pattern mayInRelationrequired_attribute_ETypedElement( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfETypedElement_class(problem,interpretation,source); - BooleanElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); } or { - find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,source,target); + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []key attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) */ -private pattern mustInRelationkey_attribute_EStringToStringMapEntry( +private pattern mustInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>key attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) */ -private pattern mayInRelationkey_attribute_EStringToStringMapEntry( +private pattern mayInRelationparent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { @@ -62532,1724 +46100,948 @@ private pattern mayInRelationkey_attribute_EStringToStringMapEntry( find mayExist(problem, interpretation, source); find mayExist(problem, interpretation, target); // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); // There are "numberOfExistingReferences" currently existing instances of the reference from the source, // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,_); + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,source,target); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); } /** - * Matcher for detecting tuples t where []value attribute EStringToStringMapEntry(source,target) + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) */ -private pattern mustInRelationvalue_attribute_EStringToStringMapEntry( +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); PartialRelationInterpretation.relationlinks(relationIterpretation,link); BinaryElementRelationLink.param1(link,source); BinaryElementRelationLink.param2(link,target); } /** - * Matcher for detecting tuples t where <>value attribute EStringToStringMapEntry(source,target) - */ -private pattern mayInRelationvalue_attribute_EStringToStringMapEntry( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,source); - StringElement(target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); -} or { - find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationdetails_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_EAnnotation(problem,interpretation,source,target); }or - - { find mustInRelationeOperations_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeStructuralFeatures_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EClassifier(problem,interpretation,source,target); }or - - { find mustInRelationeLiterals_reference_EEnum(problem,interpretation,source,target); }or - - { find mustInRelationeAnnotations_reference_EModelElement(problem,interpretation,source,target); }or - - { find mustInRelationeTypeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeParameters_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeGenericExceptions_reference_EOperation(problem,interpretation,source,target); }or - - { find mustInRelationeClassifiers_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeSubpackages_reference_EPackage(problem,interpretation,source,target); }or - - { find mustInRelationeGenericType_reference_ETypedElement(problem,interpretation,source,target); }or - - { find mustInRelationeUpperBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeTypeArguments_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeLowerBound_reference_EGenericType(problem,interpretation,source,target); }or - - { find mustInRelationeBounds_reference_ETypeParameter(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_eAttributeType_reference_EAttribute(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustInstanceOfEAttribute_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eReferenceType_reference_EReference(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustInstanceOfEReference_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeReferenceType_reference_EReference(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_eRawType_reference_EGenericType(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationeRawType_reference_EGenericType(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) -{ - find interpretation(problem,interpretation); - find mustInstanceOfEOperation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEGenericType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAttribute_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEDataType_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClassifier_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEAnnotation_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypeParameter_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEReference_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEEnum_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfETypedElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEClass_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEModelElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfENamedElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -} -pattern createObject_EStringToStringMapEntry_class_by_details_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"details reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayInRelationdetails_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EStringToStringMapEntry_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EStringToStringMapEntry class"); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnum_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnum class"); - find mayInstanceOfEEnum_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class_by_eParameters_reference_EOperation_with_eOperation_reference_EParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eParameters reference EOperation"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eOperation reference EParameter"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayInRelationeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EParameter class"); - find mayInstanceOfEParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericSuperTypes_reference_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericSuperTypes reference EClass"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericSuperTypes_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericExceptions_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericExceptions reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericExceptions_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eGenericType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eGenericType reference ETypedElement"); - find mustInstanceOfETypedElement_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeGenericType_reference_ETypedElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eUpperBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eUpperBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeUpperBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eTypeArguments_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeArguments reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeTypeArguments_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eLowerBound_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLowerBound reference EGenericType"); - find mustInstanceOfEGenericType_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeLowerBound_reference_EGenericType(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class_by_eBounds_reference_ETypeParameter( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eBounds reference ETypeParameter"); - find mustInstanceOfETypeParameter_class(problem,interpretation,container); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayInRelationeBounds_reference_ETypeParameter(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EGenericType_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EGenericType class"); - find mayInstanceOfEGenericType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart_by_eSubpackages_reference_EPackage_with_eSuperPackage_reference_EPackage( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eSubpackages reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eSuperPackage reference EPackage"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayInRelationeSubpackages_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EPackage_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EPackage class UndefinedPart"); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class_by_contents_reference_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference EAnnotation"); - find mustInstanceOfEAnnotation_class(problem,interpretation,container); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_EAnnotation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EObject_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EObject class"); - find mayInstanceOfEObject_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class_by_eLiterals_reference_EEnum_with_eEnum_reference_EEnumLiteral( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eLiterals reference EEnum"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eEnum reference EEnumLiteral"); - find mustInstanceOfEEnum_class(problem,interpretation,container); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayInRelationeLiterals_reference_EEnum(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EEnumLiteral_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EEnumLiteral class"); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EClassifier"); - find mustInstanceOfEClassifier_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EClassifier(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class_by_eTypeParameters_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eTypeParameters reference EOperation"); - find mustInstanceOfEOperation_class(problem,interpretation,container); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayInRelationeTypeParameters_reference_EOperation(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_ETypeParameter_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"ETypeParameter class"); - find mayInstanceOfETypeParameter_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAttribute_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAttribute class"); - find mayInstanceOfEAttribute_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class_by_eOperations_reference_EClass_with_eContainingClass_reference_EOperation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eOperations reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EOperation"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayInRelationeOperations_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EOperation_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EOperation class"); - find mayInstanceOfEOperation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_EAnnotation_class_by_eAnnotations_reference_EModelElement_with_eModelElement_reference_EAnnotation( + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eAnnotations reference EModelElement"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eModelElement reference EAnnotation"); - find mustInstanceOfEModelElement_class(problem,interpretation,container); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayInRelationeAnnotations_reference_EModelElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); } -pattern createObject_EAnnotation_class( +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EAnnotation class"); - find mayInstanceOfEAnnotation_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EReference_class_by_eStructuralFeatures_reference_EClass_with_eContainingClass_reference_EStructuralFeature( +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eStructuralFeatures reference EClass"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"eContainingClass reference EStructuralFeature"); - find mustInstanceOfEClass_class(problem,interpretation,container); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayInRelationeStructuralFeatures_reference_EClass(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); } -pattern createObject_EReference_class( +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EReference class"); - find mayInstanceOfEReference_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EDataType_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); } -pattern createObject_EDataType_class( +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EDataType class"); - find mayInstanceOfEDataType_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern createObject_EClass_class_by_eClassifiers_reference_EPackage_with_ePackage_reference_EClassifier( +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"eClassifiers reference EPackage"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"ePackage reference EClassifier"); - find mustInstanceOfEPackage_class(problem,interpretation,container); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayInRelationeClassifiers_reference_EPackage(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); } -pattern createObject_EClass_class( +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"EClass class"); - find mayInstanceOfEClass_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_EStringToStringMapEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnum_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); -} -pattern refineTypeTo_EParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); -} -pattern refineTypeTo_EGenericType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EPackage_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); -} -pattern refineTypeTo_EObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEModelElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EEnumLiteral_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); -} -pattern refineTypeTo_ETypeParameter_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); -} -pattern refineTypeTo_EAttribute_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); -} -pattern refineTypeTo_EOperation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEStructuralFeature_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); -} -pattern refineTypeTo_EAnnotation_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfENamedElement_class(problem,interpretation,element); -} -pattern refineTypeTo_EReference_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEParameter_class(problem,interpretation,element); - neg find mustInstanceOfEReference_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfEClassifier_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); - neg find mustInstanceOfEOperation_class(problem,interpretation,element); - neg find mustInstanceOfEAttribute_class(problem,interpretation,element); -} -pattern refineTypeTo_EDataType_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEEnum_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); -} -pattern refineTypeTo_EClass_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEAnnotation_class(problem,interpretation,element); - neg find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,element); - neg find mustInstanceOfEGenericType_class(problem,interpretation,element); - neg find mustInstanceOfEObject_class(problem,interpretation,element); - neg find mustInstanceOfEDataType_class(problem,interpretation,element); - neg find mustInstanceOfEEnumLiteral_class(problem,interpretation,element); - neg find mustInstanceOfETypeParameter_class(problem,interpretation,element); - neg find mustInstanceOfETypedElement_class(problem,interpretation,element); - neg find mustInstanceOfEClass_class(problem,interpretation,element); - neg find mustInstanceOfEPackage_class(problem,interpretation,element); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_eAttributeType_reference_EAttribute( +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributeType reference EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - find mustInstanceOfEDataType_class(problem,interpretation,to); - find mayInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); - neg find mustInRelationeAttributeType_reference_EAttribute(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); } -pattern refineRelation_references_reference_EAnnotation( +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"references reference EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - find mustInstanceOfEObject_class(problem,interpretation,to); - find mayInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationreferences_reference_EAnnotation(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeSuperTypes_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern refineRelation_eAllAttributes_reference_EClass( +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllAttributes_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllReferences_reference_EClass( +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllReferences_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); } -pattern refineRelation_eReferences_reference_EClass( +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferences reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeReferences_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeReferences_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAttributes_reference_EClass( +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAttributes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeAttributes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAttributes_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); } -pattern refineRelation_eAllContainments_reference_EClass( +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllContainments reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllContainments_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllOperations_reference_EClass( +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllOperations reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEOperation_class(problem,interpretation,to); - find mayInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllOperations_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); } -pattern refineRelation_eAllStructuralFeatures_reference_EClass( +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllStructuralFeatures reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,to); - find mayInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllStructuralFeatures_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllSuperTypes_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } -pattern refineRelation_eIDAttribute_reference_EClass( +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eIDAttribute reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeIDAttribute_reference_EClass(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eAllGenericSuperTypes_reference_EClass( +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eAllGenericSuperTypes reference EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - find mustInstanceOfEGenericType_class(problem,interpretation,to); - find mayInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); - neg find mustInRelationeAllGenericSuperTypes_reference_EClass(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); } -pattern refineRelation_eExceptions_reference_EOperation( +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eExceptions reference EOperation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEOperation_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); - neg find mustInRelationeExceptions_reference_EOperation(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern refineRelation_eOpposite_reference_EReference( +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eOpposite reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEReference_class(problem,interpretation,to); - find mayInRelationeOpposite_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeOpposite_reference_EReference(problem,interpretation,from,to); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -pattern refineRelation_eReferenceType_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eReferenceType reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEClass_class(problem,interpretation,to); - find mayInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeReferenceType_reference_EReference(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eKeys_reference_EReference( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eKeys reference EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - find mustInstanceOfEAttribute_class(problem,interpretation,to); - find mayInRelationeKeys_reference_EReference(problem,interpretation,from,to); - neg find mustInRelationeKeys_reference_EReference(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eType_reference_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eType reference ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeType_reference_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationeType_reference_ETypedElement(problem,interpretation,from,to); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); } -pattern refineRelation_eRawType_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eRawType reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeRawType_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eTypeParameter_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eTypeParameter reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfETypeParameter_class(problem,interpretation,to); - find mayInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeTypeParameter_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_eClassifier_reference_EGenericType( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"eClassifier reference EGenericType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEGenericType_class(problem,interpretation,from); - find mustInstanceOfEClassifier_class(problem,interpretation,to); - find mayInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); - neg find mustInRelationeClassifier_reference_EGenericType(problem,interpretation,from,to); -} -pattern refineRelation_iD_attribute_EAttribute( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"iD attribute EAttribute"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAttribute_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationiD_attribute_EAttribute(problem,interpretation,from,to); - neg find mustInRelationiD_attribute_EAttribute(problem,interpretation,from,to); -} -pattern refineRelation_source_attribute_EAnnotation( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source attribute EAnnotation"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEAnnotation_class(problem,interpretation,from); - StringElement(to); - find mayInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); - neg find mustInRelationsource_attribute_EAnnotation(problem,interpretation,from,to); -} -pattern refineRelation_abstract_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"abstract attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationabstract_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationabstract_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_interface_attribute_EClass( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface attribute EClass"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClass_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationinterface_attribute_EClass(problem,interpretation,from,to); - neg find mustInRelationinterface_attribute_EClass(problem,interpretation,from,to); -} -pattern refineRelation_instanceClassName_attribute_EClassifier( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceClassName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceClassName_attribute_EClassifier(problem,interpretation,from,to); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); } -pattern refineRelation_instanceTypeName_attribute_EClassifier( +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"instanceTypeName attribute EClassifier"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEClassifier_class(problem,interpretation,from); - StringElement(to); - find mayInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); - neg find mustInRelationinstanceTypeName_attribute_EClassifier(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_serializable_attribute_EDataType( +pattern createObject_FunctionalInterface_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"serializable attribute EDataType"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEDataType_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationserializable_attribute_EDataType(problem,interpretation,from,to); - neg find mustInRelationserializable_attribute_EDataType(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_value_attribute_EEnumLiteral( +pattern createObject_FunctionalArchitectureModel_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EEnumLiteral(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_literal_attribute_EEnumLiteral( +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"literal attribute EEnumLiteral"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEEnumLiteral_class(problem,interpretation,from); - StringElement(to); - find mayInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); - neg find mustInRelationliteral_attribute_EEnumLiteral(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_name_attribute_ENamedElement( +pattern createObject_FunctionalInput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"name attribute ENamedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfENamedElement_class(problem,interpretation,from); - StringElement(to); - find mayInRelationname_attribute_ENamedElement(problem,interpretation,from,to); - neg find mustInRelationname_attribute_ENamedElement(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_nsURI_attribute_EPackage( +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsURI attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsURI_attribute_EPackage(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_nsPrefix_attribute_EPackage( +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"nsPrefix attribute EPackage"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEPackage_class(problem,interpretation,from); - StringElement(to); - find mayInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); - neg find mustInRelationnsPrefix_attribute_EPackage(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_containment_attribute_EReference( +pattern createObject_Function_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"containment attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainment_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainment_attribute_EReference(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_container_attribute_EReference( +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"container attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationcontainer_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationcontainer_attribute_EReference(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_resolveProxies_attribute_EReference( +pattern createObject_FunctionalOutput_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"resolveProxies attribute EReference"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEReference_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); - neg find mustInRelationresolveProxies_attribute_EReference(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_changeable_attribute_EStructuralFeature( +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"changeable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationchangeable_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_volatile_attribute_EStructuralFeature( +pattern createObject_FAMTerminator_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"volatile attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationvolatile_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_transient_attribute_EStructuralFeature( +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"transient attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationtransient_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_defaultValueLiteral_attribute_EStructuralFeature( +pattern createObject_InformationLink_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"defaultValueLiteral attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - StringElement(to); - find mayInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationdefaultValueLiteral_attribute_EStructuralFeature(problem,interpretation,from,to); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -pattern refineRelation_unsettable_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unsettable attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationunsettable_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_derived_attribute_EStructuralFeature( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"derived attribute EStructuralFeature"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfEStructuralFeature_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); - neg find mustInRelationderived_attribute_EStructuralFeature(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_ordered_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"ordered attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationordered_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_unique_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"unique attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationunique_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_lowerBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"lowerBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationlowerBound_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_upperBound_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"upperBound attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - IntegerElement(to); - find mayInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationupperBound_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_many_attribute_ETypedElement( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"many attribute ETypedElement"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationmany_attribute_ETypedElement(problem,interpretation,from,to); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); } -pattern refineRelation_required_attribute_ETypedElement( + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"required attribute ETypedElement"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfETypedElement_class(problem,interpretation,from); - BooleanElement(to); - find mayInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); - neg find mustInRelationrequired_attribute_ETypedElement(problem,interpretation,from,to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); } -pattern refineRelation_key_attribute_EStringToStringMapEntry( +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"key attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationkey_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); } -pattern refineRelation_value_attribute_EStringToStringMapEntry( +pattern refineRelation_type_attribute_Function( problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"value attribute EStringToStringMapEntry"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfEStringToStringMapEntry_class(problem,interpretation,from); - StringElement(to); - find mayInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); - neg find mustInRelationvalue_attribute_EStringToStringMapEntry(problem,interpretation,from,to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem index 169eadb3..f221cce7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem @@ -1,97 +1,82 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + - + - + - - + + - - + + - - + + - + - + + + + + + + + + + + + + + + + + + + - + - + - + - + @@ -105,24 +90,24 @@ - + - + - + - + - + - + @@ -136,24 +121,24 @@ - + - + - + - + - + @@ -167,24 +152,24 @@ - + - + - + - + - + - + @@ -198,55 +183,42 @@ - + - - - - - - - + - - - - - - - + + + + + + - + - - - - - - - + - + - + - + - + - + - + @@ -260,24 +232,24 @@ - + - + - + - + - + - + @@ -291,24 +263,24 @@ - + - + - + - + - + - + @@ -322,1738 +294,287 @@ - - - - - - - - - - - - - - - - - - - + - + - + - + - - - + + + - - - + + + - - + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - - - - - - - - - - - - - - - - - - - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - - - - + - - - - - - - - - + + + + + + + + - - - - - - - + - + - + - + - + - - - + + + - - - + + + - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - + - + + - - - - - - - - - - - + - - - - - - - - - + + - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - + - + - - - + + + - - + + - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - - - + + + - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - + + + - - - + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel index 985e7346..55020b90 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel @@ -1,5 +1,5 @@ - + @@ -76,398 +76,39 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - + + - + - + - + - + - + - + - - + - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -481,17 +122,4 @@ - - - - - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als index 16ff4006..716e4f33 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/problem.als @@ -1,6 +1,6 @@ one sig util'language { - util'root : one type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))), - util'contains : (type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) lone->set (type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) + util'root : one type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))), + util'contains : (type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) lone->set (type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart)))))))))) } abstract sig util'Object { } @@ -12,7 +12,8 @@ sig type'FunctionalArchitectureModel'class in util'Object { rootElements'reference'FunctionalArchitectureModel : set type'FunctionalElement'class } sig type'Function'class in type'FunctionalElement'class { - subElements'reference'Function : set type'FunctionalElement'class + subElements'reference'Function : set type'FunctionalElement'class, + type'attribute'Function : one type'FunctionType'enum } sig type'FAMTerminator'class in util'Object { data'reference'FAMTerminator : lone type'FunctionalData'class @@ -41,17 +42,14 @@ sig type'FunctionalArchitectureModel'class'DefinedPart in type'FunctionalArchite } sig type'FunctionalArchitectureModel'class'UndefinedPart in type'FunctionalArchitectureModel'class { } -one sig element'o'1 in type'FunctionalArchitectureModel'class'DefinedPart { -} one sig element'Root'literal'FunctionType, element'Intermediate'literal'FunctionType, element'Leaf'literal'FunctionType in type'FunctionType'enum { } -pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation [parameter'T: type'FAMTerminator'class, parameter'I: type'InformationLink'class] { - (some variable'Out: type'FunctionalOutput'class { parameter'I in variable'Out.outgoingLinks'reference'FunctionalOutput && parameter'T in variable'Out.terminator'reference'FunctionalData }) || (some variable'In: type'FunctionalInput'class { variable'In in parameter'I.to'reference'InformationLink && (variable'In in type'FunctionalInput'class && parameter'T in variable'In.terminator'reference'FunctionalData) }) +one sig element'o'1 in type'FunctionalArchitectureModel'class'DefinedPart { } -pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [parameter'This: type'Function'class, parameter'Target: type'FunctionType'enum] { - (some variable'Model: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [ variable'Model , parameter'This ] && parameter'Target = element'Root'literal'FunctionType }) || ((all variable'Child: type'Function'class, variable'Model: type'FunctionalArchitectureModel'class { parameter'This in type'Function'class && (! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ variable'Child , parameter'This ]) && (! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [ variable'Model , parameter'This ]) && parameter'Target = element'Leaf'literal'FunctionType)) }) || (some variable'Par: type'Function'class, variable'Child: type'Function'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ parameter'This , variable'Par ] && (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'parent [ variable'Child , parameter'This ] && parameter'Target = element'Intermediate'literal'FunctionType) })) +pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation [parameter'T: type'FAMTerminator'class, parameter'I: type'InformationLink'class] { + (some variable'Out: type'FunctionalOutput'class { parameter'I in variable'Out.outgoingLinks'reference'FunctionalOutput && parameter'T in variable'Out.terminator'reference'FunctionalData }) or (some variable'In: type'FunctionalInput'class { variable'In in parameter'I.to'reference'InformationLink && (variable'In in type'FunctionalInput'class && parameter'T in variable'In.terminator'reference'FunctionalData) }) } pred pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'rootElements [parameter'Model: type'FunctionalArchitectureModel'class, parameter'Root: type'Function'class] { parameter'Root in type'Function'class && parameter'Root in parameter'Model.rootElements'reference'FunctionalArchitectureModel @@ -159,19 +157,19 @@ fact util'containmentDefinition { util'language.util'contains = interface'reference'FunctionalElement + (rootElements'reference'FunctionalArchitectureModel + (subElements'reference'Function + (data'reference'FunctionalInterface + (outgoingLinks'reference'FunctionalOutput + terminator'reference'FunctionalData)))) } fact util'noParentForRoot { - no parent: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->(util'language.util'root) in util'language.util'contains } + no parent: type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->(util'language.util'root) in util'language.util'contains } } fact util'atLeastOneParent { - all child: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { child = util'language.util'root || (some parent: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->child in util'language.util'contains }) } + all child: type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { child = util'language.util'root or (some parent: type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { parent->child in util'language.util'contains }) } } fact util'noCircularContainment { - no circle: type'FunctionalArchitectureModel'class + (type'FunctionalData'class + (type'Function'class + (type'FAMTerminator'class + (type'InformationLink'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalInput'class + (type'FunctionalOutput'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { circle->circle in ^ (util'language.util'contains) } + no circle: type'InformationLink'class + (type'FunctionalOutput'class + (type'FunctionalInput'class + (type'FunctionalData'class + (type'FunctionalArchitectureModel'class + (type'FAMTerminator'class + (type'Function'class + (type'FunctionalInterface'class + (type'FunctionalElement'class + (type'FunctionalArchitectureModel'class'DefinedPart + type'FunctionalArchitectureModel'class'UndefinedPart))))))))) { circle->circle in ^ (util'language.util'contains) } } fact lowerMultiplicity'model'FunctionalElement { all src: type'FunctionalElement'class { some trg'1: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'1 ] } } } fact upperMultiplicity'model'FunctionalElement { - all src: type'FunctionalElement'class, trg'1: type'FunctionalArchitectureModel'class, trg'2: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'1 ] && pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'2 ] => ! (trg'1 != trg'2) } + all src: type'FunctionalElement'class, trg'1: type'FunctionalArchitectureModel'class, trg'2: type'FunctionalArchitectureModel'class { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'1 ] && pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'model [ src , trg'2 ] implies ! (trg'1 != trg'2) } } fact oppositeReference'interface'FunctionalElement { interface'reference'FunctionalElement = ~ element'reference'FunctionalInterface @@ -191,13 +189,7 @@ fact oppositeReference'to'InformationLink { fact oppositeReference'data'FunctionalInterface { data'reference'FunctionalInterface = ~ interface'reference'FunctionalData } -fact lowerMultiplicity'type'Function { - all src: type'Function'class { some trg'1: type'FunctionType'enum { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'1 ] } } -} -fact upperMultiplicity'type'Function { - all src: type'Function'class, trg'1: type'FunctionType'enum, trg'2: type'FunctionType'enum { pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'1 ] && pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'type [ src , trg'2 ] => ! (trg'1 != trg'2) } -} fact errorpattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation { all p0: type'FAMTerminator'class, p1: type'InformationLink'class { ! (pattern'ca'mcgill'ecse'dslreasoner'standalone'test'fam'queries'terminatorAndInformation [ p0 , p1 ]) } } -run { } for exactly 5 util'Object , 31 Int , exactly 0 String \ No newline at end of file +run { } for exactly 10 util'Object , 31 Int , exactly 0 String \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt index 8c87a095..7029fce0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt @@ -1 +1 @@ -Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedModel generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finishedModel generation startedModel generation startedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedModel generation startedProblem is consistent, 3 models are generated!Models: [1.xmi][2.xmi][3.xmi]Visualisations: [1.gml][2.gml][3.gml]Visualisations: [1.png][2.png][3.png]Model generation finished \ No newline at end of file +Model generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated! \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml index 9eac10b7..3e4dddc2 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml @@ -113,8 +113,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -122,7 +122,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -134,8 +134,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -150,7 +148,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -159,7 +157,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -185,8 +183,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -194,7 +192,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -206,6 +204,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -220,7 +219,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -241,8 +240,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -257,8 +256,8 @@ graph id 7 graphics [ - w 112.2 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -266,7 +265,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -278,6 +277,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -292,8 +293,8 @@ graph id 8 graphics [ - w 85.80000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -301,7 +302,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -313,6 +314,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -327,8 +330,8 @@ graph id 9 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -336,7 +339,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -348,6 +351,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -362,64 +366,7 @@ graph id 10 graphics [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 + w 161.70000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -428,7 +375,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -440,7 +387,7 @@ graph LabelGraphics [ text " - FunctionType enum + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -452,11 +399,11 @@ graph node [ - id 1 + id 11 graphics [ - w 297.0 - h 40 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -464,7 +411,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -476,7 +423,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -488,11 +436,11 @@ graph node [ - id 2 + id 12 graphics [ - w 226.60000000000002 - h 40 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -500,7 +448,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -512,7 +460,6 @@ graph LabelGraphics [ text " - FunctionType enum " fontSize 14 fontName "Consolas" @@ -524,11 +471,11 @@ graph node [ - id 3 + id 13 graphics [ - w 361.90000000000003 - h 54 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -536,7 +483,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -548,8 +495,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -561,10 +506,10 @@ graph node [ - id 4 + id 14 graphics [ - w 41.800000000000004 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -573,7 +518,7 @@ graph ] LabelGraphics [ - text "true" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -596,10 +541,10 @@ graph node [ - id 5 + id 15 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -608,7 +553,7 @@ graph ] LabelGraphics [ - text "false" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -628,186 +573,66 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 10 + target 8 + graphics [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 9 + target 7 + graphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 9 + target 11 + graphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ - source 3 + source 5 target 6 graphics [ @@ -817,7 +642,202 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -941,8 +961,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -950,7 +970,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -962,8 +982,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -978,7 +996,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -987,7 +1005,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1013,8 +1031,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1022,7 +1040,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1034,6 +1052,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -1048,7 +1067,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -1069,8 +1088,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1085,8 +1104,8 @@ graph id 7 graphics [ - w 112.2 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1094,7 +1113,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1106,6 +1125,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -1120,8 +1140,8 @@ graph id 8 graphics [ - w 85.80000000000001 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1129,7 +1149,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1141,6 +1161,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -1155,8 +1176,8 @@ graph id 9 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1164,7 +1185,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1176,6 +1197,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1190,65 +1213,8 @@ graph id 10 graphics [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1256,7 +1222,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1268,7 +1234,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1280,10 +1247,10 @@ graph node [ - id 1 + id 11 graphics [ - w 297.0 + w 161.70000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -1292,7 +1259,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1304,7 +1271,7 @@ graph LabelGraphics [ text " - FunctionType enum + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -1316,11 +1283,11 @@ graph node [ - id 2 + id 12 graphics [ - w 226.60000000000002 - h 40 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1328,7 +1295,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1340,7 +1307,6 @@ graph LabelGraphics [ text " - FunctionType enum " fontSize 14 fontName "Consolas" @@ -1352,11 +1318,11 @@ graph node [ - id 3 + id 13 graphics [ - w 361.90000000000003 - h 54 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1364,7 +1330,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1376,8 +1342,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -1389,10 +1353,10 @@ graph node [ - id 4 + id 14 graphics [ - w 41.800000000000004 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -1401,7 +1365,7 @@ graph ] LabelGraphics [ - text "true" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1424,10 +1388,10 @@ graph node [ - id 5 + id 15 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -1436,7 +1400,7 @@ graph ] LabelGraphics [ - text "false" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1456,196 +1420,75 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 11 + target 9 + graphics [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 7 + target 6 + graphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 8 + target 6 + graphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ - source 3 - target 6 + source 7 + target 9 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1653,412 +1496,58 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 8 + target 9 + graphics [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 5 + target 6 + graphics [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics + ] + edge + [ + source 5 + target 9 + graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "model reference FunctionalElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2068,8 +1557,8 @@ graph ] edge [ - source 3 - target 6 + source 5 + target 10 graphics [ fill "#000000" @@ -2078,7 +1567,7 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2088,8 +1577,8 @@ graph ] edge [ - source 6 - target 0 + source 9 + target 7 graphics [ fill "#000000" @@ -2097,7 +1586,7 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2105,4366 +1594,58 @@ graph position "thead" ] ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node + edge + [ + source 9 + target 8 + graphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 6 + target 7 + graphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ source 6 - target 3 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "model reference FunctionalElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6474,8 +1655,8 @@ graph ] edge [ - source 3 - target 6 + source 9 + target 11 graphics [ fill "#000000" @@ -6484,7 +1665,7 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6495,7 +1676,7 @@ graph edge [ source 6 - target 1 + target 5 graphics [ fill "#000000" @@ -6503,7 +1684,7 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6511,267 +1692,54 @@ graph position "thead" ] ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "0" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node + edge + [ + source 9 + target 5 + graphics [ - id 5 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 6 - graphics - [ - w 33.0 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text ""A"" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 7 + id 0 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6779,7 +1747,7 @@ graph ] LabelGraphics [ - text ""B"" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6791,6 +1759,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6802,11 +1771,11 @@ graph node [ - id 8 + id 1 graphics [ - w 94.60000000000001 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6814,7 +1783,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6826,6 +1795,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6837,11 +1807,11 @@ graph node [ - id 9 + id 2 graphics [ - w 68.2 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6849,7 +1819,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6861,6 +1831,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6872,10 +1843,10 @@ graph node [ - id 10 + id 3 graphics [ - w 121.00000000000001 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -6884,7 +1855,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6907,11 +1878,11 @@ graph node [ - id 11 + id 4 graphics [ - w 269.5 - h 124 + w 50.6 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6919,7 +1890,7 @@ graph ] LabelGraphics [ - text "null" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6931,13 +1902,6 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -6949,11 +1913,11 @@ graph node [ - id 12 + id 5 graphics [ - w 269.5 - h 124 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6973,13 +1937,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -6991,11 +1949,11 @@ graph node [ - id 13 + id 6 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7015,12 +1973,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7032,11 +1986,11 @@ graph node [ - id 14 + id 7 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7056,13 +2010,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7074,11 +2023,11 @@ graph node [ - id 15 + id 8 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7098,13 +2047,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7116,11 +2060,11 @@ graph node [ - id 16 + id 9 graphics [ - w 112.2 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7128,7 +2072,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7140,6 +2084,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7151,11 +2096,11 @@ graph node [ - id 17 + id 10 graphics [ - w 85.80000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7163,7 +2108,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7175,6 +2120,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7186,11 +2133,11 @@ graph node [ - id 18 + id 11 graphics [ - w 103.4 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7198,7 +2145,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7210,6 +2157,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7221,10 +2170,10 @@ graph node [ - id 19 + id 12 graphics [ - w 103.4 + w 112.2 h 26 type "rectangle" fill "#FFFFFF" @@ -7233,7 +2182,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7253,224 +2202,115 @@ graph borderDistance 6 ] ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 13 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 11 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 12 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 13 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics + + node [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 12 - target 8 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "instanceClassName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 11 - target 6 + source 9 + target 7 graphics [ fill "#000000" @@ -7478,7 +2318,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7488,16 +2328,17 @@ graph ] edge [ - source 11 - target 10 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7507,16 +2348,17 @@ graph ] edge [ - source 12 - target 8 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7526,16 +2368,17 @@ graph ] edge [ - source 0 - target 10 + source 5 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7545,16 +2388,17 @@ graph ] edge [ - source 12 + source 5 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7564,16 +2408,17 @@ graph ] edge [ - source 11 - target 10 + source 5 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7583,16 +2428,17 @@ graph ] edge [ - source 13 - target 6 + source 7 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7602,8 +2448,8 @@ graph ] edge [ - source 0 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -7611,7 +2457,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7621,8 +2467,8 @@ graph ] edge [ - source 0 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -7630,239 +2476,81 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 8 + target 5 + graphics [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 10 + target 5 + graphics [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 6 + id 0 graphics [ - w 192.50000000000003 - h 54 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7870,7 +2558,7 @@ graph ] LabelGraphics [ - text "null" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7882,8 +2570,7 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7895,11 +2582,11 @@ graph node [ - id 7 + id 1 graphics [ - w 112.2 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7907,7 +2594,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7919,6 +2606,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7930,11 +2618,11 @@ graph node [ - id 8 + id 2 graphics [ - w 85.80000000000001 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7942,7 +2630,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7954,6 +2642,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7965,10 +2654,10 @@ graph node [ - id 9 + id 3 graphics [ - w 103.4 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -7977,7 +2666,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8000,10 +2689,10 @@ graph node [ - id 10 + id 4 graphics [ - w 103.4 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -8012,93 +2701,33 @@ graph ] LabelGraphics [ - text "New Objects" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 fontName "Monospace" autoSizePolicy "node_width" anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 5 graphics [ - w 226.60000000000002 + w 207.9 h 40 type "rectangle" fill "#FFFFFF" @@ -8107,7 +2736,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8119,7 +2748,7 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -8131,11 +2760,11 @@ graph node [ - id 1 + id 6 graphics [ - w 297.0 - h 40 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8143,7 +2772,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8155,7 +2784,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8167,11 +2797,11 @@ graph node [ - id 2 + id 7 graphics [ - w 226.60000000000002 - h 40 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8179,7 +2809,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8191,7 +2821,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8203,10 +2834,10 @@ graph node [ - id 3 + id 8 graphics [ - w 361.90000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -8215,7 +2846,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8227,8 +2858,8 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8240,11 +2871,11 @@ graph node [ - id 4 + id 9 graphics [ - w 41.800000000000004 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8252,7 +2883,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8264,6 +2895,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -8275,11 +2907,11 @@ graph node [ - id 5 + id 10 graphics [ - w 50.6 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8287,7 +2919,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8299,6 +2931,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -8310,11 +2943,11 @@ graph node [ - id 6 + id 11 graphics [ - w 192.50000000000003 - h 54 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8334,8 +2967,7 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -8347,7 +2979,7 @@ graph node [ - id 7 + id 12 graphics [ w 112.2 @@ -8382,7 +3014,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -8417,7 +3049,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -8449,45 +3081,222 @@ graph borderDistance 6 ] ] - - node + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ source 6 - target 3 + target 5 graphics [ fill "#000000" @@ -8495,7 +3304,7 @@ graph ] LabelGraphics [ - text "model reference FunctionalElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8505,17 +3314,16 @@ graph ] edge [ - source 3 - target 6 + source 7 + target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8525,8 +3333,8 @@ graph ] edge [ - source 6 - target 2 + source 8 + target 5 graphics [ fill "#000000" @@ -8534,7 +3342,7 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8550,8 +3358,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8559,7 +3367,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8571,12 +3379,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -8591,8 +3394,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8600,7 +3403,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8612,6 +3415,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -8626,8 +3430,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8635,7 +3439,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8647,6 +3451,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -8661,7 +3466,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -8670,7 +3475,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8696,7 +3501,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -8705,7 +3510,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8731,8 +3536,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8740,7 +3545,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8752,6 +3557,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -8766,8 +3572,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8775,7 +3581,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8787,6 +3593,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -8801,8 +3609,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8810,7 +3618,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8822,6 +3630,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -8836,8 +3645,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8845,7 +3654,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8857,6 +3666,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8871,8 +3682,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8880,7 +3691,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8892,6 +3703,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -8906,8 +3718,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8915,7 +3727,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8927,6 +3739,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8941,8 +3755,8 @@ graph id 11 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8962,12 +3776,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8981,164 +3791,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 68 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 68 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -9172,7 +3824,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -9207,7 +3859,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -9242,7 +3894,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -9266,45 +3918,27 @@ graph LabelGraphics [ text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 15 - target 0 + source 6 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9314,8 +3948,8 @@ graph ] edge [ - source 11 - target 0 + source 6 + target 5 graphics [ fill "#000000" @@ -9323,7 +3957,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9333,16 +3967,17 @@ graph ] edge [ - source 13 - target 0 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "ePackage reference EClassifier" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9352,8 +3987,8 @@ graph ] edge [ - source 14 - target 0 + source 9 + target 8 graphics [ fill "#000000" @@ -9361,7 +3996,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9371,8 +4006,8 @@ graph ] edge [ - source 0 - target 12 + source 7 + target 8 graphics [ fill "#000000" @@ -9381,7 +4016,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9391,8 +4026,8 @@ graph ] edge [ - source 0 - target 15 + source 7 + target 10 graphics [ fill "#000000" @@ -9401,7 +4036,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9411,7 +4046,7 @@ graph ] edge [ - source 0 + source 7 target 11 graphics [ @@ -9421,7 +4056,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9431,17 +4066,16 @@ graph ] edge [ - source 0 - target 13 + source 7 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9451,8 +4085,8 @@ graph ] edge [ - source 0 - target 14 + source 8 + target 9 graphics [ fill "#000000" @@ -9461,7 +4095,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9471,7 +4105,7 @@ graph ] edge [ - source 12 + source 8 target 7 graphics [ @@ -9480,45 +4114,7 @@ graph ] LabelGraphics [ - text "source attribute EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceTypeName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9528,8 +4124,8 @@ graph ] edge [ - source 0 - target 10 + source 10 + target 7 graphics [ fill "#000000" @@ -9537,7 +4133,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9548,45 +4144,7 @@ graph edge [ source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 + target 7 graphics [ fill "#000000" @@ -9594,7 +4152,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9604,8 +4162,8 @@ graph ] edge [ - source 0 - target 8 + source 6 + target 2 graphics [ fill "#000000" @@ -9613,7 +4171,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "type attribute Function" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9629,8 +4187,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9638,7 +4196,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9650,12 +4208,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9670,8 +4223,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9679,7 +4232,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9691,6 +4244,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9705,148 +4259,8 @@ graph id 2 graphics [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "0" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9854,7 +4268,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9866,6 +4280,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9877,10 +4292,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -9889,7 +4304,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9912,10 +4327,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -9924,7 +4339,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9947,11 +4362,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9959,7 +4374,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9971,6 +4386,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -9982,11 +4398,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9994,7 +4410,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10006,6 +4422,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -10017,11 +4435,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 124 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10041,13 +4459,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -10059,11 +4471,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10083,13 +4495,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10101,11 +4508,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10125,11 +4532,7 @@ graph LabelGraphics [ text " - EEnumLiteral class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -10141,11 +4544,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 68 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10165,9 +4568,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10179,11 +4581,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 96 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10203,11 +4605,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -10219,7 +4617,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -10254,7 +4652,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -10289,7 +4687,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -10324,7 +4722,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -10358,124 +4756,8 @@ graph ] edge [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eTypeParameters reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 13 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eLiterals reference EEnum" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eEnum reference EEnumLiteral" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 14 + source 6 + target 7 graphics [ fill "#000000" @@ -10484,7 +4766,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10494,17 +4776,16 @@ graph ] edge [ - source 0 - target 11 + source 6 + target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10514,8 +4795,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 6 graphics [ fill "#000000" @@ -10524,7 +4805,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10534,7 +4815,7 @@ graph ] edge [ - source 11 + source 9 target 8 graphics [ @@ -10543,7 +4824,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10554,7 +4835,7 @@ graph edge [ source 11 - target 9 + target 10 graphics [ fill "#000000" @@ -10562,7 +4843,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10572,8 +4853,8 @@ graph ] edge [ - source 12 - target 9 + source 11 + target 8 graphics [ fill "#000000" @@ -10581,7 +4862,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10591,16 +4872,17 @@ graph ] edge [ - source 11 - target 2 + source 7 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "serializable attribute EDataType" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10610,16 +4892,17 @@ graph ] edge [ - source 12 - target 2 + source 7 + target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "serializable attribute EDataType" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10629,8 +4912,8 @@ graph ] edge [ - source 13 - target 9 + source 7 + target 6 graphics [ fill "#000000" @@ -10638,7 +4921,7 @@ graph ] LabelGraphics [ - text "literal attribute EEnumLiteral" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10648,8 +4931,8 @@ graph ] edge [ - source 0 - target 10 + source 8 + target 11 graphics [ fill "#000000" @@ -10657,7 +4940,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10667,16 +4950,17 @@ graph ] edge [ - source 12 - target 10 + source 10 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10686,16 +4970,17 @@ graph ] edge [ - source 0 + source 8 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10705,8 +4990,8 @@ graph ] edge [ - source 0 - target 8 + source 8 + target 7 graphics [ fill "#000000" @@ -10714,170 +4999,62 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 10 + target 7 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10885,7 +5062,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10897,6 +5074,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10908,11 +5086,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10920,7 +5098,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10932,6 +5110,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10943,11 +5122,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10955,7 +5134,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10967,6 +5146,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10978,10 +5158,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -10990,7 +5170,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11013,10 +5193,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -11025,7 +5205,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11048,11 +5228,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11060,7 +5240,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11072,6 +5252,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -11083,11 +5264,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11095,7 +5276,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11107,6 +5288,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -11118,11 +5301,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11142,12 +5325,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -11159,11 +5337,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11183,12 +5361,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -11200,11 +5374,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11224,13 +5398,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -11242,11 +5411,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11266,11 +5435,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -11282,11 +5447,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 68 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11306,9 +5471,7 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -11320,7 +5483,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -11355,7 +5518,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -11390,7 +5553,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -11425,7 +5588,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -11442,102 +5605,25 @@ graph fill "#FFFFFF" fontSize 16 fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 15 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eTypeParameters reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 0 - target 15 + source 6 + target 7 graphics [ fill "#000000" @@ -11546,7 +5632,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11556,17 +5642,16 @@ graph ] edge [ - source 0 - target 11 + source 6 + target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11576,8 +5661,8 @@ graph ] edge [ - source 0 - target 13 + source 5 + target 6 graphics [ fill "#000000" @@ -11586,7 +5671,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11596,17 +5681,16 @@ graph ] edge [ - source 0 - target 12 + source 10 + target 9 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11616,8 +5700,8 @@ graph ] edge [ - source 12 - target 0 + source 11 + target 8 graphics [ fill "#000000" @@ -11625,7 +5709,7 @@ graph ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11635,16 +5719,17 @@ graph ] edge [ - source 11 - target 6 + source 7 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11654,16 +5739,17 @@ graph ] edge [ - source 11 - target 1 + source 7 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "serializable attribute EDataType" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11673,8 +5759,8 @@ graph ] edge [ - source 0 - target 10 + source 7 + target 6 graphics [ fill "#000000" @@ -11682,7 +5768,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11692,16 +5778,17 @@ graph ] edge [ - source 12 - target 6 + source 9 + target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11711,16 +5798,17 @@ graph ] edge [ - source 0 - target 9 + source 8 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11730,8 +5818,8 @@ graph ] edge [ - source 12 - target 10 + source 8 + target 7 graphics [ fill "#000000" @@ -11739,7 +5827,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11749,8 +5837,8 @@ graph ] edge [ - source 0 - target 8 + source 9 + target 7 graphics [ fill "#000000" @@ -11758,7 +5846,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11768,8 +5856,8 @@ graph ] edge [ - source 12 - target 8 + source 6 + target 0 graphics [ fill "#000000" @@ -11777,7 +5865,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "type attribute Function" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11793,8 +5881,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11802,7 +5890,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11814,12 +5902,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -11834,8 +5917,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11843,7 +5926,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11855,6 +5938,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -11869,8 +5953,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11878,7 +5962,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11890,6 +5974,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -11904,7 +5989,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -11913,7 +5998,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11939,7 +6024,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -11948,7 +6033,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11974,8 +6059,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11983,7 +6068,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -11995,6 +6080,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -12009,8 +6095,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12018,7 +6104,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -12030,6 +6116,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -12044,8 +6132,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12053,7 +6141,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -12065,6 +6153,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -12079,8 +6169,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12088,7 +6178,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -12100,6 +6190,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -12114,8 +6205,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12123,7 +6214,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -12135,6 +6226,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -12149,8 +6242,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12158,7 +6251,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -12170,6 +6263,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -12184,8 +6278,8 @@ graph id 11 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12205,12 +6299,7 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -12224,169 +6313,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 96 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -12420,7 +6346,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -12455,7 +6381,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -12490,7 +6416,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -12513,38 +6439,19 @@ graph ] LabelGraphics [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 15 - target 13 + source 8 + target 7 graphics [ fill "#000000" @@ -12552,7 +6459,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12562,17 +6469,16 @@ graph ] edge [ - source 11 - target 14 + source 10 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eTypeParameters reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12582,17 +6488,16 @@ graph ] edge [ - source 0 - target 11 + source 11 + target 9 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12602,8 +6507,8 @@ graph ] edge [ - source 13 - target 15 + source 5 + target 6 graphics [ fill "#000000" @@ -12612,7 +6517,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12622,8 +6527,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 7 graphics [ fill "#000000" @@ -12632,7 +6537,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12642,8 +6547,8 @@ graph ] edge [ - source 12 - target 13 + source 5 + target 9 graphics [ fill "#000000" @@ -12652,83 +6557,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 12 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "abstract attribute EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "interface attribute EClass" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12738,16 +6567,17 @@ graph ] edge [ - source 11 + source 7 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12757,35 +6587,17 @@ graph ] edge [ - source 0 + source 6 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12795,16 +6607,17 @@ graph ] edge [ - source 0 - target 9 + source 9 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12814,8 +6627,8 @@ graph ] edge [ - source 13 - target 7 + source 6 + target 5 graphics [ fill "#000000" @@ -12823,7 +6636,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12833,8 +6646,8 @@ graph ] edge [ - source 12 - target 7 + source 7 + target 5 graphics [ fill "#000000" @@ -12842,7 +6655,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12852,8 +6665,8 @@ graph ] edge [ - source 0 - target 8 + source 9 + target 5 graphics [ fill "#000000" @@ -12861,7 +6674,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -12985,8 +6798,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -12994,7 +6807,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13006,8 +6819,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -13022,7 +6833,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -13031,7 +6842,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13057,8 +6868,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13066,7 +6877,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13078,6 +6889,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -13092,7 +6904,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -13113,8 +6925,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13129,8 +6941,8 @@ graph id 7 graphics [ - w 112.2 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13138,7 +6950,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13150,6 +6962,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13164,8 +6978,8 @@ graph id 8 graphics [ - w 85.80000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13173,7 +6987,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13185,6 +6999,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13199,8 +7015,8 @@ graph id 9 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13208,7 +7024,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13220,6 +7036,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13234,8 +7052,8 @@ graph id 10 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13243,7 +7061,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13255,6 +7073,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -13263,74 +7082,86 @@ graph borderDistance 6 ] ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 0 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 13 graphics [ - w 254.10000000000002 - h 110 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13338,7 +7169,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13350,12 +7181,6 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class " fontSize 14 fontName "Consolas" @@ -13367,10 +7192,10 @@ graph node [ - id 1 + id 14 graphics [ - w 41.800000000000004 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -13379,7 +7204,7 @@ graph ] LabelGraphics [ - text "true" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13402,10 +7227,10 @@ graph node [ - id 2 + id 15 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -13414,7 +7239,7 @@ graph ] LabelGraphics [ - text "false" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13434,49 +7259,288 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13484,7 +7548,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13496,6 +7560,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -13507,11 +7572,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13519,7 +7584,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13531,6 +7596,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -13542,11 +7608,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13554,7 +7620,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13566,6 +7632,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -13577,10 +7644,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -13589,7 +7656,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13612,10 +7679,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -13624,7 +7691,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13647,11 +7714,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13659,7 +7726,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13671,6 +7738,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -13682,11 +7750,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13694,7 +7762,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -13706,6 +7774,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13717,11 +7787,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13741,12 +7811,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13758,11 +7824,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13782,12 +7848,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13799,11 +7861,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13823,12 +7885,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EOperation class - ETypedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -13840,11 +7897,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 68 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13864,9 +7921,7 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -13878,11 +7933,11 @@ graph node [ - id 15 + id 11 graphics [ - w 238.70000000000002 - h 40 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -13902,7 +7957,8 @@ graph LabelGraphics [ text " - EStringToStringMapEntry class + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -13914,7 +7970,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -13949,7 +8005,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -13984,7 +8040,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -14019,7 +8075,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -14053,28 +8109,8 @@ graph ] edge [ - source 14 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "details reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 + source 9 + target 6 graphics [ fill "#000000" @@ -14082,7 +8118,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14092,8 +8128,8 @@ graph ] edge [ - source 11 - target 11 + source 10 + target 7 graphics [ fill "#000000" @@ -14101,7 +8137,7 @@ graph ] LabelGraphics [ - text "eSuperTypes reference EClass" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14111,8 +8147,8 @@ graph ] edge [ - source 11 - target 13 + source 5 + target 6 graphics [ fill "#000000" @@ -14121,45 +8157,7 @@ graph ] LabelGraphics [ - text "eOperations reference EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eAllSuperTypes reference EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14169,8 +8167,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 7 graphics [ fill "#000000" @@ -14179,7 +8177,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14189,16 +8187,17 @@ graph ] edge [ - source 13 - target 11 + source 5 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eContainingClass reference EOperation" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14208,7 +8207,7 @@ graph ] edge [ - source 0 + source 5 target 11 graphics [ @@ -14218,7 +8217,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14228,8 +8227,8 @@ graph ] edge [ - source 0 - target 12 + source 6 + target 9 graphics [ fill "#000000" @@ -14238,45 +8237,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14286,54 +8247,17 @@ graph ] edge [ - source 0 + source 7 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14343,8 +8267,8 @@ graph ] edge [ - source 12 - target 8 + source 6 + target 5 graphics [ fill "#000000" @@ -14352,7 +8276,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14362,8 +8286,8 @@ graph ] edge [ - source 0 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -14371,7 +8295,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14381,8 +8305,8 @@ graph ] edge [ - source 13 - target 1 + source 8 + target 5 graphics [ fill "#000000" @@ -14390,7 +8314,7 @@ graph ] LabelGraphics [ - text "unique attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -14400,8 +8324,8 @@ graph ] edge [ - source 13 - target 4 + source 11 + target 5 graphics [ fill "#000000" @@ -14409,7 +8333,7 @@ graph ] LabelGraphics [ - text "upperBound attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png index 0ea0ef1b..e33711c3 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi index cb79481b..fa323f3d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi @@ -1,10 +1,11 @@ - - -
- - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml index 77ffa87d..383a7f99 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml @@ -113,8 +113,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -122,7 +122,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -134,8 +134,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -150,7 +148,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -159,7 +157,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -185,8 +183,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -194,7 +192,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -206,6 +204,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -220,7 +219,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -241,8 +240,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -257,8 +256,8 @@ graph id 7 graphics [ - w 112.2 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -266,7 +265,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -278,6 +277,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -292,8 +293,8 @@ graph id 8 graphics [ - w 85.80000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -301,7 +302,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -313,6 +314,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -327,8 +330,8 @@ graph id 9 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -336,7 +339,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -348,6 +351,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -362,102 +366,7 @@ graph id 10 graphics [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 + w 177.10000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -466,7 +375,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -478,7 +387,7 @@ graph LabelGraphics [ text " - FunctionType enum + InformationLink class " fontSize 14 fontName "Consolas" @@ -490,10 +399,10 @@ graph node [ - id 1 + id 11 graphics [ - w 297.0 + w 161.70000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -502,7 +411,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -514,7 +423,7 @@ graph LabelGraphics [ text " - FunctionType enum + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -526,11 +435,11 @@ graph node [ - id 2 + id 12 graphics [ - w 226.60000000000002 - h 40 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -538,7 +447,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -550,7 +459,6 @@ graph LabelGraphics [ text " - FunctionType enum " fontSize 14 fontName "Consolas" @@ -562,11 +470,11 @@ graph node [ - id 3 + id 13 graphics [ - w 361.90000000000003 - h 54 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -574,7 +482,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -586,8 +494,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -599,10 +505,10 @@ graph node [ - id 4 + id 14 graphics [ - w 41.800000000000004 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -611,7 +517,7 @@ graph ] LabelGraphics [ - text "true" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -634,10 +540,10 @@ graph node [ - id 5 + id 15 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -646,7 +552,7 @@ graph ] LabelGraphics [ - text "false" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -666,187 +572,67 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 11 + target 6 + graphics [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 9 + target 7 + graphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 10 + target 7 + graphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ - source 6 - target 3 + source 9 + target 8 graphics [ fill "#000000" @@ -854,7 +640,7 @@ graph ] LabelGraphics [ - text "model reference FunctionalElement" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -864,17 +650,16 @@ graph ] edge [ - source 3 - target 6 + source 10 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -884,16 +669,17 @@ graph ] edge [ - source 6 - target 2 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "type attribute Function" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -901,1768 +687,137 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 5 + target 7 + graphics [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 5 + target 8 + graphics [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" + text "data reference FunctionalInterface" fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 8 + target 9 + graphics [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 8 + target 10 + graphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 7 + target 9 + graphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ source 6 - target 3 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "model reference FunctionalElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2672,17 +827,16 @@ graph ] edge [ - source 3 - target 6 + source 6 + target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2692,8 +846,8 @@ graph ] edge [ - source 6 - target 2 + source 7 + target 5 graphics [ fill "#000000" @@ -2701,7 +855,26 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2824,43 +997,6 @@ graph [ id 3 graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics [ w 41.800000000000004 h 26 @@ -2894,7 +1030,7 @@ graph node [ - id 5 + id 4 graphics [ w 50.6 @@ -2929,11 +1065,11 @@ graph node [ - id 6 + id 5 graphics [ - w 192.50000000000003 - h 54 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2953,113 +1089,7 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -3071,11 +1101,11 @@ graph node [ - id 10 + id 6 graphics [ - w 103.4 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3083,93 +1113,35 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 fontName "Monospace" autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 7 graphics [ - w 226.60000000000002 + w 177.10000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -3178,7 +1150,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3190,7 +1162,7 @@ graph LabelGraphics [ text " - FunctionType enum + InformationLink class " fontSize 14 fontName "Consolas" @@ -3202,10 +1174,10 @@ graph node [ - id 1 + id 8 graphics [ - w 297.0 + w 177.10000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -3214,7 +1186,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3226,7 +1198,7 @@ graph LabelGraphics [ text " - FunctionType enum + InformationLink class " fontSize 14 fontName "Consolas" @@ -3238,11 +1210,11 @@ graph node [ - id 2 + id 9 graphics [ - w 226.60000000000002 - h 40 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3250,7 +1222,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3262,7 +1234,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -3274,10 +1247,10 @@ graph node [ - id 3 + id 10 graphics [ - w 361.90000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -3286,7 +1259,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3298,8 +1271,8 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -3311,10 +1284,46 @@ graph node [ - id 4 + id 11 graphics [ - w 41.800000000000004 + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 h 26 type "rectangle" fill "#FFFFFF" @@ -3323,7 +1332,7 @@ graph ] LabelGraphics [ - text "true" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3346,10 +1355,10 @@ graph node [ - id 5 + id 13 graphics [ - w 50.6 + w 85.80000000000001 h 26 type "rectangle" fill "#FFFFFF" @@ -3358,7 +1367,7 @@ graph ] LabelGraphics [ - text "false" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3381,11 +1390,11 @@ graph node [ - id 6 + id 14 graphics [ - w 192.50000000000003 - h 54 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3393,7 +1402,7 @@ graph ] LabelGraphics [ - text "null" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3405,8 +1414,6 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class " fontSize 14 fontName "Consolas" @@ -3418,10 +1425,10 @@ graph node [ - id 7 + id 15 graphics [ - w 112.2 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -3430,7 +1437,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3450,123 +1457,232 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 6 + target 7 + graphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ source 6 - target 3 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "model reference FunctionalElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3576,8 +1692,8 @@ graph ] edge [ - source 3 - target 6 + source 6 + target 11 graphics [ fill "#000000" @@ -3586,7 +1702,7 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3597,7 +1713,7 @@ graph edge [ source 6 - target 0 + target 5 graphics [ fill "#000000" @@ -3605,7 +1721,7 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3613,162 +1729,54 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 9 + target 5 + graphics [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 10 + target 5 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3776,7 +1784,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3788,6 +1796,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3799,11 +1808,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3811,7 +1820,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3823,6 +1832,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3834,11 +1844,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3846,7 +1856,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3858,6 +1868,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3869,10 +1880,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -3881,7 +1892,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3904,10 +1915,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -3916,7 +1927,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3939,11 +1950,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3951,7 +1962,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3963,6 +1974,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -3974,11 +1986,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3986,7 +1998,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3998,6 +2010,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4009,11 +2023,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4033,13 +2047,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4051,11 +2060,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4075,13 +2084,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4093,11 +2097,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4117,12 +2121,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -4134,11 +2133,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4158,13 +2157,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4176,11 +2170,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4200,13 +2194,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -4218,7 +2206,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -4253,7 +2241,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -4288,7 +2276,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -4323,7 +2311,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -4341,189 +2329,32 @@ graph fontSize 16 fontName "Monospace" autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 13 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 11 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 12 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 0 - target 13 + source 9 + target 7 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4533,8 +2364,8 @@ graph ] edge [ - source 13 - target 0 + source 11 + target 8 graphics [ fill "#000000" @@ -4542,7 +2373,7 @@ graph ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4552,8 +2383,8 @@ graph ] edge [ - source 12 - target 8 + source 11 + target 7 graphics [ fill "#000000" @@ -4561,7 +2392,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4571,16 +2402,17 @@ graph ] edge [ - source 11 + source 5 target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4590,16 +2422,17 @@ graph ] edge [ - source 11 - target 10 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4609,16 +2442,17 @@ graph ] edge [ - source 12 + source 5 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4628,16 +2462,17 @@ graph ] edge [ - source 0 + source 5 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4647,8 +2482,8 @@ graph ] edge [ - source 12 - target 10 + source 7 + target 11 graphics [ fill "#000000" @@ -4656,7 +2491,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4666,16 +2501,17 @@ graph ] edge [ - source 11 - target 10 + source 8 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4685,16 +2521,17 @@ graph ] edge [ - source 13 - target 6 + source 7 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4704,8 +2541,8 @@ graph ] edge [ - source 0 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -4713,7 +2550,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4723,8 +2560,8 @@ graph ] edge [ - source 13 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -4732,7 +2569,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4742,8 +2579,8 @@ graph ] edge [ - source 0 - target 8 + source 8 + target 5 graphics [ fill "#000000" @@ -4751,7 +2588,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4759,231 +2596,35 @@ graph position "thead" ] ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Root literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 297.0 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Intermediate literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 226.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "Leaf literal FunctionType" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionType enum - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 361.90000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 6 + id 0 graphics [ - w 192.50000000000003 - h 54 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4991,7 +2632,7 @@ graph ] LabelGraphics [ - text "null" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5003,8 +2644,7 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5016,11 +2656,11 @@ graph node [ - id 7 + id 1 graphics [ - w 112.2 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5028,7 +2668,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5040,6 +2680,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5051,11 +2692,11 @@ graph node [ - id 8 + id 2 graphics [ - w 85.80000000000001 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5063,7 +2704,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5075,6 +2716,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5086,10 +2728,10 @@ graph node [ - id 9 + id 3 graphics [ - w 103.4 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -5098,7 +2740,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5121,10 +2763,10 @@ graph node [ - id 10 + id 4 graphics [ - w 103.4 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -5133,7 +2775,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5153,73 +2795,13 @@ graph borderDistance 6 ] ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 5 graphics [ - w 226.60000000000002 + w 207.9 h 40 type "rectangle" fill "#FFFFFF" @@ -5228,7 +2810,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5240,7 +2822,7 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -5252,11 +2834,11 @@ graph node [ - id 1 + id 6 graphics [ - w 297.0 - h 40 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5264,7 +2846,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5276,7 +2858,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5288,11 +2871,11 @@ graph node [ - id 2 + id 7 graphics [ - w 226.60000000000002 - h 40 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5300,7 +2883,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5312,7 +2895,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5324,10 +2908,10 @@ graph node [ - id 3 + id 8 graphics [ - w 361.90000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -5336,7 +2920,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5348,8 +2932,8 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5361,11 +2945,11 @@ graph node [ - id 4 + id 9 graphics [ - w 41.800000000000004 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5373,7 +2957,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5385,6 +2969,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -5396,11 +2981,11 @@ graph node [ - id 5 + id 10 graphics [ - w 50.6 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5408,7 +2993,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5420,6 +3005,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -5431,10 +3017,10 @@ graph node [ - id 6 + id 11 graphics [ - w 192.50000000000003 + w 177.10000000000002 h 54 type "rectangle" fill "#FFFFFF" @@ -5455,8 +3041,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5468,7 +3054,7 @@ graph node [ - id 7 + id 12 graphics [ w 112.2 @@ -5503,7 +3089,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -5538,7 +3124,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -5573,7 +3159,7 @@ graph node [ - id 10 + id 15 graphics [ w 103.4 @@ -5606,17 +3192,136 @@ graph ] ] edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge [ source 6 - target 3 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "model reference FunctionalElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5626,8 +3331,8 @@ graph ] edge [ - source 3 - target 6 + source 7 + target 10 graphics [ fill "#000000" @@ -5636,7 +3341,7 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5647,7 +3352,7 @@ graph edge [ source 6 - target 1 + target 5 graphics [ fill "#000000" @@ -5655,7 +3360,64 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5671,8 +3433,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5680,7 +3442,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5692,12 +3454,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5712,8 +3469,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5721,7 +3478,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5733,6 +3490,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5747,8 +3505,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5756,7 +3514,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5768,6 +3526,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5782,7 +3541,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -5791,7 +3550,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5817,7 +3576,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -5826,7 +3585,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5852,8 +3611,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5861,7 +3620,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5873,6 +3632,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -5887,8 +3647,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5896,7 +3656,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5908,6 +3668,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -5922,148 +3684,8 @@ graph id 7 graphics [ - w 33.0 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text ""B"" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 8 - graphics - [ - w 94.60000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text ""nsPrefix"" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 9 - graphics - [ - w 68.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text ""nsUri"" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 10 - graphics - [ - w 121.00000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text ""packageName"" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 11 - graphics - [ - w 269.5 - h 110 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6083,12 +3705,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -6100,11 +3717,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 68 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6124,9 +3741,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6138,11 +3754,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6162,12 +3778,7 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -6179,11 +3790,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6203,12 +3814,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6220,11 +3827,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 68 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6244,9 +3851,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6258,7 +3864,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -6293,7 +3899,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -6328,7 +3934,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -6363,7 +3969,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -6397,35 +4003,17 @@ graph ] edge [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 0 + source 6 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6435,8 +4023,8 @@ graph ] edge [ - source 11 - target 0 + source 6 + target 5 graphics [ fill "#000000" @@ -6444,7 +4032,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6454,16 +4042,17 @@ graph ] edge [ - source 13 - target 0 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "ePackage reference EClassifier" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6473,8 +4062,8 @@ graph ] edge [ - source 14 - target 0 + source 9 + target 8 graphics [ fill "#000000" @@ -6482,7 +4071,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6492,8 +4081,8 @@ graph ] edge [ - source 0 - target 12 + source 7 + target 8 graphics [ fill "#000000" @@ -6502,7 +4091,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6512,8 +4101,8 @@ graph ] edge [ - source 0 - target 15 + source 7 + target 10 graphics [ fill "#000000" @@ -6522,7 +4111,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6532,7 +4121,7 @@ graph ] edge [ - source 0 + source 7 target 11 graphics [ @@ -6542,7 +4131,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6552,17 +4141,16 @@ graph ] edge [ - source 0 - target 13 + source 7 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6572,8 +4160,8 @@ graph ] edge [ - source 0 - target 14 + source 8 + target 9 graphics [ fill "#000000" @@ -6582,7 +4170,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6592,7 +4180,7 @@ graph ] edge [ - source 12 + source 8 target 7 graphics [ @@ -6601,26 +4189,7 @@ graph ] LabelGraphics [ - text "source attribute EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6630,27 +4199,8 @@ graph ] edge [ - source 11 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceTypeName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 10 + source 10 + target 7 graphics [ fill "#000000" @@ -6658,7 +4208,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6669,64 +4219,7 @@ graph edge [ source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 + target 7 graphics [ fill "#000000" @@ -6734,7 +4227,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6744,179 +4237,33 @@ graph ] edge [ - source 0 - target 8 + source 6 + target 2 graphics [ fill "#000000" targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node + ] + LabelGraphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6924,7 +4271,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6936,6 +4283,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6947,11 +4295,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6959,7 +4307,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6971,6 +4319,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6982,11 +4331,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6994,7 +4343,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7006,6 +4355,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7017,10 +4367,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -7029,7 +4379,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7052,10 +4402,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -7064,7 +4414,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7087,11 +4437,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7099,7 +4449,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7111,6 +4461,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -7122,11 +4473,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7134,7 +4485,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7146,6 +4497,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -7157,11 +4510,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 124 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7181,13 +4534,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -7199,11 +4546,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7223,13 +4570,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7241,11 +4583,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7265,11 +4607,7 @@ graph LabelGraphics [ text " - EEnumLiteral class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7281,11 +4619,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 68 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7305,9 +4643,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7319,11 +4656,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7343,11 +4680,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7359,7 +4692,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -7394,7 +4727,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -7429,7 +4762,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -7442,180 +4775,64 @@ graph LabelGraphics [ text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 19 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eTypeParameters reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 13 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eLiterals reference EEnum" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "eEnum reference EEnumLiteral" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 0 - target 14 + source 6 + target 7 graphics [ fill "#000000" @@ -7624,7 +4841,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7634,17 +4851,16 @@ graph ] edge [ - source 0 - target 11 + source 6 + target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7654,8 +4870,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 6 graphics [ fill "#000000" @@ -7664,26 +4880,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source attribute EAnnotation" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7693,7 +4890,7 @@ graph ] edge [ - source 11 + source 9 target 8 graphics [ @@ -7702,7 +4899,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7713,7 +4910,7 @@ graph edge [ source 11 - target 9 + target 10 graphics [ fill "#000000" @@ -7721,7 +4918,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7731,16 +4928,17 @@ graph ] edge [ - source 12 - target 9 + source 7 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7750,16 +4948,17 @@ graph ] edge [ - source 11 - target 2 + source 7 + target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "serializable attribute EDataType" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7769,8 +4968,8 @@ graph ] edge [ - source 12 - target 2 + source 7 + target 6 graphics [ fill "#000000" @@ -7778,7 +4977,7 @@ graph ] LabelGraphics [ - text "serializable attribute EDataType" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7788,16 +4987,17 @@ graph ] edge [ - source 13 + source 8 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "literal attribute EEnumLiteral" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7807,16 +5007,17 @@ graph ] edge [ - source 0 - target 10 + source 10 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7826,8 +5027,8 @@ graph ] edge [ - source 12 - target 10 + source 8 + target 7 graphics [ fill "#000000" @@ -7835,7 +5036,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7845,8 +5046,8 @@ graph ] edge [ - source 0 - target 9 + source 10 + target 7 graphics [ fill "#000000" @@ -7854,7 +5055,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7864,8 +5065,8 @@ graph ] edge [ - source 0 - target 8 + source 6 + target 0 graphics [ fill "#000000" @@ -7873,7 +5074,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "type attribute Function" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7889,8 +5090,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7898,7 +5099,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7910,12 +5111,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7930,8 +5126,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7939,7 +5135,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -7951,6 +5147,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -7965,148 +5162,8 @@ graph id 2 graphics [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 4 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "0" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 5 - graphics - [ - w 15.400000000000002 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 6 - graphics - [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8114,7 +5171,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8126,6 +5183,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -8137,10 +5195,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -8149,7 +5207,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8172,10 +5230,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -8184,7 +5242,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8207,11 +5265,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8219,7 +5277,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8231,6 +5289,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -8242,11 +5301,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8254,7 +5313,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -8266,6 +5325,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -8277,11 +5338,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8301,12 +5362,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -8318,11 +5374,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8342,12 +5398,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8359,11 +5411,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8383,13 +5435,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8401,11 +5448,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8425,11 +5472,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -8441,11 +5484,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 68 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -8465,9 +5508,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -8479,7 +5521,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -8514,7 +5556,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -8549,7 +5591,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -8584,7 +5626,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -8618,35 +5660,17 @@ graph ] edge [ - source 15 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 + source 6 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "ePackage reference EClassifier" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8656,8 +5680,8 @@ graph ] edge [ - source 13 - target 0 + source 6 + target 5 graphics [ fill "#000000" @@ -8665,7 +5689,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8675,8 +5699,8 @@ graph ] edge [ - source 13 - target 14 + source 5 + target 6 graphics [ fill "#000000" @@ -8685,7 +5709,7 @@ graph ] LabelGraphics [ - text "eTypeParameters reference EClassifier" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8695,17 +5719,16 @@ graph ] edge [ - source 0 - target 15 + source 10 + target 9 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8715,8 +5738,8 @@ graph ] edge [ - source 0 - target 11 + source 7 + target 8 graphics [ fill "#000000" @@ -8725,7 +5748,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8735,8 +5758,8 @@ graph ] edge [ - source 0 - target 13 + source 7 + target 9 graphics [ fill "#000000" @@ -8745,7 +5768,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8755,8 +5778,8 @@ graph ] edge [ - source 0 - target 12 + source 7 + target 11 graphics [ fill "#000000" @@ -8765,26 +5788,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8794,7 +5798,7 @@ graph ] edge [ - source 11 + source 7 target 6 graphics [ @@ -8803,45 +5807,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 1 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "serializable attribute EDataType" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8851,54 +5817,17 @@ graph ] edge [ - source 0 + source 9 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8908,8 +5837,8 @@ graph ] edge [ - source 12 - target 10 + source 8 + target 7 graphics [ fill "#000000" @@ -8917,7 +5846,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8927,8 +5856,8 @@ graph ] edge [ - source 0 - target 8 + source 9 + target 7 graphics [ fill "#000000" @@ -8936,7 +5865,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -8945,180 +5874,53 @@ graph ] ] edge - [ - source 12 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 6 + target 0 + graphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9126,7 +5928,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9138,6 +5940,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9149,11 +5952,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9161,7 +5964,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9173,6 +5976,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9184,11 +5988,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9196,7 +6000,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9208,6 +6012,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -9219,10 +6024,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -9231,7 +6036,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9254,10 +6059,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -9266,7 +6071,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9289,11 +6094,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9301,7 +6106,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9313,6 +6118,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -9324,11 +6130,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9336,7 +6142,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -9348,6 +6154,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -9359,11 +6167,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9383,12 +6191,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -9400,11 +6204,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9424,12 +6228,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -9441,11 +6240,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9465,12 +6264,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -9482,11 +6277,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 96 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9506,11 +6301,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -9522,11 +6313,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -9546,12 +6337,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -9563,7 +6350,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -9598,7 +6385,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -9633,7 +6420,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -9668,7 +6455,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -9691,126 +6478,27 @@ graph ] LabelGraphics [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 13 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eTypeParameters reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 11 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ - source 0 - target 12 + source 8 + target 7 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9820,17 +6508,16 @@ graph ] edge [ - source 12 - target 13 + source 10 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9840,16 +6527,17 @@ graph ] edge [ - source 12 - target 0 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9859,16 +6547,17 @@ graph ] edge [ - source 13 - target 12 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9878,16 +6567,17 @@ graph ] edge [ - source 11 - target 1 + source 5 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "abstract attribute EClass" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9897,16 +6587,17 @@ graph ] edge [ - source 11 - target 2 + source 5 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "interface attribute EClass" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9916,35 +6607,17 @@ graph ] edge [ - source 11 + source 7 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceTypeName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9954,35 +6627,17 @@ graph ] edge [ - source 0 + source 6 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -9992,8 +6647,8 @@ graph ] edge [ - source 0 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -10001,7 +6656,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10011,8 +6666,8 @@ graph ] edge [ - source 13 - target 7 + source 7 + target 5 graphics [ fill "#000000" @@ -10020,7 +6675,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10030,8 +6685,8 @@ graph ] edge [ - source 12 - target 7 + source 9 + target 5 graphics [ fill "#000000" @@ -10039,7 +6694,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10049,8 +6704,8 @@ graph ] edge [ - source 0 - target 8 + source 11 + target 5 graphics [ fill "#000000" @@ -10058,7 +6713,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10182,8 +6837,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10191,7 +6846,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10203,8 +6858,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -10219,7 +6872,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -10228,7 +6881,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10254,8 +6907,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10263,7 +6916,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10275,6 +6928,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -10289,7 +6943,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -10310,8 +6964,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10325,6 +6979,190 @@ graph [ id 7 graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics [ w 112.2 h 26 @@ -10358,7 +7196,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -10393,7 +7231,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -10428,7 +7266,7 @@ graph node [ - id 10 + id 15 graphics [ w 103.4 @@ -10462,8 +7300,8 @@ graph ] edge [ - source 6 - target 3 + source 11 + target 9 graphics [ fill "#000000" @@ -10471,7 +7309,7 @@ graph ] LabelGraphics [ - text "model reference FunctionalElement" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10481,7 +7319,7 @@ graph ] edge [ - source 3 + source 5 target 6 graphics [ @@ -10491,7 +7329,107 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10502,7 +7440,7 @@ graph edge [ source 6 - target 1 + target 5 graphics [ fill "#000000" @@ -10510,7 +7448,7 @@ graph ] LabelGraphics [ - text "type attribute Function" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -10518,162 +7456,92 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 7 + target 5 + graphics [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 8 + target 5 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10681,7 +7549,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10693,6 +7561,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10704,11 +7573,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10716,7 +7585,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10728,6 +7597,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10739,11 +7609,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10751,7 +7621,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10763,6 +7633,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -10774,10 +7645,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -10786,7 +7657,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10809,10 +7680,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -10821,7 +7692,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10844,11 +7715,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10856,7 +7727,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10868,6 +7739,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -10879,11 +7751,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10891,7 +7763,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -10903,6 +7775,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10914,11 +7788,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10938,12 +7812,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10955,11 +7825,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -10979,12 +7849,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -10996,11 +7862,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11020,12 +7886,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EOperation class - ETypedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -11037,11 +7898,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 68 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11061,9 +7922,7 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -11075,11 +7934,11 @@ graph node [ - id 15 + id 11 graphics [ - w 238.70000000000002 - h 40 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -11099,7 +7958,8 @@ graph LabelGraphics [ text " - EStringToStringMapEntry class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -11111,7 +7971,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -11146,7 +8006,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -11181,7 +8041,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -11216,7 +8076,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -11250,28 +8110,8 @@ graph ] edge [ - source 14 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "details reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 + source 9 + target 6 graphics [ fill "#000000" @@ -11279,7 +8119,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11289,8 +8129,8 @@ graph ] edge [ - source 11 - target 11 + source 10 + target 7 graphics [ fill "#000000" @@ -11298,7 +8138,7 @@ graph ] LabelGraphics [ - text "eSuperTypes reference EClass" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11308,8 +8148,8 @@ graph ] edge [ - source 11 - target 13 + source 5 + target 6 graphics [ fill "#000000" @@ -11318,45 +8158,7 @@ graph ] LabelGraphics [ - text "eOperations reference EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eAllSuperTypes reference EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11366,8 +8168,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 7 graphics [ fill "#000000" @@ -11376,26 +8178,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eContainingClass reference EOperation" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11405,8 +8188,8 @@ graph ] edge [ - source 0 - target 11 + source 5 + target 8 graphics [ fill "#000000" @@ -11415,7 +8198,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11425,8 +8208,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 11 graphics [ fill "#000000" @@ -11435,45 +8218,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11483,16 +8228,17 @@ graph ] edge [ - source 11 + source 6 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11502,54 +8248,17 @@ graph ] edge [ - source 0 + source 7 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11559,8 +8268,8 @@ graph ] edge [ - source 12 - target 8 + source 6 + target 5 graphics [ fill "#000000" @@ -11568,7 +8277,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11578,8 +8287,8 @@ graph ] edge [ - source 0 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -11587,7 +8296,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11597,8 +8306,8 @@ graph ] edge [ - source 13 - target 1 + source 8 + target 5 graphics [ fill "#000000" @@ -11606,7 +8315,7 @@ graph ] LabelGraphics [ - text "unique attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -11616,8 +8325,8 @@ graph ] edge [ - source 13 - target 4 + source 11 + target 5 graphics [ fill "#000000" @@ -11625,7 +8334,7 @@ graph ] LabelGraphics [ - text "upperBound attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png index b5fea093..05355ee6 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi index 4a9086fe..956b6f1b 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi @@ -1,10 +1,11 @@ - - -
- - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml index 55dc70ba..ed77ebc2 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml @@ -113,8 +113,8 @@ graph id 3 graphics [ - w 361.90000000000003 - h 54 + w 41.800000000000004 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -122,7 +122,7 @@ graph ] LabelGraphics [ - text "o 1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -134,8 +134,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -150,7 +148,7 @@ graph id 4 graphics [ - w 41.800000000000004 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -159,7 +157,7 @@ graph ] LabelGraphics [ - text "true" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -185,8 +183,8 @@ graph id 5 graphics [ - w 50.6 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -194,7 +192,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -206,6 +204,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -220,7 +219,7 @@ graph id 6 graphics [ - w 192.50000000000003 + w 184.8 h 54 type "rectangle" fill "#FFFFFF" @@ -241,8 +240,8 @@ graph LabelGraphics [ text " - FunctionalElement class - Function class + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -257,8 +256,8 @@ graph id 7 graphics [ - w 112.2 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -266,7 +265,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -278,6 +277,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -292,8 +293,8 @@ graph id 8 graphics [ - w 85.80000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -301,7 +302,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -313,6 +314,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -327,8 +330,8 @@ graph id 9 graphics [ - w 103.4 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -336,7 +339,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -348,6 +351,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -362,102 +366,7 @@ graph id 10 graphics [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 6 - target 3 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "model reference FunctionalElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "rootElements reference FunctionalArchitectureModel" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "type attribute Function" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 226.60000000000002 + w 177.10000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -466,7 +375,7 @@ graph ] LabelGraphics [ - text "Root literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -478,7 +387,7 @@ graph LabelGraphics [ text " - FunctionType enum + InformationLink class " fontSize 14 fontName "Consolas" @@ -490,11 +399,11 @@ graph node [ - id 1 + id 11 graphics [ - w 297.0 - h 40 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -502,7 +411,7 @@ graph ] LabelGraphics [ - text "Intermediate literal FunctionType" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -514,7 +423,8 @@ graph LabelGraphics [ text " - FunctionType enum + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -526,11 +436,11 @@ graph node [ - id 2 + id 12 graphics [ - w 226.60000000000002 - h 40 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -538,7 +448,7 @@ graph ] LabelGraphics [ - text "Leaf literal FunctionType" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -550,7 +460,6 @@ graph LabelGraphics [ text " - FunctionType enum " fontSize 14 fontName "Consolas" @@ -562,11 +471,11 @@ graph node [ - id 3 + id 13 graphics [ - w 361.90000000000003 - h 54 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -574,7 +483,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -586,8 +495,6 @@ graph LabelGraphics [ text " - FunctionalArchitectureModel class DefinedPart - FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -599,10 +506,10 @@ graph node [ - id 4 + id 14 graphics [ - w 41.800000000000004 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -611,7 +518,7 @@ graph ] LabelGraphics [ - text "true" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -634,10 +541,10 @@ graph node [ - id 5 + id 15 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -646,7 +553,7 @@ graph ] LabelGraphics [ - text "false" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -666,187 +573,67 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 9 + target 7 + graphics [ - id 6 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FunctionalElement class - Function class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 7 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 10 + target 7 + graphics [ - id 8 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 9 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 9 + target 8 + graphics [ - id 10 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] + ] edge [ - source 6 - target 3 + source 10 + target 8 graphics [ fill "#000000" @@ -854,7 +641,7 @@ graph ] LabelGraphics [ - text "model reference FunctionalElement" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -864,7 +651,7 @@ graph ] edge [ - source 3 + source 5 target 6 graphics [ @@ -874,7 +661,7 @@ graph ] LabelGraphics [ - text "rootElements reference FunctionalArchitectureModel" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -884,16 +671,17 @@ graph ] edge [ - source 6 - target 0 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "type attribute Function" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -901,162 +689,210 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 5 + target 8 + graphics [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 5 + target 11 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1064,7 +900,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1076,6 +912,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1087,11 +924,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1099,7 +936,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1111,6 +948,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1122,11 +960,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1134,7 +972,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1146,6 +984,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1157,10 +996,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -1169,7 +1008,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1192,10 +1031,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -1204,7 +1043,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1227,11 +1066,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1239,7 +1078,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1251,6 +1090,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -1262,11 +1102,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1274,7 +1114,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1286,6 +1126,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1297,11 +1139,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1321,13 +1163,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -1339,11 +1175,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1363,13 +1199,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -1381,11 +1211,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1405,12 +1235,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1422,11 +1248,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 124 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1446,13 +1272,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1464,11 +1285,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1488,13 +1309,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1506,7 +1322,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -1541,7 +1357,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -1576,7 +1392,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -1611,7 +1427,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -1645,8 +1461,8 @@ graph ] edge [ - source 11 - target 0 + source 7 + target 6 graphics [ fill "#000000" @@ -1654,7 +1470,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1664,8 +1480,8 @@ graph ] edge [ - source 12 - target 0 + source 8 + target 6 graphics [ fill "#000000" @@ -1673,7 +1489,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1683,8 +1499,8 @@ graph ] edge [ - source 14 - target 0 + source 7 + target 9 graphics [ fill "#000000" @@ -1692,7 +1508,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1702,8 +1518,8 @@ graph ] edge [ - source 15 - target 13 + source 8 + target 11 graphics [ fill "#000000" @@ -1711,7 +1527,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1721,8 +1537,8 @@ graph ] edge [ - source 0 - target 11 + source 5 + target 6 graphics [ fill "#000000" @@ -1731,7 +1547,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1741,8 +1557,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 9 graphics [ fill "#000000" @@ -1751,7 +1567,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1761,8 +1577,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 10 graphics [ fill "#000000" @@ -1771,7 +1587,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1781,8 +1597,8 @@ graph ] edge [ - source 13 - target 15 + source 5 + target 11 graphics [ fill "#000000" @@ -1791,7 +1607,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1801,17 +1617,16 @@ graph ] edge [ - source 0 - target 13 + source 9 + target 7 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1821,8 +1636,8 @@ graph ] edge [ - source 13 - target 0 + source 11 + target 8 graphics [ fill "#000000" @@ -1830,7 +1645,7 @@ graph ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1840,16 +1655,17 @@ graph ] edge [ - source 12 - target 8 + source 6 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1859,35 +1675,17 @@ graph ] edge [ - source 11 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceClassName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 10 + source 6 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1897,8 +1695,8 @@ graph ] edge [ - source 12 - target 8 + source 6 + target 5 graphics [ fill "#000000" @@ -1906,7 +1704,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1916,8 +1714,8 @@ graph ] edge [ - source 0 - target 10 + source 9 + target 5 graphics [ fill "#000000" @@ -1925,7 +1723,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1935,8 +1733,8 @@ graph ] edge [ - source 12 - target 10 + source 10 + target 5 graphics [ fill "#000000" @@ -1944,7 +1742,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1955,102 +1753,7 @@ graph edge [ source 11 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 6 + target 5 graphics [ fill "#000000" @@ -2058,7 +1761,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2074,8 +1777,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2083,7 +1786,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2095,12 +1798,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -2115,8 +1813,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2124,7 +1822,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2136,6 +1834,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -2150,8 +1849,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2159,7 +1858,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2171,6 +1870,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -2185,7 +1885,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -2194,7 +1894,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2220,7 +1920,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -2229,7 +1929,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2255,8 +1955,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2264,7 +1964,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2276,6 +1976,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -2290,8 +1991,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2299,7 +2000,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2311,6 +2012,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -2325,8 +2028,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2334,7 +2037,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2346,6 +2049,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -2360,8 +2065,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2369,7 +2074,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2381,6 +2086,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -2395,8 +2102,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2404,7 +2111,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2416,6 +2123,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -2430,8 +2138,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2439,7 +2147,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2451,6 +2159,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -2465,8 +2175,8 @@ graph id 11 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2486,12 +2196,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -2506,8 +2211,8 @@ graph id 12 graphics [ - w 269.5 - h 68 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2515,7 +2220,7 @@ graph ] LabelGraphics [ - text "null" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2527,9 +2232,6 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2544,8 +2246,8 @@ graph id 13 graphics [ - w 269.5 - h 110 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2553,7 +2255,7 @@ graph ] LabelGraphics [ - text "null" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2565,12 +2267,6 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2585,8 +2281,8 @@ graph id 14 graphics [ - w 269.5 - h 110 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2594,7 +2290,7 @@ graph ] LabelGraphics [ - text "null" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2606,12 +2302,6 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2626,8 +2316,8 @@ graph id 15 graphics [ - w 269.5 - h 68 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2635,7 +2325,7 @@ graph ] LabelGraphics [ - text "null" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2647,9 +2337,6 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2658,314 +2345,37 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 9 + target 7 + graphics [ - id 16 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 17 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node - [ - id 18 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 19 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 12 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eAnnotations reference EModelElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eAnnotations reference EModelElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 11 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 13 - graphics + ] + edge + [ + source 11 + target 10 + graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2975,8 +2385,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 6 graphics [ fill "#000000" @@ -2985,7 +2395,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2995,16 +2405,17 @@ graph ] edge [ - source 12 + source 5 target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "source attribute EAnnotation" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3014,16 +2425,17 @@ graph ] edge [ - source 11 + source 5 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3033,16 +2445,17 @@ graph ] edge [ - source 14 + source 5 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3052,35 +2465,17 @@ graph ] edge [ - source 11 + source 7 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3090,16 +2485,17 @@ graph ] edge [ - source 11 - target 8 + source 10 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3109,8 +2505,8 @@ graph ] edge [ - source 13 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -3118,7 +2514,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3128,8 +2524,8 @@ graph ] edge [ - source 14 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -3137,7 +2533,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3147,8 +2543,8 @@ graph ] edge [ - source 0 - target 9 + source 8 + target 5 graphics [ fill "#000000" @@ -3156,7 +2552,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3166,8 +2562,8 @@ graph ] edge [ - source 0 - target 8 + source 10 + target 5 graphics [ fill "#000000" @@ -3175,7 +2571,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3191,8 +2587,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3200,7 +2596,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3212,12 +2608,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3232,8 +2623,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3241,7 +2632,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3253,6 +2644,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3267,8 +2659,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3276,7 +2668,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3288,6 +2680,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -3302,7 +2695,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -3311,7 +2704,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3337,7 +2730,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -3346,7 +2739,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3372,8 +2765,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3381,7 +2774,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3393,6 +2786,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -3407,8 +2801,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3416,7 +2810,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3428,6 +2822,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -3442,8 +2838,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3451,7 +2847,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3463,6 +2859,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -3477,8 +2875,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3486,7 +2884,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3498,6 +2896,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -3512,8 +2912,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3521,7 +2921,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3533,6 +2933,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -3547,8 +2948,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3556,7 +2957,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3568,6 +2969,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -3582,8 +2984,8 @@ graph id 11 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3603,13 +3005,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -3623,166 +3019,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 96 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EEnumLiteral class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 68 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 96 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -3816,7 +3052,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -3851,7 +3087,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -3886,7 +3122,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -3920,8 +3156,8 @@ graph ] edge [ - source 14 - target 0 + source 9 + target 6 graphics [ fill "#000000" @@ -3929,7 +3165,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3939,8 +3175,8 @@ graph ] edge [ - source 11 - target 0 + source 10 + target 7 graphics [ fill "#000000" @@ -3948,7 +3184,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3958,8 +3194,8 @@ graph ] edge [ - source 12 - target 0 + source 11 + target 6 graphics [ fill "#000000" @@ -3967,7 +3203,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3977,17 +3213,16 @@ graph ] edge [ - source 12 - target 15 + source 11 + target 7 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eTypeParameters reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3997,8 +3232,8 @@ graph ] edge [ - source 11 - target 13 + source 5 + target 6 graphics [ fill "#000000" @@ -4007,7 +3242,7 @@ graph ] LabelGraphics [ - text "eLiterals reference EEnum" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4017,16 +3252,17 @@ graph ] edge [ - source 13 - target 11 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eEnum reference EEnumLiteral" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4036,8 +3272,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 8 graphics [ fill "#000000" @@ -4046,7 +3282,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4056,17 +3292,16 @@ graph ] edge [ - source 0 + source 7 target 11 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4076,8 +3311,8 @@ graph ] edge [ - source 0 - target 12 + source 6 + target 11 graphics [ fill "#000000" @@ -4086,7 +3321,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4096,16 +3331,17 @@ graph ] edge [ - source 14 - target 10 + source 6 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "source attribute EAnnotation" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4115,16 +3351,17 @@ graph ] edge [ - source 11 - target 8 + source 7 + target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4134,8 +3371,8 @@ graph ] edge [ - source 12 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -4143,7 +3380,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4153,8 +3390,8 @@ graph ] edge [ - source 11 - target 9 + source 7 + target 5 graphics [ fill "#000000" @@ -4162,7 +3399,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4172,8 +3409,8 @@ graph ] edge [ - source 12 - target 9 + source 8 + target 5 graphics [ fill "#000000" @@ -4181,7 +3418,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4189,190 +3426,52 @@ graph position "thead" ] ] - edge - [ - source 11 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics +] +graph +[ + node [ - text "serializable attribute EDataType" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 12 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "serializable attribute EDataType" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "literal attribute EEnumLiteral" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node + + node [ id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4380,7 +3479,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4392,6 +3491,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -4406,8 +3506,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4415,7 +3515,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4427,6 +3527,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -4441,7 +3542,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -4450,7 +3551,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4476,7 +3577,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -4485,7 +3586,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4511,8 +3612,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 269.5 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4520,7 +3621,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4532,6 +3633,7 @@ graph LabelGraphics [ text " + FunctionalArchitectureModel class " fontSize 14 fontName "Consolas" @@ -4546,8 +3648,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 192.50000000000003 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4555,7 +3657,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4567,6 +3669,8 @@ graph LabelGraphics [ text " + FunctionalElement class + Function class " fontSize 14 fontName "Consolas" @@ -4581,8 +3685,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4590,7 +3694,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4602,6 +3706,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -4616,8 +3721,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4625,7 +3730,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4637,6 +3742,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4651,8 +3758,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4660,7 +3767,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4672,6 +3779,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -4686,8 +3794,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4695,7 +3803,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4707,6 +3815,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -4721,8 +3831,8 @@ graph id 11 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4742,12 +3852,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -4762,8 +3867,8 @@ graph id 12 graphics [ - w 269.5 - h 110 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4771,7 +3876,7 @@ graph ] LabelGraphics [ - text "null" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4783,12 +3888,6 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4803,8 +3902,8 @@ graph id 13 graphics [ - w 269.5 - h 124 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4812,7 +3911,7 @@ graph ] LabelGraphics [ - text "null" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4824,13 +3923,6 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4845,8 +3937,8 @@ graph id 14 graphics [ - w 269.5 - h 96 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4854,7 +3946,7 @@ graph ] LabelGraphics [ - text "null" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4866,11 +3958,6 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4885,8 +3972,8 @@ graph id 15 graphics [ - w 269.5 - h 68 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4894,7 +3981,7 @@ graph ] LabelGraphics [ - text "null" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4906,9 +3993,6 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4917,158 +4001,19 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 6 + target 7 + graphics [ - id 16 - graphics - [ - w 112.2 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Integers" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 17 - graphics - [ - w 85.80000000000001 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Reals" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 18 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Strings" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 19 - graphics - [ - w 103.4 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 15 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" + text "interface reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5078,8 +4023,8 @@ graph ] edge [ - source 11 - target 0 + source 6 + target 5 graphics [ fill "#000000" @@ -5087,7 +4032,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "model reference FunctionalElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5097,16 +4042,17 @@ graph ] edge [ - source 13 - target 0 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "ePackage reference EClassifier" + text "rootElements reference FunctionalArchitectureModel" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5116,17 +4062,16 @@ graph ] edge [ - source 13 - target 14 + source 9 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eTypeParameters reference EClassifier" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5136,17 +4081,16 @@ graph ] edge [ - source 0 - target 15 + source 11 + target 10 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5156,8 +4100,8 @@ graph ] edge [ - source 0 - target 11 + source 7 + target 8 graphics [ fill "#000000" @@ -5166,7 +4110,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5176,8 +4120,8 @@ graph ] edge [ - source 0 - target 13 + source 7 + target 10 graphics [ fill "#000000" @@ -5186,7 +4130,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5196,17 +4140,16 @@ graph ] edge [ - source 0 - target 12 + source 7 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eSubpackages reference EPackage" + text "element reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5216,16 +4159,17 @@ graph ] edge [ - source 12 - target 0 + source 8 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "eSuperPackage reference EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5235,16 +4179,17 @@ graph ] edge [ - source 15 - target 6 + source 10 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "source attribute EAnnotation" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5254,8 +4199,8 @@ graph ] edge [ - source 11 - target 6 + source 8 + target 7 graphics [ fill "#000000" @@ -5263,7 +4208,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5273,7 +4218,7 @@ graph ] edge [ - source 13 + source 10 target 7 graphics [ @@ -5282,7 +4227,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5292,8 +4237,8 @@ graph ] edge [ - source 11 - target 1 + source 6 + target 2 graphics [ fill "#000000" @@ -5301,7 +4246,7 @@ graph ] LabelGraphics [ - text "serializable attribute EDataType" + text "type attribute Function" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -5309,130 +4254,2035 @@ graph position "thead" ] ] - edge - [ - source 0 - target 10 - graphics +] +graph +[ + node [ - fill "#000000" - targetArrow "standard" + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 12 - target 6 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] edge [ - source 0 + source 7 target 9 graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics [ fill "#000000" targetArrow "standard" ] - LabelGraphics + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 12 - target 10 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 0 - target 8 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 12 - target 8 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 10 graphics [ - w 254.10000000000002 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5440,7 +6290,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5452,12 +6302,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -5469,11 +6314,11 @@ graph node [ - id 1 + id 11 graphics [ - w 41.800000000000004 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5481,7 +6326,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5493,6 +6338,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5504,10 +6351,10 @@ graph node [ - id 2 + id 12 graphics [ - w 50.6 + w 112.2 h 26 type "rectangle" fill "#FFFFFF" @@ -5516,7 +6363,7 @@ graph ] LabelGraphics [ - text "false" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5539,10 +6386,10 @@ graph node [ - id 3 + id 13 graphics [ - w 24.200000000000003 + w 85.80000000000001 h 26 type "rectangle" fill "#FFFFFF" @@ -5551,7 +6398,7 @@ graph ] LabelGraphics [ - text "-1" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5574,10 +6421,10 @@ graph node [ - id 4 + id 14 graphics [ - w 15.400000000000002 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -5586,7 +6433,7 @@ graph ] LabelGraphics [ - text "0" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5609,10 +6456,10 @@ graph node [ - id 5 + id 15 graphics [ - w 15.400000000000002 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -5621,7 +6468,7 @@ graph ] LabelGraphics [ - text "1" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5641,14 +6488,250 @@ graph borderDistance 6 ] ] - + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 6 + id 0 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5656,7 +6739,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5668,6 +6751,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5679,11 +6763,11 @@ graph node [ - id 7 + id 1 graphics [ - w 33.0 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5691,7 +6775,7 @@ graph ] LabelGraphics [ - text ""B"" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5703,6 +6787,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5714,11 +6799,11 @@ graph node [ - id 8 + id 2 graphics [ - w 94.60000000000001 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5726,7 +6811,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5738,6 +6823,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -5749,10 +6835,10 @@ graph node [ - id 9 + id 3 graphics [ - w 68.2 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -5761,7 +6847,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5784,10 +6870,10 @@ graph node [ - id 10 + id 4 graphics [ - w 121.00000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -5796,7 +6882,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -5819,11 +6905,11 @@ graph node [ - id 11 + id 5 graphics [ - w 269.5 - h 110 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5843,12 +6929,7 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -5860,11 +6941,11 @@ graph node [ - id 12 + id 6 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5884,12 +6965,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5901,11 +6978,11 @@ graph node [ - id 13 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5925,12 +7002,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5942,11 +7015,11 @@ graph node [ - id 14 + id 8 graphics [ - w 269.5 - h 96 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -5966,11 +7039,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - ETypeParameter class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -5982,11 +7052,11 @@ graph node [ - id 15 + id 9 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6006,12 +7076,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6023,11 +7089,11 @@ graph node [ - id 16 + id 10 graphics [ - w 112.2 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6035,7 +7101,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6047,6 +7113,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6058,11 +7126,11 @@ graph node [ - id 17 + id 11 graphics [ - w 85.80000000000001 - h 26 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6070,7 +7138,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6082,6 +7150,7 @@ graph LabelGraphics [ text " + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -6093,10 +7162,10 @@ graph node [ - id 18 + id 12 graphics [ - w 103.4 + w 112.2 h 26 type "rectangle" fill "#FFFFFF" @@ -6105,7 +7174,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6128,10 +7197,10 @@ graph node [ - id 19 + id 13 graphics [ - w 103.4 + w 85.80000000000001 h 26 type "rectangle" fill "#FFFFFF" @@ -6140,206 +7209,100 @@ graph ] LabelGraphics [ - text "New Objects" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 fontName "Monospace" autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 13 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eTypeParameters reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 11 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 12 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 13 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 13 - target 12 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "eSuperPackage reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] edge [ source 11 - target 1 + target 6 graphics [ fill "#000000" @@ -6347,7 +7310,7 @@ graph ] LabelGraphics [ - text "abstract attribute EClass" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6357,16 +7320,17 @@ graph ] edge [ - source 11 - target 2 + source 5 + target 6 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "interface attribute EClass" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6376,16 +7340,17 @@ graph ] edge [ - source 11 - target 8 + source 5 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6395,16 +7360,17 @@ graph ] edge [ - source 15 - target 6 + source 5 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6414,16 +7380,17 @@ graph ] edge [ - source 0 - target 10 + source 5 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6433,16 +7400,17 @@ graph ] edge [ - source 13 - target 8 + source 5 + target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6452,16 +7420,17 @@ graph ] edge [ - source 11 - target 6 + source 6 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6471,8 +7440,8 @@ graph ] edge [ - source 0 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -6480,7 +7449,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6490,8 +7459,8 @@ graph ] edge [ - source 13 - target 7 + source 7 + target 5 graphics [ fill "#000000" @@ -6499,7 +7468,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6509,8 +7478,8 @@ graph ] edge [ - source 12 - target 7 + source 8 + target 5 graphics [ fill "#000000" @@ -6518,7 +7487,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6528,8 +7497,8 @@ graph ] edge [ - source 0 - target 8 + source 9 + target 5 graphics [ fill "#000000" @@ -6537,7 +7506,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -6545,162 +7514,35 @@ graph position "thead" ] ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 254.10000000000002 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6708,7 +7550,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6720,6 +7562,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6731,11 +7574,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6743,7 +7586,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6755,6 +7598,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6766,11 +7610,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6778,7 +7622,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6790,6 +7634,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -6801,10 +7646,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -6813,7 +7658,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6836,10 +7681,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -6848,7 +7693,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6871,11 +7716,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6883,7 +7728,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6895,6 +7740,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -6906,11 +7752,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6918,7 +7764,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -6930,6 +7776,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6941,11 +7789,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -6965,12 +7813,8 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -6982,11 +7826,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7006,12 +7850,8 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -7023,11 +7863,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7047,12 +7887,7 @@ graph LabelGraphics [ text " - EModelElement class - ENamedElement class - EOperation class - ETypedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7064,11 +7899,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 68 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -7088,9 +7923,7 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7102,10 +7935,10 @@ graph node [ - id 15 + id 11 graphics [ - w 238.70000000000002 + w 161.70000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -7126,7 +7959,7 @@ graph LabelGraphics [ text " - EStringToStringMapEntry class + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -7138,7 +7971,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -7173,7 +8006,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -7208,7 +8041,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -7243,7 +8076,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -7277,75 +8110,16 @@ graph ] edge [ - source 14 - target 15 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "details reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 11 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperTypes reference EClass" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 13 + source 9 + target 6 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eOperations reference EClass" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7355,8 +8129,8 @@ graph ] edge [ - source 11 - target 11 + source 10 + target 7 graphics [ fill "#000000" @@ -7364,7 +8138,7 @@ graph ] LabelGraphics [ - text "eAllSuperTypes reference EClass" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7375,46 +8149,7 @@ graph edge [ source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 14 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "eAnnotations reference EModelElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 11 + target 8 graphics [ fill "#000000" @@ -7422,7 +8157,7 @@ graph ] LabelGraphics [ - text "eContainingClass reference EOperation" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7432,8 +8167,8 @@ graph ] edge [ - source 0 - target 11 + source 5 + target 6 graphics [ fill "#000000" @@ -7442,7 +8177,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7452,8 +8187,8 @@ graph ] edge [ - source 0 - target 12 + source 5 + target 7 graphics [ fill "#000000" @@ -7462,26 +8197,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7491,16 +8207,17 @@ graph ] edge [ - source 11 + source 5 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7510,16 +8227,17 @@ graph ] edge [ - source 11 + source 6 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7529,73 +8247,17 @@ graph ] edge [ - source 0 + source 7 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 9 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7605,16 +8267,17 @@ graph ] edge [ - source 12 - target 8 + source 8 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7624,8 +8287,8 @@ graph ] edge [ - source 0 - target 8 + source 6 + target 5 graphics [ fill "#000000" @@ -7633,7 +8296,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7643,8 +8306,8 @@ graph ] edge [ - source 13 - target 1 + source 7 + target 5 graphics [ fill "#000000" @@ -7652,7 +8315,7 @@ graph ] LabelGraphics [ - text "unique attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -7662,8 +8325,8 @@ graph ] edge [ - source 13 - target 4 + source 8 + target 5 graphics [ fill "#000000" @@ -7671,7 +8334,7 @@ graph ] LabelGraphics [ - text "upperBound attribute ETypedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png index bfe18c4e..5df81bb3 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi index 45634c72..b4259573 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi @@ -1,10 +1,12 @@ - - -
- - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml index a44b2785..2dd09497 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml @@ -5,8 +5,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -14,7 +14,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -26,12 +26,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -46,8 +41,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -55,7 +50,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -67,6 +62,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -81,8 +77,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -90,7 +86,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -102,6 +98,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -116,7 +113,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -125,7 +122,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -151,7 +148,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -160,7 +157,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -186,8 +183,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -195,7 +192,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -207,6 +204,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -221,8 +219,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -230,7 +228,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -242,6 +240,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -256,8 +256,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -265,7 +265,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -277,6 +277,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -291,8 +293,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -300,7 +302,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -312,6 +314,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -326,8 +330,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -335,7 +339,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -347,6 +351,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -361,8 +366,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -370,7 +375,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -382,6 +387,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -396,8 +402,8 @@ graph id 11 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -417,13 +423,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -437,173 +437,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -637,7 +470,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -672,7 +505,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -707,7 +540,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -741,8 +574,8 @@ graph ] edge [ - source 11 - target 0 + source 9 + target 7 graphics [ fill "#000000" @@ -750,7 +583,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -760,8 +593,8 @@ graph ] edge [ - source 12 - target 0 + source 10 + target 7 graphics [ fill "#000000" @@ -769,7 +602,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -779,8 +612,8 @@ graph ] edge [ - source 14 - target 0 + source 11 + target 6 graphics [ fill "#000000" @@ -788,7 +621,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -798,8 +631,8 @@ graph ] edge [ - source 15 - target 13 + source 9 + target 8 graphics [ fill "#000000" @@ -807,7 +640,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -817,17 +650,16 @@ graph ] edge [ - source 0 - target 11 + source 11 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -837,17 +669,16 @@ graph ] edge [ - source 0 - target 12 + source 10 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -857,8 +688,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 6 graphics [ fill "#000000" @@ -867,7 +698,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -877,8 +708,8 @@ graph ] edge [ - source 13 - target 15 + source 5 + target 7 graphics [ fill "#000000" @@ -887,7 +718,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -897,8 +728,8 @@ graph ] edge [ - source 0 - target 13 + source 5 + target 8 graphics [ fill "#000000" @@ -907,26 +738,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -936,8 +748,8 @@ graph ] edge [ - source 12 - target 8 + source 8 + target 9 graphics [ fill "#000000" @@ -945,7 +757,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -955,8 +767,8 @@ graph ] edge [ - source 11 - target 6 + source 8 + target 11 graphics [ fill "#000000" @@ -964,7 +776,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -974,7 +786,7 @@ graph ] edge [ - source 11 + source 8 target 10 graphics [ @@ -983,7 +795,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -993,16 +805,17 @@ graph ] edge [ - source 12 - target 8 + source 7 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1012,16 +825,17 @@ graph ] edge [ - source 0 + source 7 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1031,16 +845,17 @@ graph ] edge [ - source 12 - target 10 + source 6 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1050,8 +865,8 @@ graph ] edge [ - source 11 - target 10 + source 6 + target 5 graphics [ fill "#000000" @@ -1059,7 +874,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1069,8 +884,8 @@ graph ] edge [ - source 13 - target 6 + source 7 + target 5 graphics [ fill "#000000" @@ -1078,7 +893,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1088,8 +903,8 @@ graph ] edge [ - source 14 - target 10 + source 8 + target 5 graphics [ fill "#000000" @@ -1097,7 +912,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1105,92 +920,267 @@ graph position "thead" ] ] - edge - [ - source 0 - target 9 - graphics +] +graph +[ + node [ - fill "#000000" - targetArrow "standard" + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 0 - target 8 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] - edge - [ - source 13 - target 6 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 7 graphics [ - w 254.10000000000002 - h 110 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1198,7 +1188,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1210,12 +1200,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + InformationLink class " fontSize 14 fontName "Consolas" @@ -1227,11 +1212,11 @@ graph node [ - id 1 + id 8 graphics [ - w 41.800000000000004 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1239,7 +1224,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1251,6 +1236,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -1262,11 +1248,11 @@ graph node [ - id 2 + id 9 graphics [ - w 50.6 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1274,7 +1260,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1286,6 +1272,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1294,49 +1282,6308 @@ graph borderDistance 6 ] ] - - node + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics [ - id 3 - graphics - [ - w 24.200000000000003 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "-1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 4 + id 0 graphics [ - w 15.400000000000002 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1344,7 +7591,7 @@ graph ] LabelGraphics [ - text "0" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1356,6 +7603,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1367,11 +7615,11 @@ graph node [ - id 5 + id 1 graphics [ - w 15.400000000000002 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1379,7 +7627,7 @@ graph ] LabelGraphics [ - text "1" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1391,6 +7639,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1402,11 +7651,11 @@ graph node [ - id 6 + id 2 graphics [ - w 33.0 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1414,7 +7663,7 @@ graph ] LabelGraphics [ - text ""A"" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1426,6 +7675,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1437,10 +7687,10 @@ graph node [ - id 7 + id 3 graphics [ - w 33.0 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -1449,7 +7699,7 @@ graph ] LabelGraphics [ - text ""B"" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1472,10 +7722,10 @@ graph node [ - id 8 + id 4 graphics [ - w 94.60000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -1484,7 +7734,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1507,11 +7757,11 @@ graph node [ - id 9 + id 5 graphics [ - w 68.2 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1519,7 +7769,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1531,6 +7781,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -1542,11 +7793,11 @@ graph node [ - id 10 + id 6 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1554,7 +7805,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1566,6 +7817,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1577,11 +7830,11 @@ graph node [ - id 11 + id 7 graphics [ - w 269.5 - h 110 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1601,12 +7854,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1618,11 +7867,11 @@ graph node [ - id 12 + id 8 graphics [ - w 269.5 - h 68 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1642,9 +7891,8 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1656,11 +7904,11 @@ graph node [ - id 13 + id 9 graphics [ - w 269.5 - h 110 + w 161.70000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1680,12 +7928,7 @@ graph LabelGraphics [ text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FAMTerminator class " fontSize 14 fontName "Consolas" @@ -1697,11 +7940,11 @@ graph node [ - id 14 + id 10 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1721,12 +7964,8 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1738,11 +7977,11 @@ graph node [ - id 15 + id 11 graphics [ - w 269.5 - h 68 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1762,9 +8001,7 @@ graph LabelGraphics [ text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -1776,7 +8013,7 @@ graph node [ - id 16 + id 12 graphics [ w 112.2 @@ -1811,7 +8048,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -1846,7 +8083,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -1881,7 +8118,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -1915,27 +8152,8 @@ graph ] edge [ - source 12 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eModelElement reference EAnnotation" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 15 - target 0 + source 9 + target 6 graphics [ fill "#000000" @@ -1943,7 +8161,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "data reference FAMTerminator" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1954,45 +8172,7 @@ graph edge [ source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 14 - target 0 + target 8 graphics [ fill "#000000" @@ -2000,7 +8180,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2010,17 +8190,16 @@ graph ] edge [ - source 0 - target 12 + source 11 + target 10 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2030,8 +8209,8 @@ graph ] edge [ - source 0 - target 15 + source 5 + target 6 graphics [ fill "#000000" @@ -2040,7 +8219,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2050,8 +8229,8 @@ graph ] edge [ - source 0 - target 11 + source 5 + target 7 graphics [ fill "#000000" @@ -2060,7 +8239,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2070,8 +8249,8 @@ graph ] edge [ - source 0 - target 13 + source 5 + target 8 graphics [ fill "#000000" @@ -2080,7 +8259,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2090,8 +8269,8 @@ graph ] edge [ - source 0 - target 14 + source 5 + target 10 graphics [ fill "#000000" @@ -2100,26 +8279,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source attribute EAnnotation" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2129,8 +8289,8 @@ graph ] edge [ - source 11 - target 8 + source 10 + target 11 graphics [ fill "#000000" @@ -2138,7 +8298,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2148,16 +8308,17 @@ graph ] edge [ - source 14 - target 10 + source 8 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2167,73 +8328,17 @@ graph ] edge [ - source 11 + source 6 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 2 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "serializable attribute EDataType" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 10 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 11 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "name attribute ENamedElement" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2243,8 +8348,8 @@ graph ] edge [ - source 13 - target 9 + source 6 + target 5 graphics [ fill "#000000" @@ -2252,7 +8357,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2262,8 +8367,8 @@ graph ] edge [ - source 14 - target 8 + source 7 + target 5 graphics [ fill "#000000" @@ -2271,7 +8376,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2281,8 +8386,8 @@ graph ] edge [ - source 0 - target 9 + source 8 + target 5 graphics [ fill "#000000" @@ -2290,7 +8395,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2300,8 +8405,8 @@ graph ] edge [ - source 0 - target 8 + source 10 + target 5 graphics [ fill "#000000" @@ -2309,7 +8414,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png index a47da297..5a2af8ba 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi index 8bff1dc6..4ca54850 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi @@ -1,8 +1,11 @@ - - - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml index e5647b66..3a9035a7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml @@ -5,8 +5,8 @@ graph id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -14,7 +14,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -26,12 +26,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -46,8 +41,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -55,7 +50,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -67,6 +62,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -81,8 +77,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -90,7 +86,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -102,6 +98,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -116,7 +113,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -125,7 +122,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -151,7 +148,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -160,7 +157,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -186,8 +183,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -195,7 +192,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -207,6 +204,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -221,8 +219,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -230,7 +228,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -242,6 +240,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -256,8 +256,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -265,7 +265,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -277,6 +277,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -291,8 +293,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -300,7 +302,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -312,6 +314,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -326,8 +330,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -335,7 +339,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -347,6 +351,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -361,8 +366,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -370,7 +375,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -382,6 +387,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -396,8 +402,8 @@ graph id 11 graphics [ - w 269.5 - h 124 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -417,13 +423,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -437,173 +437,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EModelElement class - ENamedElement class - EPackage class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - EPackage class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 124 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EEnum class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -637,7 +470,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -672,7 +505,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -707,7 +540,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -741,27 +574,8 @@ graph ] edge [ - source 11 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "ePackage reference EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 0 + source 9 + target 7 graphics [ fill "#000000" @@ -769,7 +583,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -779,8 +593,8 @@ graph ] edge [ - source 14 - target 0 + source 10 + target 7 graphics [ fill "#000000" @@ -788,7 +602,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -798,8 +612,8 @@ graph ] edge [ - source 15 - target 13 + source 11 + target 7 graphics [ fill "#000000" @@ -807,7 +621,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -817,17 +631,16 @@ graph ] edge [ - source 0 - target 11 + source 9 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -837,17 +650,16 @@ graph ] edge [ - source 0 - target 12 + source 10 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -857,17 +669,16 @@ graph ] edge [ - source 0 - target 14 + source 11 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -877,8 +688,8 @@ graph ] edge [ - source 13 - target 15 + source 5 + target 6 graphics [ fill "#000000" @@ -887,7 +698,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -897,8 +708,8 @@ graph ] edge [ - source 0 - target 13 + source 5 + target 7 graphics [ fill "#000000" @@ -907,26 +718,7 @@ graph ] LabelGraphics [ - text "eSubpackages reference EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 0 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "eSuperPackage reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -936,16 +728,17 @@ graph ] edge [ - source 12 + source 5 target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -955,8 +748,8 @@ graph ] edge [ - source 11 - target 6 + source 8 + target 9 graphics [ fill "#000000" @@ -964,7 +757,7 @@ graph ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -974,7 +767,7 @@ graph ] edge [ - source 11 + source 8 target 10 graphics [ @@ -983,26 +776,7 @@ graph ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 12 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "instanceTypeName attribute EClassifier" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1012,8 +786,8 @@ graph ] edge [ - source 11 - target 1 + source 8 + target 11 graphics [ fill "#000000" @@ -1021,7 +795,7 @@ graph ] LabelGraphics [ - text "serializable attribute EDataType" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1031,16 +805,17 @@ graph ] edge [ - source 0 - target 10 + source 7 + target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1050,16 +825,17 @@ graph ] edge [ - source 12 + source 7 target 10 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1069,16 +845,17 @@ graph ] edge [ - source 11 - target 10 + source 7 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1088,8 +865,8 @@ graph ] edge [ - source 13 - target 6 + source 6 + target 5 graphics [ fill "#000000" @@ -1097,7 +874,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1107,8 +884,8 @@ graph ] edge [ - source 14 - target 10 + source 7 + target 5 graphics [ fill "#000000" @@ -1116,7 +893,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1126,8 +903,8 @@ graph ] edge [ - source 0 - target 9 + source 8 + target 5 graphics [ fill "#000000" @@ -1135,7 +912,7 @@ graph ] LabelGraphics [ - text "nsURI attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1143,73 +920,16 @@ graph position "thead" ] ] - edge - [ - source 13 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsURI attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 8 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 13 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "nsPrefix attribute EPackage" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node +] +graph +[ + node [ id 0 graphics [ - w 254.10000000000002 - h 110 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1217,7 +937,7 @@ graph ] LabelGraphics [ - text "o 1" + text "Root literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1229,12 +949,7 @@ graph LabelGraphics [ text " - EModelElement class DefinedPart - ENamedElement class DefinedPart - EPackage class DefinedPart - EModelElement class - ENamedElement class - EPackage class + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1249,8 +964,8 @@ graph id 1 graphics [ - w 41.800000000000004 - h 26 + w 297.0 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1258,7 +973,7 @@ graph ] LabelGraphics [ - text "true" + text "Intermediate literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1270,6 +985,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1284,8 +1000,8 @@ graph id 2 graphics [ - w 50.6 - h 26 + w 226.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1293,7 +1009,7 @@ graph ] LabelGraphics [ - text "false" + text "Leaf literal FunctionType" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1305,6 +1021,7 @@ graph LabelGraphics [ text " + FunctionType enum " fontSize 14 fontName "Consolas" @@ -1319,7 +1036,7 @@ graph id 3 graphics [ - w 24.200000000000003 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -1328,7 +1045,7 @@ graph ] LabelGraphics [ - text "-1" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1354,7 +1071,7 @@ graph id 4 graphics [ - w 15.400000000000002 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -1363,7 +1080,7 @@ graph ] LabelGraphics [ - text "0" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1389,8 +1106,8 @@ graph id 5 graphics [ - w 15.400000000000002 - h 26 + w 207.9 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1398,7 +1115,7 @@ graph ] LabelGraphics [ - text "1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1410,6 +1127,7 @@ graph LabelGraphics [ text " + FunctionalInterface class " fontSize 14 fontName "Consolas" @@ -1424,8 +1142,8 @@ graph id 6 graphics [ - w 33.0 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1433,7 +1151,7 @@ graph ] LabelGraphics [ - text ""A"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1445,6 +1163,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1459,8 +1179,8 @@ graph id 7 graphics [ - w 33.0 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1468,7 +1188,7 @@ graph ] LabelGraphics [ - text ""B"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1480,6 +1200,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -1494,8 +1215,8 @@ graph id 8 graphics [ - w 94.60000000000001 - h 26 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1503,7 +1224,7 @@ graph ] LabelGraphics [ - text ""nsPrefix"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1515,6 +1236,7 @@ graph LabelGraphics [ text " + InformationLink class " fontSize 14 fontName "Consolas" @@ -1529,8 +1251,8 @@ graph id 9 graphics [ - w 68.2 - h 26 + w 177.10000000000002 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1538,7 +1260,7 @@ graph ] LabelGraphics [ - text ""nsUri"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1550,6 +1272,8 @@ graph LabelGraphics [ text " + FunctionalInput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1564,8 +1288,8 @@ graph id 10 graphics [ - w 121.00000000000001 - h 26 + w 184.8 + h 54 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1573,7 +1297,7 @@ graph ] LabelGraphics [ - text ""packageName"" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1585,6 +1309,8 @@ graph LabelGraphics [ text " + FunctionalOutput class + FunctionalData class " fontSize 14 fontName "Consolas" @@ -1599,8 +1325,8 @@ graph id 11 graphics [ - w 269.5 - h 110 + w 177.10000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1620,12 +1346,7 @@ graph LabelGraphics [ text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart + InformationLink class " fontSize 14 fontName "Consolas" @@ -1639,164 +1360,6 @@ graph [ id 12 graphics - [ - w 269.5 - h 68 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 13 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClass class - EClassifier class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 14 - graphics - [ - w 269.5 - h 110 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EClassifier class - EDataType class - EModelElement class - ENamedElement class - EModelElement class UndefinedPart - ENamedElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 15 - graphics - [ - w 269.5 - h 68 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - EAnnotation class - EModelElement class - EModelElement class UndefinedPart - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 16 - graphics [ w 112.2 h 26 @@ -1830,7 +1393,7 @@ graph node [ - id 17 + id 13 graphics [ w 85.80000000000001 @@ -1865,7 +1428,7 @@ graph node [ - id 18 + id 14 graphics [ w 103.4 @@ -1900,7 +1463,7 @@ graph node [ - id 19 + id 15 graphics [ w 103.4 @@ -1934,8 +1497,8 @@ graph ] edge [ - source 12 - target 0 + source 7 + target 6 graphics [ fill "#000000" @@ -1943,7 +1506,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1953,8 +1516,8 @@ graph ] edge [ - source 15 - target 0 + source 8 + target 6 graphics [ fill "#000000" @@ -1962,7 +1525,7 @@ graph ] LabelGraphics [ - text "eModelElement reference EAnnotation" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1973,7 +1536,7 @@ graph edge [ source 11 - target 0 + target 10 graphics [ fill "#000000" @@ -1981,7 +1544,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "from reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -1991,8 +1554,8 @@ graph ] edge [ - source 13 - target 0 + source 7 + target 9 graphics [ fill "#000000" @@ -2000,7 +1563,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2010,8 +1573,8 @@ graph ] edge [ - source 14 - target 0 + source 8 + target 9 graphics [ fill "#000000" @@ -2019,7 +1582,7 @@ graph ] LabelGraphics [ - text "ePackage reference EClassifier" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2029,17 +1592,16 @@ graph ] edge [ - source 0 - target 12 + source 11 + target 9 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "to reference InformationLink" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2049,8 +1611,8 @@ graph ] edge [ - source 0 - target 15 + source 5 + target 6 graphics [ fill "#000000" @@ -2059,7 +1621,7 @@ graph ] LabelGraphics [ - text "eAnnotations reference EModelElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2069,8 +1631,8 @@ graph ] edge [ - source 0 - target 11 + source 5 + target 9 graphics [ fill "#000000" @@ -2079,7 +1641,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2089,8 +1651,8 @@ graph ] edge [ - source 0 - target 13 + source 5 + target 10 graphics [ fill "#000000" @@ -2099,7 +1661,7 @@ graph ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2109,17 +1671,16 @@ graph ] edge [ - source 0 - target 14 + source 9 + target 7 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "eClassifiers reference EPackage" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2129,8 +1690,8 @@ graph ] edge [ - source 12 - target 7 + source 9 + target 8 graphics [ fill "#000000" @@ -2138,7 +1699,7 @@ graph ] LabelGraphics [ - text "source attribute EAnnotation" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2148,8 +1709,8 @@ graph ] edge [ - source 13 - target 2 + source 9 + target 11 graphics [ fill "#000000" @@ -2157,7 +1718,7 @@ graph ] LabelGraphics [ - text "abstract attribute EClass" + text "IncomingLinks reference FunctionalInput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2167,16 +1728,17 @@ graph ] edge [ - source 11 - target 8 + source 6 + target 7 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2186,16 +1748,17 @@ graph ] edge [ - source 14 - target 10 + source 6 + target 8 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceClassName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2205,16 +1768,17 @@ graph ] edge [ - source 11 - target 9 + source 10 + target 11 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "instanceTypeName attribute EClassifier" + text "outgoingLinks reference FunctionalOutput" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2224,8 +1788,8 @@ graph ] edge [ - source 11 - target 2 + source 6 + target 5 graphics [ fill "#000000" @@ -2233,7 +1797,7 @@ graph ] LabelGraphics [ - text "serializable attribute EDataType" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2243,8 +1807,8 @@ graph ] edge [ - source 0 - target 10 + source 9 + target 5 graphics [ fill "#000000" @@ -2252,7 +1816,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2262,8 +1826,8 @@ graph ] edge [ - source 11 - target 8 + source 10 + target 5 graphics [ fill "#000000" @@ -2271,7 +1835,7 @@ graph ] LabelGraphics [ - text "name attribute ENamedElement" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2279,18 +1843,6515 @@ graph position "thead" ] ] - edge - [ - source 13 - target 9 - graphics - [ - fill "#000000" +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "parent reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "subElements reference Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 269.5 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2300,16 +8361,57 @@ graph ] edge [ - source 14 + source 5 target 8 graphics [ fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "name attribute ENamedElement" + text "data reference FunctionalInterface" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2319,16 +8421,17 @@ graph ] edge [ - source 0 + source 6 target 9 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "nsURI attribute EPackage" + text "terminator reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -2338,8 +8441,84 @@ graph ] edge [ - source 0 - target 8 + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 graphics [ fill "#000000" @@ -2347,7 +8526,7 @@ graph ] LabelGraphics [ - text "nsPrefix attribute EPackage" + text "interface reference FunctionalData" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png index 7b6e8da5..3c09036a 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi index 8bff1dc6..21ac69a6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi @@ -1,8 +1,10 @@ - - - - - - - + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv index 6422beb9..f0a5df58 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv @@ -1,48 +1,20 @@ -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;441;2068;2486;3217702419;62;29;140;4;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;463;2860;2654;3199911479;74;37;138;5;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;499;2201;2467;3339884626;68;36;141;4;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;452;2821;2223;3526490298;59;27;122;5;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;11;1529;1717;4396467206;87;94;100;54;17;4;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;15;1411;1457;4222415279;54;68;77;36;10;4;0;5 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;9;1335;1288;2769089958;64;74;31;12;1;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;4;1180;1189;2923747093;50;58;26;10;1;0;1 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;839;2519;2455;3266543842;68;33;193;5;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;11;2019;1948;3337962573;91;104;53;16;2;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;1719;3345;2829;7904668959;235;261;107;497;53;0;6 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;13;1736;1740;2852471270;62;73;37;19;1;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;529;2502;2857;3681787432;68;30;125;4;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;788;2572;2188;3322713636;67;30;148;5;0;4 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;443;2849;2573;4906642931;151;171;75;124;7;0;8 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;19;4315;9042;20459725100;239;247;252;257;261;217;19;6;0;11 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;513;2237;2193;6152392500;162;177;77;150;6;0;5 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;11;1602;1604;2992330200;66;77;38;16;1;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;128;4855;10109;16068923000;382;391;398;403;409;349;37;8;0;16 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;18;3632;9743;7955260600;299;307;313;261;17;7;0;8 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;471;5606;10554;10190416000;482;497;509;400;189;16;0;21 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;28;4850;10801;9664839300;622;635;651;560;23;18;0;20 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;6;1884;1462;3186743800;40;48;20;16;1;0;1 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -2;1;ModelResultImpl;9;4021;9222;7668037900;233;239;243;201;10;8;0;6 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;2;1459;1800;9941267600;254;383;414;441;477;249;6;14;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;0;1095;1138;10430069000;47;67;101;104;168;77;5;3;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;971;1320;9287027600;59;82;103;298;350;265;7;2;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;945;1239;9183595100;65;83;102;132;150;81;6;2;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;934;1758;9668065700;313;387;426;505;625;353;7;8;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;952;1268;9015161500;79;135;155;174;233;121;6;3;0;2 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;966;1534;9401550800;104;179;199;336;375;186;7;5;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;1027;1635;8949130900;249;277;316;417;444;258;5;5;0;4 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1;928;1173;8877697600;49;109;128;149;167;83;5;2;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;2;1070;1291;9164916500;97;114;167;249;276;120;8;3;0;3 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt index 5caab94d..187ae1ac 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/errors.txt @@ -1,55 +1,17 @@ -Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is not translated to logic! - hu.bme.mit.inf.dslreasoner.ecore2logic.EClassMapper_AllElementAsObject.TypeofEClass(EClassMapper_AllElementAsObject.java:63) - hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.TypeofEClass(Ecore2Logic.java:96) - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation.transform(InstanceModel2PartialInterpretation.java:99) - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic.transform(InstanceModel2Logic.java:19) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:192) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalArgumentException): Class FunctionalArchitectureModel is not translated to logic! - hu.bme.mit.inf.dslreasoner.ecore2logic.EClassMapper_AllElementAsObject.TypeofEClass(EClassMapper_AllElementAsObject.java:63) - hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic.TypeofEClass(Ecore2Logic.java:96) - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation.transform(InstanceModel2PartialInterpretation.java:99) - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic.transform(InstanceModel2Logic.java:19) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:192) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Error loading group hu.bme.mit.inf.dslreasoner.domains.alloyexamples.FileSystem - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$QueryGroupProvider.get(ExtensionBasedQuerySpecificationLoader.java:204) - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:282) - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:1) - org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:66) - org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:1) - org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) - org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) - org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl.(FileSystemImpl.java:55) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.createFileSystem(filesystemFactoryImpl.java:74) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.create(filesystemFactoryImpl.java:59) - hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) - hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (IllegalStateException): Error loading group hu.bme.mit.inf.dslreasoner.domains.alloyexamples.FileSystem - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$QueryGroupProvider.get(ExtensionBasedQuerySpecificationLoader.java:204) - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:282) - org.eclipse.viatra.query.runtime.registry.ExtensionBasedQuerySpecificationLoader$GroupBasedQuerySpecificationProvider.get(ExtensionBasedQuerySpecificationLoader.java:1) - org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:66) - org.eclipse.viatra.query.runtime.registry.data.RegistryEntryImpl.get(RegistryEntryImpl.java:1) - org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) - org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) - org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.FileSystemImpl.(FileSystemImpl.java:55) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.createFileSystem(filesystemFactoryImpl.java:74) - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl.filesystemFactoryImpl.create(filesystemFactoryImpl.java:59) - hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) - hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) +Error occured (NullPointerException): + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.lambda$8(QueryLoader.java:108) + org.eclipse.xtext.xbase.lib.internal.BooleanFunctionDelegate.apply(BooleanFunctionDelegate.java:41) + com.google.common.collect.Iterators$6.computeNext(Iterators.java:617) + com.google.common.collect.AbstractIterator.tryToComputeNext(AbstractIterator.java:145) + com.google.common.collect.AbstractIterator.hasNext(AbstractIterator.java:140) + com.google.common.collect.Iterators.addAll(Iterators.java:366) + com.google.common.collect.Iterables.addAll(Iterables.java:332) + com.google.common.collect.Sets.newLinkedHashSet(Sets.java:383) + org.eclipse.xtext.xbase.lib.IterableExtensions.toSet(IterableExtensions.java:592) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader._getPatterns(QueryLoader.java:84) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.getPatterns(QueryLoader.java:213) + hu.bme.mit.inf.dslreasoner.application.execution.QueryLoader.loadQueries(QueryLoader.java:54) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:167) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated index f90ed439..5ac9e1dc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated @@ -104,27 +104,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -152,21 +152,21 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or @@ -194,17 +194,17 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or @@ -232,17 +232,17 @@ private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or @@ -270,18 +270,18 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); @@ -310,25 +310,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -356,25 +356,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -403,9 +403,9 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); @@ -413,9 +413,9 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); @@ -445,20 +445,20 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -486,21 +486,21 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -528,25 +528,25 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -574,25 +574,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -620,19 +620,19 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -681,17 +681,17 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -740,19 +740,19 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -987,1963 +987,1406 @@ private pattern mayInRelationregions_reference_CompositeElement( ////////// // 1.3 Relation Definition Indexers ////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or - - { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or - - { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; } - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); - find mustInstanceOfTransition_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); } - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } -pattern createObject_Exit_class_by_vertices_reference_Region( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_r1) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } -pattern createObject_Exit_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_r1) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } -pattern createObject_FinalState_class_by_vertices_reference_Region( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_r) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); } -pattern createObject_FinalState_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_r) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_r) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; } -pattern createObject_Transition_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; } -pattern createObject_Region_class_by_regions_reference_CompositeElement( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); - find mustInstanceOfCompositeElement_class(problem,interpretation,container); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); } -pattern createObject_Region_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; } -pattern createObject_Choice_class_by_vertices_reference_Region( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_Choice_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_Synchronization_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Statechart_class_UndefinedPart( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Entry_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Entry_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); } -pattern createObject_State_class_by_vertices_reference_Region( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; } -pattern createObject_State_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_region) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); - PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfVertex_class(problem,interpretation,from); - find mustInstanceOfTransition_class(problem,interpretation,to); - find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); - neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); } - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "FileSystem class". - */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); - find directInstanceOf(problem,interpretation,element,type); +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -/** - * An element may be an instance of type "FileSystem class". - */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } -/** - * An element must be an instance of type "FSObject class". - */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); -} - -/** - * An element may be an instance of type "FSObject class". - */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Dir class". - */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); -} - -/** - * An element may be an instance of type "Dir class". - */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } -/** - * An element must be an instance of type "File class". - */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -/** - * An element may be an instance of type "File class". - */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); -} - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ -private pattern mustInRelationlive_reference_FileSystem( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } -/** - * Matcher for detecting tuples t where <>live reference FileSystem(source,target) - */ -private pattern mayInRelationlive_reference_FileSystem( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); -} or { - find mustInRelationlive_reference_FileSystem(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_v) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or - - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or - - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); } - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; } -pattern createObject_Model_class_UndefinedPart( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_v) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; } -pattern createObject_Dir_class_by_root_reference_FileSystem( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; } -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; } -pattern createObject_Dir_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_parent, var_child) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); } -pattern createObject_File_class_by_otherFSObjects_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -pattern createObject_File_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_s, var_v) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -pattern createObject_FileSystem_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_s, var_v) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); -} -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); } -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_live_reference_FileSystem( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_composite) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; } - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; -} - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); } - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); -} - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); -} - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "FileSystem class". - */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; } - -/** - * An element may be an instance of type "FileSystem class". - */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } -/** - * An element must be an instance of type "FSObject class". - */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; } -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); } - -/** - * An element may be an instance of type "FSObject class". - */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Dir class". - */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } -/** - * An element may be an instance of type "Dir class". - */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } -/** - * An element must be an instance of type "File class". - */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); } -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); } -/** - * An element may be an instance of type "File class". - */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); } -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); } -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); } - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); } -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { - find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ -private pattern mustInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where <>live reference FileSystem(source,target) - */ -private pattern mayInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); -} or { - find mustInRelationlive_reference_FileSystem(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) { - find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); -} - -////////// -// 1.3 Relation Definition Indexers -////////// - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or - - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or - - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); } -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// - ////////// // 3. Unfinishedness Indexers ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } @@ -2951,187 +2394,407 @@ pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicPro ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) { - find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Model_class_UndefinedPart( +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class_by_otherFSObjects_reference_Model( +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class( +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class_by_root_reference_FileSystem( +pattern createObject_Entry_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class( +pattern createObject_Transition_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( +pattern createObject_Region_class_by_regions_reference_CompositeElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FileSystem_class( +pattern createObject_Region_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -3139,58 +2802,126 @@ pattern createObject_FileSystem_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); } -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); } ////////// // 4.3 Relation refinement ////////// -pattern refineRelation_live_reference_FileSystem( +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); } import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" @@ -3298,27 +3029,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3346,9 +3077,9 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); @@ -3356,9 +3087,9 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); @@ -3388,16 +3119,16 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); @@ -3464,18 +3195,18 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); @@ -3504,25 +3235,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3550,25 +3281,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3598,8 +3329,8 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); @@ -3608,8 +3339,8 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); @@ -3638,21 +3369,21 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3682,8 +3413,8 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); @@ -3692,8 +3423,8 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); @@ -3722,25 +3453,25 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3768,25 +3499,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3815,18 +3546,18 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -3875,16 +3606,16 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -3934,18 +3665,18 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -5687,55 +5418,55 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustInstanceOfEntry_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); + find mustInstanceOfChoice_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); + find mustInstanceOfStatechart_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); + find mustInstanceOfVertex_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); + find mustInstanceOfPseudostate_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustInstanceOfTransition_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustInstanceOfRegularState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); + find mustInstanceOfRegion_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); + find mustInstanceOfSynchronization_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -5754,157 +5485,157 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Entry_class_by_vertices_reference_Region( +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class( +pattern createObject_State_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class_by_vertices_reference_Region( +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class( +pattern createObject_Transition_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_State_class_by_vertices_reference_Region( +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_State_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Statechart_class_UndefinedPart( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class( +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class_by_regions_reference_CompositeElement( +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); - find mustInstanceOfCompositeElement_class(problem,interpretation,container); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - find mayInstanceOfRegion_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -5936,59 +5667,59 @@ pattern createObject_FinalState_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class_by_vertices_reference_Region( +pattern createObject_Region_class_by_regions_reference_CompositeElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class( +pattern createObject_Region_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +pattern createObject_Entry_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class( +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -5996,31 +5727,14 @@ pattern createObject_Synchronization_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); -} -pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); } pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); @@ -6029,72 +5743,89 @@ pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInt neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); -} -pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); } pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); } -pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); } -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); } ////////// @@ -6223,27 +5954,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6271,21 +6002,21 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6313,17 +6044,17 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6351,16 +6082,16 @@ private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); @@ -6391,8 +6122,8 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -6400,8 +6131,8 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6429,25 +6160,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6475,25 +6206,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6523,9 +6254,9 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -6533,9 +6264,9 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6563,21 +6294,21 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6607,9 +6338,9 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -6617,9 +6348,9 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6647,25 +6378,25 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6693,25 +6424,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6739,19 +6470,19 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -6801,16 +6532,16 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -6860,18 +6591,18 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -8612,55 +8343,55 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustInstanceOfEntry_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); + find mustInstanceOfChoice_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); + find mustInstanceOfStatechart_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); + find mustInstanceOfVertex_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); + find mustInstanceOfPseudostate_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustInstanceOfTransition_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustInstanceOfRegularState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); + find mustInstanceOfRegion_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); + find mustInstanceOfSynchronization_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -8679,115 +8410,115 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_State_class_by_vertices_reference_Region( +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_State_class( +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class_by_vertices_reference_Region( +pattern createObject_State_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class( +pattern createObject_State_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class_by_vertices_reference_Region( +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class_by_vertices_reference_Region( +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -8803,61 +8534,59 @@ pattern createObject_Statechart_class_UndefinedPart( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class_by_vertices_reference_Region( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class( +pattern createObject_FinalState_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +pattern createObject_Entry_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class( +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -8889,31 +8618,33 @@ pattern createObject_Region_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class( +pattern createObject_Transition_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -8921,105 +8652,105 @@ pattern createObject_Synchronization_class( ////////// // 4.2 Type refinement ////////// +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); +} pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); -} -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); } pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } ////////// @@ -9148,27 +8879,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9196,21 +8927,21 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9238,17 +8969,17 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9314,19 +9045,19 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9354,25 +9085,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9400,25 +9131,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9446,21 +9177,21 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9488,21 +9219,21 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9530,21 +9261,21 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9572,25 +9303,25 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9618,25 +9349,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9664,19 +9395,19 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -9725,16 +9456,16 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -9784,18 +9515,18 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -11537,55 +11268,55 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustInstanceOfEntry_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); + find mustInstanceOfChoice_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); + find mustInstanceOfStatechart_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); + find mustInstanceOfVertex_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); + find mustInstanceOfPseudostate_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustInstanceOfTransition_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustInstanceOfRegularState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); + find mustInstanceOfRegion_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); + find mustInstanceOfSynchronization_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -11604,145 +11335,173 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Entry_class_by_vertices_reference_Region( +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class_by_vertices_reference_Region( +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class( +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +pattern createObject_Entry_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class( +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +pattern createObject_Region_class_by_regions_reference_CompositeElement( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class( +pattern createObject_Region_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class_by_vertices_reference_Region( +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -11758,31 +11517,31 @@ pattern createObject_Statechart_class_UndefinedPart( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class_by_regions_reference_CompositeElement( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); - find mustInstanceOfCompositeElement_class(problem,interpretation,container); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class( +pattern createObject_FinalState_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - find mayInstanceOfRegion_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -11814,137 +11573,109 @@ pattern createObject_State_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class_by_vertices_reference_Region( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Exit_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); } pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } -pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); } pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); -} -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); } ////////// @@ -12075,12 +11806,12 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -12088,12 +11819,12 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12121,21 +11852,21 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12201,17 +11932,17 @@ private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12239,19 +11970,19 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12281,11 +12012,11 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -12293,11 +12024,11 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12326,24 +12057,24 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12371,21 +12102,21 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12413,21 +12144,21 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12455,20 +12186,20 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); @@ -12499,11 +12230,11 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -12511,11 +12242,11 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12545,11 +12276,11 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { @@ -12557,11 +12288,11 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12589,19 +12320,19 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -12651,16 +12382,16 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -12710,8 +12441,8 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -12719,8 +12450,8 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -14462,55 +14193,55 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustInstanceOfEntry_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); + find mustInstanceOfChoice_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); + find mustInstanceOfStatechart_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); + find mustInstanceOfVertex_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); + find mustInstanceOfPseudostate_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustInstanceOfTransition_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustInstanceOfRegularState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); + find mustInstanceOfRegion_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); + find mustInstanceOfSynchronization_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -14529,6 +14260,34 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, @@ -14587,59 +14346,31 @@ pattern createObject_Synchronization_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_State_class_by_vertices_reference_Region( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_State_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Exit_class_by_vertices_reference_Region( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class( +pattern createObject_FinalState_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -14671,31 +14402,15 @@ pattern createObject_Choice_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class_by_vertices_reference_Region( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FinalState_class( +pattern createObject_Statechart_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -14755,15 +14470,31 @@ pattern createObject_Entry_class( find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Statechart_class_UndefinedPart( +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -14771,14 +14502,25 @@ pattern createObject_Statechart_class_UndefinedPart( ////////// // 4.2 Type refinement ////////// +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); +} pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); } pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); @@ -14786,36 +14528,22 @@ pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation: find mayInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); } -pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); -} -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); } pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); @@ -14823,31 +14551,30 @@ pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialIn find mayInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); } pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); } pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); @@ -14855,21 +14582,25 @@ pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInt find mayInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); } -pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); } ////////// @@ -14998,27 +14729,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15046,21 +14777,21 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15088,17 +14819,17 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15127,16 +14858,16 @@ private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretati find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewTransition_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15164,19 +14895,19 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15204,25 +14935,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15250,25 +14981,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15296,21 +15027,21 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15338,21 +15069,21 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15380,21 +15111,21 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15422,25 +15153,25 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15468,25 +15199,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15514,19 +15245,19 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); } or @@ -15634,18 +15365,18 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); @@ -17387,15 +17118,15 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustInstanceOfEntry_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); + find mustInstanceOfChoice_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -17403,39 +17134,39 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); + find mustInstanceOfStatechart_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); + find mustInstanceOfVertex_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); + find mustInstanceOfPseudostate_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); + find mustInstanceOfTransition_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustInstanceOfRegularState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustInstanceOfRegion_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustInstanceOfSynchronization_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); @@ -17454,241 +17185,241 @@ private pattern hasElementInContainment(problem:LogicProblem, interpretation:Par find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_State_class_by_vertices_reference_Region( +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_State_class( +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class_by_vertices_reference_Region( +pattern createObject_Entry_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FinalState_class( +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Synchronization_class( +pattern createObject_FinalState_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class_by_regions_reference_CompositeElement( +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); - find mustInstanceOfCompositeElement_class(problem,interpretation,container); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Region_class( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - find mayInstanceOfRegion_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class_by_vertices_reference_Region( +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Entry_class( +pattern createObject_Region_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class_by_vertices_reference_Region( +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Exit_class( +pattern createObject_Transition_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class_by_vertices_reference_Region( +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Choice_class( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +pattern createObject_State_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Transition_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Statechart_class_UndefinedPart( +pattern createObject_State_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -17696,105 +17427,105 @@ pattern createObject_Statechart_class_UndefinedPart( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } -pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfRegion_class(problem,interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); } -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); } -pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); -} -pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } -pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); } ////////// @@ -17923,27 +17654,27 @@ private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretat { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewPseudostate_class(problem, interpretation); neg find isPrimitive(element); } or @@ -17972,9 +17703,9 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); @@ -17982,9 +17713,9 @@ private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:P find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewVertex_class(problem, interpretation); neg find isPrimitive(element); @@ -18014,16 +17745,16 @@ private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:P find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewRegion_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18089,19 +17820,19 @@ private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretati { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18129,25 +17860,25 @@ private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewEntry_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18175,25 +17906,25 @@ private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpr { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewSynchronization_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18221,20 +17952,20 @@ private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:Pa { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewState_class(problem, interpretation); neg find isPrimitive(element); @@ -18263,20 +17994,20 @@ private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpreta { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewRegularState_class(problem, interpretation); neg find isPrimitive(element); @@ -18305,21 +18036,21 @@ private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interp { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18348,24 +18079,24 @@ private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:P find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find scopeDisallowsNewChoice_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18393,25 +18124,25 @@ private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:Par { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); neg find scopeDisallowsNewExit_class(problem, interpretation); neg find isPrimitive(element); } or @@ -18440,8 +18171,8 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); @@ -18449,8 +18180,8 @@ private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretati find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfPseudostate_class(problem,interpretation,element); neg find scopeDisallowsNewFinalState_class(problem, interpretation); neg find isPrimitive(element); @@ -18500,17 +18231,17 @@ private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfRegion_class(problem,interpretation,element); neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -18559,19 +18290,19 @@ private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicP { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find mustInstanceOfTransition_class(problem,interpretation,element); neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or @@ -20273,1233 +20004,2736 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_ { find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, - var_s, var_v1, var_v2) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, - var_s) +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, - var_s, var_v1, var_v2) +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, - var_s, var_v) +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, - var_s) +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, - var_s1, var_s2) +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } ////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors +// 1.3 Relation Definition Indexers ////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) { find interpretation(problem,interpretation); - find mustInstanceOfPseudostate_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfEntry_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfTransition_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfChoice_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfRegularState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ find interpretation(problem,interpretation); - find mustInstanceOfRegion_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ find interpretation(problem,interpretation); - find mustInstanceOfVertex_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - find mustInstanceOfExit_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - find mustInstanceOfFinalState_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - find mustInstanceOfSynchronization_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ find interpretation(problem,interpretation); - find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ find interpretation(problem,interpretation); - find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); } -pattern createObject_Choice_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfChoice_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; } -pattern createObject_Choice_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); - find mayInstanceOfChoice_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_Statechart_class_UndefinedPart( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_FinalState_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -pattern createObject_FinalState_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); - find mayInstanceOfFinalState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Region_class_by_regions_reference_CompositeElement( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); - find mustInstanceOfCompositeElement_class(problem,interpretation,container); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Region_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); - find mayInstanceOfRegion_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -pattern createObject_Entry_class_by_vertices_reference_Region( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfEntry_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); } -pattern createObject_Entry_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); - find mayInstanceOfEntry_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; } -pattern createObject_Exit_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; } -pattern createObject_Exit_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); - find mayInstanceOfExit_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern createObject_State_class_by_vertices_reference_Region( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -pattern createObject_State_class( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_e) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); - find mayInstanceOfState_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_f) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); - find mustInstanceOfVertex_class(problem,interpretation,container); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern createObject_Transition_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_t, var_f) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); - find mayInstanceOfTransition_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -pattern createObject_Synchronization_class_by_vertices_reference_Region( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_t, var_f) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); - find mustInstanceOfRegion_class(problem,interpretation,container); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); - find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -pattern createObject_Synchronization_class( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_region) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); - find mayInstanceOfSynchronization_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); -} - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } -pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); } -pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } -pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfFinalState_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfState_class(problem,interpretation,element); - neg find mustInstanceOfStatechart_class(problem,interpretation,element); - neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } -pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfVertex_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } -pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfSynchronization_class(problem,interpretation,element); - neg find mustInstanceOfChoice_class(problem,interpretation,element); - neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); - neg find mustInstanceOfRegion_class(problem,interpretation,element); - neg find mustInstanceOfEntry_class(problem,interpretation,element); - neg find mustInstanceOfExit_class(problem,interpretation,element); - neg find mustInstanceOfTransition_class(problem,interpretation,element); - neg find mustInstanceOfRegularState_class(problem,interpretation,element); - neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_c) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); - PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); - PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfVertex_class(problem,interpretation,from); - find mustInstanceOfTransition_class(problem,interpretation,to); - find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); - neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "FileSystem class". - */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); - find directInstanceOf(problem,interpretation,element,type); +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } - -/** - * An element may be an instance of type "FileSystem class". - */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } -/** - * An element must be an instance of type "FSObject class". - */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); } - -/** - * An element may be an instance of type "FSObject class". - */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Dir class". - */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } - -/** - * An element may be an instance of type "Dir class". - */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } -/** - * An element must be an instance of type "File class". - */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } - -/** - * An element may be an instance of type "File class". - */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); -} - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mustInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mayInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_composite) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_composite) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_composite) { find interpretation(problem,interpretation); - find mayInstanceOfFSObject_class(problem,interpretation,var_o1); - find mayInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mayInstanceOfDir_class(problem,interpretation,var_o1); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_o2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_s) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; -} -private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) + var_s) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; }or{ find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_l); -}or{ + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_root); - find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; }or{ find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } ////////// @@ -21511,13 +22745,11 @@ private pattern mustContains2(source: DefinedElement, target: DefinedElement) { private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } private pattern mustTransitiveContains(source,target) { find mustContains2+(source,target); @@ -21528,10 +22760,95 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); } ////////// @@ -21539,21 +22856,12 @@ pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesys ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } @@ -21561,3140 +22869,2796 @@ pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicPro ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); } - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) { - find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); } -pattern createObject_FileSystem_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) { - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); } -pattern createObject_File_class_by_otherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); } -pattern createObject_File_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); } -pattern createObject_Model_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); } -pattern createObject_Dir_class_by_root_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); } -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); } -pattern createObject_Dir_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) { - find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); } ////////// -// 4.2 Type refinement +// 4. Refinement Indexers ////////// -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { - find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); -} -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); -} -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); -} -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); -} - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_live_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); -} - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; -} - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); -} - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); -} - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); -} - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "FileSystem class". - */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); -} - -/** - * An element may be an instance of type "FileSystem class". - */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or { + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } -/** - * An element must be an instance of type "FSObject class". - */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); -} - -/** - * An element may be an instance of type "FSObject class". - */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Dir class". - */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); } - -/** - * An element may be an instance of type "Dir class". - */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } -/** - * An element must be an instance of type "File class". - */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } - -/** - * An element may be an instance of type "File class". - */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); -} - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( +pattern createObject_State_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mustInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mayInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( +pattern createObject_Exit_class( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( +pattern createObject_Statechart_class_UndefinedPart( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" ////////// -// 1.3 Relation Definition Indexers +// 0. Util ////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) -{ + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - find mayInstanceOfFSObject_class(problem,interpretation,var_o1); - find mayInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mayInstanceOfDir_class(problem,interpretation,var_o1); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_o2); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( - problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) -{ + LogicProblem.elements(problem,element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; + PartialInterpretation.newElements(interpretation,element); } -private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); } -private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); } -private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; -}or{ + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_l); -}or{ + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_root); - find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; -}or{ + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( - problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( - problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) -{ - find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( - problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); -} - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); } - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or - - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or - - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); } -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); -} - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) -{ - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); } -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_Model_class_UndefinedPart( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_File_class_by_otherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_File_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_FileSystem_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_Dir_class_by_root_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); -} -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( - problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) -{ + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern createObject_Dir_class( - problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) -{ +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); } -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); -} -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); } -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); } -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_live_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) -{ +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); } -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); -} - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); } or { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); } - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); } -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); } or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); } -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); } - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); } -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); } or { find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); } - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); } -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// /** - * An element must be an instance of type "FileSystem class". + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); + Type.name(type,"Statechart class UndefinedPart"); } /** - * An element may be an instance of type "FileSystem class". + * An element may be an instance of type "Statechart class UndefinedPart". */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or { find interpretation(problem,interpretation); PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); neg find isPrimitive(element); } or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + /** - * An element must be an instance of type "FSObject class". + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); find directInstanceOf(problem,interpretation,element,type); } -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); PartialInterpretation.scopes(interpretation,scope); Scope.targetTypeInterpretation(scope,typeInterpretation); Scope.maxNewElements(scope,0); PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "FSObject class". + * Matcher for detecting tuples t where <>target reference Transition(source,target) */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} /** - * An element must be an instance of type "Dir class". + * Matcher for detecting tuples t where []source reference Transition(source,target) */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "Dir class". + * Matcher for detecting tuples t where <>source reference Transition(source,target) */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} /** - * An element must be an instance of type "File class". + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); } - /** - * An element may be an instance of type "File class". + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); } or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; } -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); } -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_t, var_src, var_trg) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mustInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mayInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_t, var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_e) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_e) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_e) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_e, var_t1, var_t2) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_t, var_e) { find interpretation(problem,interpretation); - find mayInstanceOfFSObject_class(problem,interpretation,var_o1); - find mayInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mayInstanceOfDir_class(problem,interpretation,var_o1); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_o2); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_t, var_e) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; -} -private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) + var_t, var_e) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_l); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_root); - find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_t, var_f) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_t, var_f) { find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) -{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); -} - -////////// -// 1.4 Containment Indexer -////////// -private pattern mustContains2(source: DefinedElement, target: DefinedElement) { - find mustContains4(_,_,source,target); -} - -private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or - - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or - - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } - -private pattern mustTransitiveContains(source,target) { - find mustContains2+(source,target); -} - -////////// -// 2. Invalidation Indexers -////////// -// 2.1 Invalidated by WF Queries -////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_t, var_f) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); -} - -////////// -// 3. Unfinishedness Indexers -////////// -// 3.1 Unfinishedness Measured by Multiplicity -////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} - -////////// -// 3.2 Unfinishedness Measured by WF Queries -////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) -{ - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; } - -////////// -// 4. Refinement Indexers -////////// -// 4.1 Object constructors -////////// -private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) { find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); - find mustExist(problem, interpretation, root); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern createObject_Dir_class_by_root_reference_FileSystem( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_region) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_region) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); } -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_region, var_state) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } -pattern createObject_Dir_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_region, var_state) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_region, var_state) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; } -pattern createObject_File_class_by_otherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_c) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } -pattern createObject_File_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_c) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } -pattern createObject_Model_class_UndefinedPart( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_c) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, - container:DefinedElement) + var_c) { find interpretation(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); - find mustExist(problem, interpretation, container); - neg find mustExist(problem, interpretation, newObject); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } -pattern createObject_FileSystem_class( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - typeInterpretation:PartialComplexTypeInterpretation) + var_c) { find interpretation(problem,interpretation); - neg find hasElementInContainment(problem,interpretation); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayExist(problem, interpretation, newObject); - neg find mustExist(problem, interpretation, newObject); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } - -////////// -// 4.2 Type refinement -////////// -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); } -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); } - -////////// -// 4.3 Relation refinement -////////// -pattern refineRelation_live_reference_FileSystem( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, - from: DefinedElement, to: DefinedElement) + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); - find mustExist(problem, interpretation, from); - find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); -} -import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" -import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" - -////////// -// 0. Util -////////// -private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { - PartialInterpretation.problem(interpretation,problem); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } - -///////////////////////// -// 0.1 Existence -///////////////////////// -private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find interpretation(problem,interpretation); - LogicProblem.elements(problem,element); -} or { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); -} - -private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - find mustExist(problem,interpretation,element); -} or { - find interpretation(problem,interpretation); - neg find elementCloseWorld(element); - PartialInterpretation.openWorldElements(interpretation,element); -} - -private pattern elementCloseWorld(element:DefinedElement) { - PartialInterpretation.openWorldElements(i,element); - PartialInterpretation.maxNewElements(i,0); -} or { - Scope.targetTypeInterpretation(scope,interpretation); - PartialTypeInterpratation.elements(interpretation,element); - Scope.maxNewElements(scope,0); -} - -//////////////////////// -// 0.2 Equivalence -//////////////////////// -pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { - find mayExist(problem,interpretation,a); - find mayExist(problem,interpretation,b); - a == b; + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } - -//////////////////////// -// 0.3 Required Patterns by TypeIndexer -//////////////////////// -private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); } - -private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { - find interpretation(problem,interpretation); - LogicProblem.types(problem,type); - TypeDefinition.elements(type,element); -} or { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ find interpretation(problem,interpretation); - find typeInterpretation(problem,interpretation,type,typeInterpretation); - PartialComplexTypeInterpretation.elements(typeInterpretation,element); -} - -private pattern isPrimitive(element: PrimitiveElement) { - PrimitiveElement(element); -} - -////////// -// 1. Problem-Specific Base Indexers -////////// -// 1.1 Type Indexers -////////// -// 1.1.1 primitive Type Indexers -////////// - -////////// -// 1.1.2 domain-specific Type Indexers -////////// -/** - * An element must be an instance of type "FileSystem class". - */ -private pattern mustInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FileSystem class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FileSystem class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } - -/** - * An element may be an instance of type "FileSystem class". - */ -private pattern mayInstanceOfFileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewFileSystem_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFileSystem_class(problem,interpretation,element); } -/** - * An element must be an instance of type "FSObject class". - */ -private pattern mustInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"FSObject class"); - find directInstanceOf(problem,interpretation,element,type); -} -private pattern scopeDisallowsNewFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"FSObject class"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); } - -/** - * An element may be an instance of type "FSObject class". - */ -private pattern mayInstanceOfFSObject_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or { + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFSObject_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFSObject_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Dir class". - */ -private pattern mustInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Dir class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; } -private pattern scopeDisallowsNewDir_class(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Dir class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } - -/** - * An element may be an instance of type "Dir class". - */ -private pattern mayInstanceOfDir_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewDir_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfDir_class(problem,interpretation,element); } -/** - * An element must be an instance of type "File class". - */ -private pattern mustInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"File class"); - find directInstanceOf(problem,interpretation,element,type); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } -private pattern scopeDisallowsNewFile_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"File class"); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); } - -/** - * An element may be an instance of type "File class". - */ -private pattern mayInstanceOfFile_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find scopeDisallowsNewFile_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfFile_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class". - */ -private pattern mustInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); } -private pattern scopeDisallowsNewModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } - -/** - * An element may be an instance of type "Model class". - */ -private pattern mayInstanceOfModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class DefinedPart". - */ -private pattern mustInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class DefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; } -private pattern scopeDisallowsNewModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class DefinedPart"); -} - -/** - * An element may be an instance of type "Model class DefinedPart". - */ -private pattern mayInstanceOfModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) -{ find mustInstanceOfModel_class_DefinedPart(problem,interpretation,element); } -/** - * An element must be an instance of type "Model class UndefinedPart". - */ -private pattern mustInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { - Type.name(type,"Model class UndefinedPart"); - find directInstanceOf(problem,interpretation,element,type); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); } -private pattern scopeDisallowsNewModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ find interpretation(problem,interpretation); - PartialInterpretation.scopes(interpretation,scope); - Scope.targetTypeInterpretation(scope,typeInterpretation); - Scope.maxNewElements(scope,0); - PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); - Type.name(type,"Model class UndefinedPart"); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; } - -/** - * An element may be an instance of type "Model class UndefinedPart". - */ -private pattern mayInstanceOfModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) { find interpretation(problem,interpretation); - PartialInterpretation.newElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or { - find interpretation(problem,interpretation); - PartialInterpretation.openWorldElements(interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); - neg find scopeDisallowsNewModel_class_UndefinedPart(problem, interpretation); - neg find isPrimitive(element); -} or -{ find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); } - -////////// -// 1.2 Relation Declaration Indexers -////////// -/** - * Matcher for detecting tuples t where []root reference FileSystem(source,target) - */ -private pattern mustInRelationroot_reference_FileSystem( + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); } -/** - * Matcher for detecting tuples t where <>root reference FileSystem(source,target) - */ -private pattern mayInRelationroot_reference_FileSystem( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFileSystem_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mustInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []live reference FileSystem(source,target) - */ - private pattern mayInRelationlive_reference_FileSystem( - problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) - { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,source,target); - } -/** - * Matcher for detecting tuples t where []parent reference FSObject(source,target) - */ -private pattern mustInRelationparent_reference_FSObject( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v1, var_v2) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FSObject"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; } -/** - * Matcher for detecting tuples t where <>parent reference FSObject(source,target) - */ -private pattern mayInRelationparent_reference_FSObject( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfFSObject_class(problem,interpretation,source); - find mayInstanceOfDir_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The eOpposite of the reference is containment, then a referene cannot be created if - // 1. Multiple parents - neg find mustContains4(problem,interpretation,source,_); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationparent_reference_FSObject(problem,interpretation,source,target); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -/** - * Matcher for detecting tuples t where []contents reference Dir(source,target) - */ -private pattern mustInRelationcontents_reference_Dir( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"contents reference Dir"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); } -/** - * Matcher for detecting tuples t where <>contents reference Dir(source,target) - */ -private pattern mayInRelationcontents_reference_Dir( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_parent, var_child) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfDir_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference to the target, - // the upper bound of the opposite reference multiplicity should be considered. - numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FSObject(problem,interpretation,target,_); - check(numberOfExistingOppositeReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; } -/** - * Matcher for detecting tuples t where []filesystems reference Model(source,target) - */ -private pattern mustInRelationfilesystems_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where <>filesystems reference Model(source,target) - */ -private pattern mayInRelationfilesystems_reference_Model( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFileSystem_class(problem,interpretation,target); - // There are "numberOfExistingReferences" currently existing instances of the reference from the source, - // the upper bound of the multiplicity should be considered. - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,source,_); - check(numberOfExistingReferences < 1); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where []otherFSObjects reference Model(source,target) - */ -private pattern mustInRelationotherFSObjects_reference_Model( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_s, var_v) { find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"otherFSObjects reference Model"); - PartialRelationInterpretation.relationlinks(relationIterpretation,link); - BinaryElementRelationLink.param1(link,source); - BinaryElementRelationLink.param2(link,target); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); } -/** - * Matcher for detecting tuples t where <>otherFSObjects reference Model(source,target) - */ -private pattern mayInRelationotherFSObjects_reference_Model( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - source: DefinedElement, target:DefinedElement) + var_composite) { find interpretation(problem,interpretation); - // The two endpoint of the link have to exist - find mayExist(problem, interpretation, source); - find mayExist(problem, interpretation, target); - // Type consistency - find mayInstanceOfModel_class(problem,interpretation,source); - find mayInstanceOfFSObject_class(problem,interpretation,target); - // The reference is containment, then a new reference cannot be create if: - // 1. Multiple parents - neg find mustContains4(problem,interpretation,_,target); - // 2. Circle in the containment hierarchy - neg find mustTransitiveContains(source,target); -} or { - find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); } - -////////// -// 1.3 Relation Definition Indexers -////////// -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries patternContent -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_composite) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_composite) { find interpretation(problem,interpretation); - find mayInstanceOfFSObject_class(problem,interpretation,var_o1); - find mayInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mayInstanceOfDir_class(problem,interpretation,var_o1); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_o2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( problem:LogicProblem, interpretation:PartialInterpretation, - var_o1, var_o2) + var_s) { find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,var_o1); - find mustInstanceOfFSObject_class(problem,interpretation,var_o2); - // o1 is exported - // o2 is exported - find mustInstanceOfDir_class(problem,interpretation,var_o1); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_o1,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_o2; -} -private pattern twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); -} -private pattern twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(var_o1, var_o2) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent(_,_,var_o1, var_o2); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries live -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) + var_s) { find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; }or{ find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_l); -}or{ + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ find interpretation(problem,interpretation); - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mayInstanceOfFileSystem_class(problem,interpretation,var_this); - find mayInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mayInstanceOfDir_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_root); - find twoParam_mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); -} -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live( - problem:LogicProblem, interpretation:PartialInterpretation, - var_this, var_l) -{ - find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_l; + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; }or{ find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInstanceOfFSObject_class(problem,interpretation,var_l); - // this is exported - // l is exported - find mustInstanceOfFileSystem_class(problem,interpretation,var_this); - find mustInRelationroot_reference_FileSystem(problem,interpretation,var_this,var_virtual0); - find mustInstanceOfDir_class(problem,interpretation,var_virtual0); - var_virtual0 == var_root; - find twoParam_currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_patternContent+(var_root,var_l); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; } -// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test filesystem queries contentInNotLive -private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); } -private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mayInstanceOfDir_class(problem,interpretation,var_parent); - find mayInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mayInstanceOfFSObject_class(problem,interpretation,var_virtual0); - find mayEquivalent(problem, interpretation, var_virtual0, var_child); - neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } -private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive( +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) + var_s1, var_s2) { find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_parent); -}or{ - find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInstanceOfFSObject_class(problem,interpretation,var_child); - // parent is exported - // child is exported - find mustInstanceOfDir_class(problem,interpretation,var_parent); - find mustInRelationcontents_reference_Dir(problem,interpretation,var_parent,var_virtual0); - find mustInstanceOfFSObject_class(problem,interpretation,var_virtual0); - var_virtual0 == var_child; - neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_live(problem,interpretation,_var__0,var_child); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; } ////////// @@ -24706,13 +25670,11 @@ private pattern mustContains2(source: DefinedElement, target: DefinedElement) { private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, source: DefinedElement, target: DefinedElement) - { find mustInRelationroot_reference_FileSystem(problem,interpretation,source,target); }or - - { find mustInRelationcontents_reference_Dir(problem,interpretation,source,target); }or + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or - { find mustInRelationfilesystems_reference_Model(problem,interpretation,source,target); }or + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or - { find mustInRelationotherFSObjects_reference_Model(problem,interpretation,source,target); } + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } private pattern mustTransitiveContains(source,target) { find mustContains2+(source,target); @@ -24723,10 +25685,95 @@ private pattern mustTransitiveContains(source,target) { ////////// // 2.1 Invalidated by WF Queries ////////// -pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) { - find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); } ////////// @@ -24734,21 +25781,12 @@ pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesys ////////// // 3.1 Unfinishedness Measured by Multiplicity ////////// -pattern unfinishedLowerMultiplicity_root_reference_FileSystem(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { - find interpretation(problem,interpretation); - PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationroot_reference_FileSystem(problem,interpretation,object,_); - check(numberOfExistingReferences < 1); - missingMultiplicity == eval(1-numberOfExistingReferences); -} -pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,object); - numberOfExistingReferences == count find mustInRelationfilesystems_reference_Model(problem,interpretation,object,_); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); check(numberOfExistingReferences < 1); missingMultiplicity == eval(1-numberOfExistingReferences); } @@ -24756,10 +25794,95 @@ pattern unfinishedLowerMultiplicity_filesystems_reference_Model(problem:LogicPro ////////// // 3.2 Unfinishedness Measured by WF Queries ////////// -pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem:LogicProblem, interpretation:PartialInterpretation, - var_parent, var_child) +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) { - find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesystem_queries_contentInNotLive(problem,interpretation,var_parent,var_child); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); } ////////// @@ -24770,178 +25893,308 @@ pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_filesyst private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) { find interpretation(problem,interpretation); - find mustInstanceOfModel_class(problem,interpretation,root); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFile_class(problem,interpretation,root); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFSObject_class(problem,interpretation,root); + find mustInstanceOfFinalState_class(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfFileSystem_class(problem,interpretation,root); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfDir_class(problem,interpretation,root); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfModel_class_DefinedPart(problem,interpretation,root); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); }or{ find interpretation(problem,interpretation); - find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,root); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); find mustExist(problem, interpretation, root); } -pattern createObject_Dir_class_by_root_reference_FileSystem( +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"root reference FileSystem"); - find mustInstanceOfFileSystem_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationroot_reference_FileSystem(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class_by_contents_reference_Dir_with_parent_reference_FSObject( +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class_by_otherFSObjects_reference_Model( +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfDir_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Dir_class( +pattern createObject_State_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Dir class"); - find mayInstanceOfDir_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FileSystem_class_by_filesystems_reference_Model( +pattern createObject_Choice_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"filesystems reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); - find mayInRelationfilesystems_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_FileSystem_class( +pattern createObject_Choice_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FileSystem class"); - find mayInstanceOfFileSystem_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_Model_class_UndefinedPart( +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Model class UndefinedPart"); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class_by_contents_reference_Dir_with_parent_reference_FSObject( +pattern createObject_FinalState_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, - relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"contents reference Dir"); - PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); - PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FSObject"); - find mustInstanceOfDir_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationcontents_reference_Dir(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class_by_otherFSObjects_reference_Model( +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( problem:LogicProblem, interpretation:PartialInterpretation, relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, container:DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); - PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"otherFSObjects reference Model"); - find mustInstanceOfModel_class(problem,interpretation,container); - find mayInstanceOfFile_class(problem,interpretation,newObject); - find mayInRelationotherFSObjects_reference_Model(problem,interpretation,container,newObject); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); find mustExist(problem, interpretation, container); neg find mustExist(problem, interpretation, newObject); } -pattern createObject_File_class( +pattern createObject_Synchronization_class( problem:LogicProblem, interpretation:PartialInterpretation, typeInterpretation:PartialComplexTypeInterpretation) { find interpretation(problem,interpretation); neg find hasElementInContainment(problem,interpretation); PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); - PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"File class"); - find mayInstanceOfFile_class(problem,interpretation,newObject); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); find mayExist(problem, interpretation, newObject); neg find mustExist(problem, interpretation, newObject); } @@ -24949,56 +26202,124 @@ pattern createObject_File_class( ////////// // 4.2 Type refinement ////////// -pattern refineTypeTo_Dir_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } -pattern refineTypeTo_FileSystem_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_Model_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfModel_class_UndefinedPart(problem,interpretation,element); - neg find mustInstanceOfFSObject_class(problem,interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); } -pattern refineTypeTo_File_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.newElements(interpretation,element); - find mayInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfDir_class(problem,interpretation,element); - neg find mustInstanceOfFileSystem_class(problem,interpretation,element); - neg find mustInstanceOfFile_class(problem,interpretation,element); - neg find mustInstanceOfModel_class(problem,interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); } ////////// // 4.3 Relation refinement ////////// -pattern refineRelation_live_reference_FileSystem( +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( problem:LogicProblem, interpretation:PartialInterpretation, - relationIterpretation:PartialRelationInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, from: DefinedElement, to: DefinedElement) { find interpretation(problem,interpretation); PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); - PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"live reference FileSystem"); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); find mustExist(problem, interpretation, from); find mustExist(problem, interpretation, to); - find mustInstanceOfFileSystem_class(problem,interpretation,from); - find mustInstanceOfFSObject_class(problem,interpretation,to); - find mayInRelationlive_reference_FileSystem(problem,interpretation,from,to); - neg find mustInRelationlive_reference_FileSystem(problem,interpretation,from,to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem index 991c88fd..2079fe25 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem @@ -1,23 +1,33 @@ - - - - - - - - + + + + + + + + + + + + + + + + + + - + - + - + @@ -25,24 +35,24 @@ - + - + - + - + - + - + @@ -56,24 +66,24 @@ - + - + - + - + - + - + @@ -87,220 +97,1358 @@ - + - + - - - - - - - - - - + + + + + + + + + + + + - + - - - - + - - + + - - - - - - - - - - + + + + - - - - - + + + - + - - - - + - - - - - - - + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + + + + - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - + - + - - - - - - + + - + + - - - + + + + + + + + + + - - + + - + + + + + - - - - - - - - + + + + - - - - - - - - - + + + - - - + + + + + + + + + - - + - - + - - - - - - + + + + + + - + - + - - - - - + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + + - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel index 6c0e5571..5479fb8d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/init.partialmodel @@ -1,5 +1,5 @@ - + @@ -37,25 +37,53 @@ - + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -66,4 +94,13 @@ + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt index 162931cc..977a3efc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt @@ -1 +1 @@ -Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Model generation startedProblem is consistent, 2 models are generated!Model generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is inconsistent, no model is created!Model generation finishedModel generation startedProblem is inconsistent, no model is created!Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finished \ No newline at end of file +Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml index e73f85db..897aa2d4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml @@ -150,8 +150,8 @@ graph id 4 graphics [ - w 107.80000000000001 - h 40 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -171,7 +171,9 @@ graph LabelGraphics [ text " - Region class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -186,7 +188,7 @@ graph id 5 graphics [ - w 154.0 + w 146.3 h 68 type "rectangle" fill "#FFFFFF" @@ -207,9 +209,9 @@ graph LabelGraphics [ text " + Pseudostate class Vertex class - RegularState class - FinalState class + Entry class " fontSize 14 fontName "Consolas" @@ -224,8 +226,44 @@ graph id 6 graphics [ - w 154.0 - h 68 + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -246,8 +284,10 @@ graph [ text " Vertex class + State class RegularState class - FinalState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -259,7 +299,7 @@ graph node [ - id 7 + id 8 graphics [ w 112.2 @@ -294,7 +334,7 @@ graph node [ - id 8 + id 9 graphics [ w 85.80000000000001 @@ -329,7 +369,7 @@ graph node [ - id 9 + id 10 graphics [ w 103.4 @@ -364,7 +404,7 @@ graph node [ - id 10 + id 11 graphics [ w 103.4 @@ -399,7 +439,46 @@ graph edge [ source 4 - target 5 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 graphics [ fill "#000000" @@ -419,7 +498,7 @@ graph edge [ source 3 - target 6 + target 5 graphics [ fill "#000000" @@ -438,8 +517,8 @@ graph ] edge [ - source 0 - target 3 + source 3 + target 7 graphics [ fill "#000000" @@ -448,7 +527,7 @@ graph ] LabelGraphics [ - text "regions reference CompositeElement" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -458,9 +537,47 @@ graph ] edge [ - source 0 + source 6 target 4 graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics [ fill "#000000" width 3 @@ -593,8 +710,8 @@ graph id 3 graphics [ - w 107.80000000000001 - h 40 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -602,7 +719,7 @@ graph ] LabelGraphics [ - text "null" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -614,7 +731,6 @@ graph LabelGraphics [ text " - Region class " fontSize 14 fontName "Consolas" @@ -629,8 +745,8 @@ graph id 4 graphics [ - w 292.6 - h 96 + w 85.80000000000001 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -638,7 +754,7 @@ graph ] LabelGraphics [ - text "null" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -650,11 +766,6 @@ graph LabelGraphics [ text " - Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -669,8 +780,8 @@ graph id 5 graphics [ - w 146.3 - h 68 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -678,7 +789,7 @@ graph ] LabelGraphics [ - text "null" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -690,9 +801,6 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Entry class " fontSize 14 fontName "Consolas" @@ -707,8 +815,8 @@ graph id 6 graphics [ - w 138.60000000000002 - h 40 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -716,7 +824,7 @@ graph ] LabelGraphics [ - text "null" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -728,7 +836,6 @@ graph LabelGraphics [ text " - Transition class " fontSize 14 fontName "Consolas" @@ -737,14 +844,16 @@ graph borderDistance 6 ] ] - +] +graph +[ node [ - id 7 + id 0 graphics [ - w 112.2 - h 26 + w 277.20000000000005 + h 82 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -752,7 +861,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "o 1" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -764,6 +873,10 @@ graph LabelGraphics [ text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class " fontSize 14 fontName "Consolas" @@ -775,10 +888,10 @@ graph node [ - id 8 + id 1 graphics [ - w 85.80000000000001 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -787,7 +900,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -810,10 +923,10 @@ graph node [ - id 9 + id 2 graphics [ - w 103.4 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -822,7 +935,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -845,11 +958,11 @@ graph node [ - id 10 + id 3 graphics [ - w 103.4 - h 26 + w 107.80000000000001 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -857,7 +970,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -869,6 +982,7 @@ graph LabelGraphics [ text " + Region class " fontSize 14 fontName "Consolas" @@ -877,153 +991,52 @@ graph borderDistance 6 ] ] - edge - [ - source 4 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 6 - graphics + + node [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 4 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - ] -] -graph -[ + node [ - id 0 + id 5 graphics [ - w 277.20000000000005 - h 82 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1031,7 +1044,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1043,10 +1056,9 @@ graph LabelGraphics [ text " - Statechart class DefinedPart - CompositeElement class DefinedPart - Statechart class - CompositeElement class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -1058,11 +1070,11 @@ graph node [ - id 1 + id 6 graphics [ - w 41.800000000000004 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1070,7 +1082,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1082,6 +1094,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -1093,11 +1108,11 @@ graph node [ - id 2 + id 7 graphics [ - w 50.6 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1105,7 +1120,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1117,6 +1132,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Entry class " fontSize 14 fontName "Consolas" @@ -1128,10 +1146,10 @@ graph node [ - id 3 + id 8 graphics [ - w 107.80000000000001 + w 138.60000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -1152,7 +1170,7 @@ graph LabelGraphics [ text " - Region class + Transition class " fontSize 14 fontName "Consolas" @@ -1164,11 +1182,11 @@ graph node [ - id 4 + id 9 graphics [ - w 146.3 - h 68 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1188,9 +1206,11 @@ graph LabelGraphics [ text " - Pseudostate class Vertex class - Entry class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1202,7 +1222,7 @@ graph node [ - id 5 + id 10 graphics [ w 138.60000000000002 @@ -1238,7 +1258,7 @@ graph node [ - id 6 + id 11 graphics [ w 292.6 @@ -1278,7 +1298,7 @@ graph node [ - id 7 + id 12 graphics [ w 138.60000000000002 @@ -1314,11 +1334,11 @@ graph node [ - id 8 + id 13 graphics [ - w 112.2 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1326,7 +1346,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1338,6 +1358,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1349,11 +1374,11 @@ graph node [ - id 9 + id 14 graphics [ - w 85.80000000000001 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1361,7 +1386,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1373,6 +1398,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1384,11 +1414,11 @@ graph node [ - id 10 + id 15 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1396,7 +1426,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1408,6 +1438,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1419,11 +1450,11 @@ graph node [ - id 11 + id 16 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1431,7 +1462,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1443,6 +1474,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1451,230 +1483,14 @@ graph borderDistance 6 ] ] - edge - [ - source 6 - target 7 - graphics + + node [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 4 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 6 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 4 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 + id 17 graphics [ - w 277.20000000000005 - h 82 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1682,7 +1498,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1694,10 +1510,11 @@ graph LabelGraphics [ text " - Statechart class DefinedPart - CompositeElement class DefinedPart - Statechart class + Vertex class + State class + RegularState class CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1709,11 +1526,11 @@ graph node [ - id 1 + id 18 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1721,7 +1538,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1733,6 +1550,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1744,11 +1562,11 @@ graph node [ - id 2 + id 19 graphics [ - w 50.6 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1756,7 +1574,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1768,6 +1586,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1779,11 +1598,11 @@ graph node [ - id 3 + id 20 graphics [ - w 107.80000000000001 - h 40 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1803,7 +1622,11 @@ graph LabelGraphics [ text " - Region class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1815,11 +1638,11 @@ graph node [ - id 4 + id 21 graphics [ - w 154.0 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1839,9 +1662,7 @@ graph LabelGraphics [ text " - Vertex class - RegularState class - FinalState class + Transition class " fontSize 14 fontName "Consolas" @@ -1853,7 +1674,7 @@ graph node [ - id 5 + id 22 graphics [ w 146.3 @@ -1879,7 +1700,7 @@ graph text " Pseudostate class Vertex class - Entry class + Exit class " fontSize 14 fontName "Consolas" @@ -1891,11 +1712,11 @@ graph node [ - id 6 + id 23 graphics [ - w 292.6 - h 96 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1915,11 +1736,7 @@ graph LabelGraphics [ text " - Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart + Transition class " fontSize 14 fontName "Consolas" @@ -1931,11 +1748,11 @@ graph node [ - id 7 + id 24 graphics [ - w 138.60000000000002 - h 40 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1955,7 +1772,9 @@ graph LabelGraphics [ text " - Transition class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -1967,11 +1786,11 @@ graph node [ - id 8 + id 25 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1979,7 +1798,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1991,6 +1810,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2002,11 +1822,11 @@ graph node [ - id 9 + id 26 graphics [ - w 85.80000000000001 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2014,7 +1834,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2026,6 +1846,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2037,11 +1862,11 @@ graph node [ - id 10 + id 27 graphics [ - w 103.4 - h 26 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2049,7 +1874,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2061,6 +1886,9 @@ graph LabelGraphics [ text " + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -2072,11 +1900,11 @@ graph node [ - id 11 + id 28 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2084,7 +1912,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2096,6 +1924,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2104,173 +1933,14 @@ graph borderDistance 6 ] ] - edge - [ - source 6 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 29 graphics [ - w 277.20000000000005 - h 82 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2278,7 +1948,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2290,10 +1960,7 @@ graph LabelGraphics [ text " - Statechart class DefinedPart - CompositeElement class DefinedPart - Statechart class - CompositeElement class + Transition class " fontSize 14 fontName "Consolas" @@ -2305,11 +1972,11 @@ graph node [ - id 1 + id 30 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2317,7 +1984,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2329,6 +1996,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2340,11 +2008,11 @@ graph node [ - id 2 + id 31 graphics [ - w 50.6 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2352,7 +2020,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2364,6 +2032,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2375,10 +2044,10 @@ graph node [ - id 3 + id 32 graphics [ - w 107.80000000000001 + w 138.60000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -2399,7 +2068,7 @@ graph LabelGraphics [ text " - Region class + Transition class " fontSize 14 fontName "Consolas" @@ -2411,11 +2080,11 @@ graph node [ - id 4 + id 33 graphics [ - w 146.3 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2435,9 +2104,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Exit class + Transition class " fontSize 14 fontName "Consolas" @@ -2449,11 +2116,11 @@ graph node [ - id 5 + id 34 graphics [ - w 146.3 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2473,9 +2140,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Entry class + Transition class " fontSize 14 fontName "Consolas" @@ -2487,11 +2152,11 @@ graph node [ - id 6 + id 35 graphics [ - w 292.6 - h 96 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2511,11 +2176,7 @@ graph LabelGraphics [ text " - Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart + Transition class " fontSize 14 fontName "Consolas" @@ -2527,11 +2188,11 @@ graph node [ - id 7 + id 36 graphics [ - w 138.60000000000002 - h 40 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2551,7 +2212,9 @@ graph LabelGraphics [ text " - Transition class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -2563,11 +2226,11 @@ graph node [ - id 8 + id 37 graphics [ - w 112.2 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2575,7 +2238,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2587,6 +2250,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -2598,11 +2264,11 @@ graph node [ - id 9 + id 38 graphics [ - w 85.80000000000001 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2610,7 +2276,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2622,6 +2288,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2633,11 +2300,11 @@ graph node [ - id 10 + id 39 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2645,7 +2312,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2657,6 +2324,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2668,11 +2336,11 @@ graph node [ - id 11 + id 40 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2680,7 +2348,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2692,6 +2360,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2700,173 +2369,14 @@ graph borderDistance 6 ] ] - edge - [ - source 6 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 6 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 41 graphics [ - w 192.50000000000003 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2874,7 +2384,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2886,8 +2396,7 @@ graph LabelGraphics [ text " - Model class DefinedPart - Model class + Transition class " fontSize 14 fontName "Consolas" @@ -2899,11 +2408,11 @@ graph node [ - id 1 + id 42 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2911,7 +2420,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2923,6 +2432,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2934,11 +2444,11 @@ graph node [ - id 2 + id 43 graphics [ - w 50.6 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2946,7 +2456,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2958,6 +2468,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2969,11 +2480,11 @@ graph node [ - id 3 + id 44 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2993,8 +2504,7 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Transition class " fontSize 14 fontName "Consolas" @@ -3006,11 +2516,11 @@ graph node [ - id 4 + id 45 graphics [ - w 123.20000000000002 - h 54 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3030,8 +2540,9 @@ graph LabelGraphics [ text " - FSObject class - File class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -3043,7 +2554,7 @@ graph node [ - id 5 + id 46 graphics [ w 138.60000000000002 @@ -3067,7 +2578,7 @@ graph LabelGraphics [ text " - FileSystem class + Transition class " fontSize 14 fontName "Consolas" @@ -3079,11 +2590,11 @@ graph node [ - id 6 + id 47 graphics [ - w 123.20000000000002 - h 54 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3103,8 +2614,11 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -3116,11 +2630,11 @@ graph node [ - id 7 + id 48 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3128,7 +2642,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3140,6 +2654,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -3151,11 +2666,11 @@ graph node [ - id 8 + id 49 graphics [ - w 85.80000000000001 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3163,7 +2678,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3175,6 +2690,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -3186,11 +2702,11 @@ graph node [ - id 9 + id 50 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3198,7 +2714,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3210,6 +2726,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -3221,11 +2738,11 @@ graph node [ - id 10 + id 51 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3233,7 +2750,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3245,6 +2762,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -3253,96 +2771,14 @@ graph borderDistance 6 ] ] - edge - [ - source 5 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "root reference FileSystem" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "filesystems reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 52 graphics [ - w 192.50000000000003 - h 54 + w 112.2 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3350,7 +2786,7 @@ graph ] LabelGraphics [ - text "o 1" + text "New Integers" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3362,8 +2798,6 @@ graph LabelGraphics [ text " - Model class DefinedPart - Model class " fontSize 14 fontName "Consolas" @@ -3375,10 +2809,10 @@ graph node [ - id 1 + id 53 graphics [ - w 41.800000000000004 + w 85.80000000000001 h 26 type "rectangle" fill "#FFFFFF" @@ -3387,7 +2821,7 @@ graph ] LabelGraphics [ - text "true" + text "New Reals" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3410,10 +2844,10 @@ graph node [ - id 2 + id 54 graphics [ - w 50.6 + w 103.4 h 26 type "rectangle" fill "#FFFFFF" @@ -3422,7 +2856,7 @@ graph ] LabelGraphics [ - text "false" + text "New Strings" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3445,11 +2879,11 @@ graph node [ - id 3 + id 55 graphics [ - w 123.20000000000002 - h 54 + w 103.4 + h 26 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3457,7 +2891,7 @@ graph ] LabelGraphics [ - text "null" + text "New Objects" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3469,8 +2903,6 @@ graph LabelGraphics [ text " - FSObject class - File class " fontSize 14 fontName "Consolas" @@ -3479,108 +2911,8333 @@ graph borderDistance 6 ] ] - - node + edge + [ + source 5 + target 8 + graphics [ - id 4 - graphics - [ - w 138.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FileSystem class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 5 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FSObject class - Dir class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 4 + target 10 + graphics [ - id 6 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 12 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 15 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 16 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 19 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 21 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 28 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 29 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 30 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 31 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 32 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 24 + target 33 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 38 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 40 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 39 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 41 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 42 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 43 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 24 + target 44 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 46 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 48 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 49 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 50 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 51 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 16 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 18 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 19 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 21 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 23 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 25 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 28 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 29 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 30 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 31 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 32 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 33 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 34 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 35 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 38 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 39 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 40 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 41 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 42 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 43 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 44 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 46 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 48 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 49 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 50 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 51 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 17 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 20 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 22 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 24 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 26 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 27 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 36 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 37 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 45 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 47 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 16 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 30 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 24 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 24 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 45 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 16 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 30 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 47 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 47 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 20 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 21 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 22 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 23 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 24 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 25 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 26 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 27 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 28 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 29 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 30 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 31 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 32 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 33 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 34 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 35 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 36 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 37 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 38 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 39 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 40 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 41 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 42 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 43 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 44 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 45 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 46 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 47 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 48 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 49 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 50 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 51 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 52 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 53 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 54 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 55 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 21 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 28 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 29 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 31 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 36 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 37 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 38 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 40 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 39 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 42 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 43 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 44 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 45 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 46 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 47 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 48 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 49 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 50 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 51 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 21 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 22 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 26 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 28 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 29 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 31 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 36 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 37 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 38 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 39 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 40 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 42 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 43 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 44 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 45 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 46 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 47 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 48 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 49 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 50 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 51 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 16 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 17 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 18 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 19 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 20 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 23 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 24 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 25 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 27 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 30 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 32 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 33 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 34 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 35 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 41 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 36 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 37 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 33 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 32 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 19 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 36 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 37 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 41 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] LabelGraphics [ text " - FSObject class - Dir class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -3592,7 +11249,119 @@ graph node [ - id 7 + id 9 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 graphics [ w 112.2 @@ -3627,7 +11396,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -3662,7 +11431,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -3697,7 +11466,7 @@ graph node [ - id 10 + id 15 graphics [ w 103.4 @@ -3731,8 +11500,165 @@ graph ] edge [ - source 4 - target 6 + source 5 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 graphics [ fill "#000000" @@ -3741,7 +11667,7 @@ graph ] LabelGraphics [ - text "root reference FileSystem" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3751,8 +11677,8 @@ graph ] edge [ - source 0 - target 4 + source 3 + target 9 graphics [ fill "#000000" @@ -3761,7 +11687,7 @@ graph ] LabelGraphics [ - text "filesystems reference Model" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3771,8 +11697,8 @@ graph ] edge [ - source 0 - target 3 + source 3 + target 10 graphics [ fill "#000000" @@ -3781,7 +11707,7 @@ graph ] LabelGraphics [ - text "otherFSObjects reference Model" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3791,17 +11717,16 @@ graph ] edge [ - source 0 + source 7 target 5 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "otherFSObjects reference Model" + text "target reference Transition" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3809,233 +11734,131 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 11 + target 8 + graphics [ - id 0 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - Model class DefinedPart - Model class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 6 + target 9 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FSObject class - File class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 6 + target 5 + graphics [ - id 4 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FSObject class - File class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 11 + target 10 + graphics [ - id 5 - graphics - [ - w 138.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FileSystem class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 6 + id 0 graphics [ - w 123.20000000000002 - h 54 + w 277.20000000000005 + h 82 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4043,7 +11866,7 @@ graph ] LabelGraphics [ - text "null" + text "o 1" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4055,8 +11878,10 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class " fontSize 14 fontName "Consolas" @@ -4068,10 +11893,10 @@ graph node [ - id 7 + id 1 graphics [ - w 112.2 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -4080,7 +11905,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4103,10 +11928,10 @@ graph node [ - id 8 + id 2 graphics [ - w 85.80000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -4115,7 +11940,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4138,11 +11963,11 @@ graph node [ - id 9 + id 3 graphics [ - w 103.4 - h 26 + w 107.80000000000001 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4150,7 +11975,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4162,6 +11987,7 @@ graph LabelGraphics [ text " + Region class " fontSize 14 fontName "Consolas" @@ -4173,11 +11999,11 @@ graph node [ - id 10 + id 4 graphics [ - w 103.4 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4185,7 +12011,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4197,6 +12023,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Entry class " fontSize 14 fontName "Consolas" @@ -4205,96 +12034,14 @@ graph borderDistance 6 ] ] - edge - [ - source 5 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "root reference FileSystem" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "filesystems reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 5 graphics [ - w 192.50000000000003 - h 54 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4302,7 +12049,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4314,8 +12061,9 @@ graph LabelGraphics [ text " - Model class DefinedPart - Model class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -4327,11 +12075,11 @@ graph node [ - id 1 + id 6 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4339,7 +12087,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4351,6 +12099,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -4362,11 +12111,11 @@ graph node [ - id 2 + id 7 graphics [ - w 50.6 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4374,7 +12123,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -4386,6 +12135,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -4397,11 +12149,11 @@ graph node [ - id 3 + id 8 graphics [ - w 138.60000000000002 - h 40 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4421,7 +12173,11 @@ graph LabelGraphics [ text " - FileSystem class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4433,11 +12189,11 @@ graph node [ - id 4 + id 9 graphics [ - w 123.20000000000002 - h 54 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4457,8 +12213,11 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -4470,11 +12229,11 @@ graph node [ - id 5 + id 10 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4494,8 +12253,7 @@ graph LabelGraphics [ text " - FSObject class - File class + Transition class " fontSize 14 fontName "Consolas" @@ -4507,11 +12265,11 @@ graph node [ - id 6 + id 11 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -4531,8 +12289,7 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Transition class " fontSize 14 fontName "Consolas" @@ -4544,7 +12301,7 @@ graph node [ - id 7 + id 12 graphics [ w 112.2 @@ -4579,7 +12336,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -4614,7 +12371,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -4649,7 +12406,7 @@ graph node [ - id 10 + id 15 graphics [ w 103.4 @@ -4682,6 +12439,123 @@ graph ] ] edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge [ source 3 target 4 @@ -4693,7 +12567,7 @@ graph ] LabelGraphics [ - text "root reference FileSystem" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4703,16 +12577,17 @@ graph ] edge [ - source 6 - target 4 + source 3 + target 5 graphics [ fill "#000000" + width 3 targetArrow "standard" ] LabelGraphics [ - text "parent reference FSObject" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4722,8 +12597,8 @@ graph ] edge [ - source 4 - target 6 + source 3 + target 7 graphics [ fill "#000000" @@ -4732,7 +12607,7 @@ graph ] LabelGraphics [ - text "contents reference Dir" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4742,8 +12617,28 @@ graph ] edge [ - source 0 - target 3 + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 graphics [ fill "#000000" @@ -4752,7 +12647,7 @@ graph ] LabelGraphics [ - text "filesystems reference Model" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4762,9 +12657,123 @@ graph ] edge [ - source 0 + source 6 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 target 5 graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics [ fill "#000000" width 3 @@ -4772,7 +12781,7 @@ graph ] LabelGraphics [ - text "otherFSObjects reference Model" + text "regions reference CompositeElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png index 605b244d..0b9199f4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi index ffc48f68..8136fd72 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi @@ -1,9 +1,15 @@ - - - - - - - - + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml index 57d704cf..77878c2e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml @@ -150,8 +150,8 @@ graph id 4 graphics [ - w 107.80000000000001 - h 40 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -171,7 +171,9 @@ graph LabelGraphics [ text " - Region class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -186,7 +188,7 @@ graph id 5 graphics [ - w 154.0 + w 146.3 h 68 type "rectangle" fill "#FFFFFF" @@ -207,9 +209,9 @@ graph LabelGraphics [ text " + Pseudostate class Vertex class - RegularState class - FinalState class + Entry class " fontSize 14 fontName "Consolas" @@ -224,8 +226,8 @@ graph id 6 graphics [ - w 177.10000000000002 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -245,9 +247,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Synchronization class + Transition class " fontSize 14 fontName "Consolas" @@ -261,6 +261,46 @@ graph [ id 7 graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics [ w 112.2 h 26 @@ -294,7 +334,7 @@ graph node [ - id 8 + id 9 graphics [ w 85.80000000000001 @@ -329,7 +369,7 @@ graph node [ - id 9 + id 10 graphics [ w 103.4 @@ -364,7 +404,7 @@ graph node [ - id 10 + id 11 graphics [ w 103.4 @@ -398,8 +438,47 @@ graph ] edge [ - source 4 - target 5 + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 graphics [ fill "#000000" @@ -419,7 +498,7 @@ graph edge [ source 3 - target 6 + target 5 graphics [ fill "#000000" @@ -438,8 +517,8 @@ graph ] edge [ - source 0 - target 3 + source 3 + target 7 graphics [ fill "#000000" @@ -448,7 +527,45 @@ graph ] LabelGraphics [ - text "regions reference CompositeElement" + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -459,7 +576,7 @@ graph edge [ source 0 - target 4 + target 3 graphics [ fill "#000000" @@ -652,7 +769,7 @@ graph text " Pseudostate class Vertex class - Entry class + Exit class " fontSize 14 fontName "Consolas" @@ -667,8 +784,8 @@ graph id 5 graphics [ - w 138.60000000000002 - h 40 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -688,7 +805,9 @@ graph LabelGraphics [ text " - Transition class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -703,8 +822,8 @@ graph id 6 graphics [ - w 292.6 - h 96 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -724,11 +843,9 @@ graph LabelGraphics [ text " + Pseudostate class Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart + Exit class " fontSize 14 fontName "Consolas" @@ -766,7 +883,7 @@ graph text " Pseudostate class Vertex class - Exit class + Entry class " fontSize 14 fontName "Consolas" @@ -781,8 +898,8 @@ graph id 8 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -790,7 +907,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -802,6 +919,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -816,8 +934,8 @@ graph id 9 graphics [ - w 85.80000000000001 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -825,7 +943,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -837,6 +955,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -851,8 +974,8 @@ graph id 10 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -860,7 +983,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -872,6 +995,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -886,8 +1010,8 @@ graph id 11 graphics [ - w 103.4 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -895,7 +1019,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -907,6 +1031,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -915,173 +1044,50 @@ graph borderDistance 6 ] ] - edge - [ - source 7 - target 5 - graphics + + node [ - fill "#000000" - targetArrow "standard" + id 12 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] - LabelGraphics + + node [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 4 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 4 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 + id 13 graphics [ - w 277.20000000000005 - h 82 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1089,7 +1095,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1101,10 +1107,11 @@ graph LabelGraphics [ text " - Statechart class DefinedPart - CompositeElement class DefinedPart - Statechart class + Vertex class + State class + RegularState class CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1116,11 +1123,11 @@ graph node [ - id 1 + id 14 graphics [ - w 41.800000000000004 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1128,7 +1135,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1140,6 +1147,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1151,11 +1163,11 @@ graph node [ - id 2 + id 15 graphics [ - w 50.6 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1163,7 +1175,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1175,6 +1187,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1186,10 +1199,10 @@ graph node [ - id 3 + id 16 graphics [ - w 107.80000000000001 + w 138.60000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -1210,7 +1223,7 @@ graph LabelGraphics [ text " - Region class + Transition class " fontSize 14 fontName "Consolas" @@ -1222,11 +1235,11 @@ graph node [ - id 4 + id 17 graphics [ - w 154.0 - h 68 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1247,8 +1260,10 @@ graph [ text " Vertex class + State class RegularState class - FinalState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1260,11 +1275,11 @@ graph node [ - id 5 + id 18 graphics [ - w 146.3 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1284,9 +1299,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Entry class + Transition class " fontSize 14 fontName "Consolas" @@ -1298,11 +1311,11 @@ graph node [ - id 6 + id 19 graphics [ - w 292.6 - h 96 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1322,11 +1335,7 @@ graph LabelGraphics [ text " - Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart + Transition class " fontSize 14 fontName "Consolas" @@ -1338,11 +1347,11 @@ graph node [ - id 7 + id 20 graphics [ - w 138.60000000000002 - h 40 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1362,7 +1371,11 @@ graph LabelGraphics [ text " - Transition class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1374,11 +1387,11 @@ graph node [ - id 8 + id 21 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1386,7 +1399,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1398,6 +1411,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1409,11 +1423,11 @@ graph node [ - id 9 + id 22 graphics [ - w 85.80000000000001 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1421,7 +1435,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1433,6 +1447,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -1444,11 +1461,11 @@ graph node [ - id 10 + id 23 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1456,7 +1473,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1468,6 +1485,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -1479,11 +1497,11 @@ graph node [ - id 11 + id 24 graphics [ - w 103.4 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1491,7 +1509,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1503,6 +1521,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -1511,173 +1532,14 @@ graph borderDistance 6 ] ] - edge - [ - source 4 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 4 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 25 graphics [ - w 277.20000000000005 - h 82 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1685,7 +1547,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1697,10 +1559,7 @@ graph LabelGraphics [ text " - Statechart class DefinedPart - CompositeElement class DefinedPart - Statechart class - CompositeElement class + Transition class " fontSize 14 fontName "Consolas" @@ -1712,11 +1571,11 @@ graph node [ - id 1 + id 26 graphics [ - w 41.800000000000004 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1724,7 +1583,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1736,6 +1595,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -1747,11 +1611,11 @@ graph node [ - id 2 + id 27 graphics [ - w 50.6 - h 26 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1759,7 +1623,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1771,6 +1635,9 @@ graph LabelGraphics [ text " + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -1782,10 +1649,10 @@ graph node [ - id 3 + id 28 graphics [ - w 107.80000000000001 + w 138.60000000000002 h 40 type "rectangle" fill "#FFFFFF" @@ -1806,7 +1673,7 @@ graph LabelGraphics [ text " - Region class + Transition class " fontSize 14 fontName "Consolas" @@ -1818,11 +1685,11 @@ graph node [ - id 4 + id 29 graphics [ - w 146.3 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1842,9 +1709,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Exit class + Transition class " fontSize 14 fontName "Consolas" @@ -1856,11 +1721,11 @@ graph node [ - id 5 + id 30 graphics [ - w 146.3 - h 68 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1880,9 +1745,7 @@ graph LabelGraphics [ text " - Pseudostate class - Vertex class - Entry class + Transition class " fontSize 14 fontName "Consolas" @@ -1894,11 +1757,11 @@ graph node [ - id 6 + id 31 graphics [ - w 292.6 - h 96 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1918,11 +1781,7 @@ graph LabelGraphics [ text " - Vertex class - State class - RegularState class - CompositeElement class - CompositeElement class UndefinedPart + Transition class " fontSize 14 fontName "Consolas" @@ -1934,7 +1793,7 @@ graph node [ - id 7 + id 32 graphics [ w 138.60000000000002 @@ -1970,11 +1829,11 @@ graph node [ - id 8 + id 33 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -1982,7 +1841,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -1994,6 +1853,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2005,11 +1865,11 @@ graph node [ - id 9 + id 34 graphics [ - w 85.80000000000001 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2017,7 +1877,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2029,6 +1889,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2040,11 +1901,11 @@ graph node [ - id 10 + id 35 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2052,7 +1913,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2064,6 +1925,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2075,11 +1937,11 @@ graph node [ - id 11 + id 36 graphics [ - w 103.4 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2087,7 +1949,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2099,6 +1961,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -2107,173 +1972,14 @@ graph borderDistance 6 ] ] - edge - [ - source 4 - target 7 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "incomingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 5 - target 7 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "outgoingTransitions reference Vertex" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 3 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "vertices reference Region" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 4 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "target reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 7 - target 5 - graphics - [ - fill "#000000" - targetArrow "standard" - ] - LabelGraphics - [ - text "source reference Transition" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "regions reference CompositeElement" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 37 graphics [ - w 192.50000000000003 - h 54 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2281,7 +1987,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2293,8 +1999,9 @@ graph LabelGraphics [ text " - Model class DefinedPart - Model class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -2306,11 +2013,11 @@ graph node [ - id 1 + id 38 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2318,7 +2025,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2330,6 +2037,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2341,11 +2049,11 @@ graph node [ - id 2 + id 39 graphics [ - w 50.6 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2353,7 +2061,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2365,6 +2073,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2376,11 +2085,11 @@ graph node [ - id 3 + id 40 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2400,8 +2109,7 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Transition class " fontSize 14 fontName "Consolas" @@ -2413,7 +2121,7 @@ graph node [ - id 4 + id 41 graphics [ w 138.60000000000002 @@ -2437,7 +2145,7 @@ graph LabelGraphics [ text " - FileSystem class + Transition class " fontSize 14 fontName "Consolas" @@ -2449,11 +2157,11 @@ graph node [ - id 5 + id 42 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2473,8 +2181,7 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Transition class " fontSize 14 fontName "Consolas" @@ -2486,11 +2193,11 @@ graph node [ - id 6 + id 43 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2510,8 +2217,7 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Transition class " fontSize 14 fontName "Consolas" @@ -2523,11 +2229,11 @@ graph node [ - id 7 + id 44 graphics [ - w 112.2 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2535,7 +2241,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2547,6 +2253,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2558,11 +2265,11 @@ graph node [ - id 8 + id 45 graphics [ - w 85.80000000000001 - h 26 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2570,7 +2277,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2582,6 +2289,9 @@ graph LabelGraphics [ text " + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -2593,11 +2303,11 @@ graph node [ - id 9 + id 46 graphics [ - w 103.4 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2605,7 +2315,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2617,6 +2327,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -2628,11 +2339,11 @@ graph node [ - id 10 + id 47 graphics [ - w 103.4 - h 26 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2640,196 +2351,7 @@ graph ] LabelGraphics [ - text "New Objects" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - edge - [ - source 4 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "root reference FileSystem" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "filesystems reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ - node - [ - id 0 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - Model class DefinedPart - Model class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] - ] - - node - [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -2841,6 +2363,11 @@ graph LabelGraphics [ text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -2852,11 +2379,11 @@ graph node [ - id 3 + id 48 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2876,8 +2403,7 @@ graph LabelGraphics [ text " - FSObject class - File class + Transition class " fontSize 14 fontName "Consolas" @@ -2889,7 +2415,7 @@ graph node [ - id 4 + id 49 graphics [ w 138.60000000000002 @@ -2913,7 +2439,7 @@ graph LabelGraphics [ text " - FileSystem class + Transition class " fontSize 14 fontName "Consolas" @@ -2925,11 +2451,11 @@ graph node [ - id 5 + id 50 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2949,8 +2475,7 @@ graph LabelGraphics [ text " - FSObject class - File class + Transition class " fontSize 14 fontName "Consolas" @@ -2962,11 +2487,11 @@ graph node [ - id 6 + id 51 graphics [ - w 123.20000000000002 - h 54 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -2986,8 +2511,9 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -2999,7 +2525,7 @@ graph node [ - id 7 + id 52 graphics [ w 112.2 @@ -3034,7 +2560,7 @@ graph node [ - id 8 + id 53 graphics [ w 85.80000000000001 @@ -3069,7 +2595,7 @@ graph node [ - id 9 + id 54 graphics [ w 103.4 @@ -3104,7 +2630,7 @@ graph node [ - id 10 + id 55 graphics [ w 103.4 @@ -3138,17 +2664,16 @@ graph ] edge [ - source 4 - target 6 + source 5 + target 8 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "root reference FileSystem" + text "incomingTransitions reference Vertex" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3158,17 +2683,16 @@ graph ] edge [ - source 0 - target 4 + source 4 + target 10 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "filesystems reference Model" + text "incomingTransitions reference Vertex" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3178,17 +2702,16 @@ graph ] edge [ - source 0 - target 3 + source 11 + target 12 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "otherFSObjects reference Model" + text "incomingTransitions reference Vertex" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3198,17 +2721,16 @@ graph ] edge [ - source 0 - target 5 + source 11 + target 15 graphics [ fill "#000000" - width 3 targetArrow "standard" ] LabelGraphics [ - text "otherFSObjects reference Model" + text "incomingTransitions reference Vertex" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -3216,233 +2738,8768 @@ graph position "thead" ] ] -] -graph -[ - node + edge + [ + source 11 + target 18 + graphics [ - id 0 - graphics - [ - w 192.50000000000003 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "o 1" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - Model class DefinedPart - Model class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 16 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 19 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 21 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 28 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 29 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 30 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 31 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 32 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 24 + target 33 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 38 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 40 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 39 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 41 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 42 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 27 + target 43 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 24 + target 44 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 46 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 48 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 49 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 50 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 16 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 18 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 19 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 21 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 23 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 25 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 28 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 29 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 30 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 31 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 32 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 33 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 34 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 35 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 38 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 39 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 40 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 41 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 42 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 43 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 44 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 46 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 48 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 14 + target 49 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 50 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 17 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 20 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 22 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 24 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 26 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 27 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 36 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 37 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 45 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 47 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 51 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 16 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 30 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 24 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 27 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 24 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 45 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 12 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 15 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 16 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 30 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 14 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 47 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 16 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 17 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 18 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 19 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 20 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 21 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 22 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 23 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 24 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 25 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 26 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 27 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 28 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 29 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 30 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 31 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 32 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 33 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 34 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 35 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 36 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 37 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 38 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 39 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 40 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 41 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 42 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 43 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 44 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 45 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 46 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 47 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 48 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 49 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 50 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 51 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 52 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 53 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 54 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 55 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 13 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 21 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 22 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 26 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 17 + target 28 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 29 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 18 + target 31 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 36 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 34 + target 37 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 38 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 40 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 39 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 42 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 32 + target 43 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 44 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 19 + target 45 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 46 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 47 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 48 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 49 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 50 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 33 + target 51 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 13 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 21 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 22 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 26 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 28 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 29 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 31 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 36 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 37 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 38 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 39 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 23 + target 40 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 42 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 43 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 25 + target 44 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 45 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 46 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 47 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 20 + target 48 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 49 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 35 + target 50 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 41 + target 51 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 12 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 14 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 15 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 16 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 17 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 18 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 19 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 20 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 23 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 24 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 25 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 27 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 30 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 32 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 33 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 34 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 35 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 41 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 17 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 18 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 36 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 37 + target 34 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 33 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 32 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 19 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 33 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 13 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 21 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 22 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 26 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 28 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 29 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 31 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 36 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 37 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 38 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 39 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 40 + target 23 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 42 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 43 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 44 + target 25 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 45 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 46 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 47 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 48 + target 20 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 49 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 50 + target 35 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 51 + target 41 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] ] node [ - id 1 - graphics - [ - w 41.800000000000004 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "true" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 3 + target 5 + graphics [ - id 2 - graphics - [ - w 50.6 - h 26 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "false" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + width 3 + targetArrow "standard" ] - - node + LabelGraphics [ - id 3 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FSObject class - File class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" ] - - node + LabelGraphics [ - id 4 - graphics - [ - w 138.60000000000002 - h 40 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FileSystem class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" ] - - node + ] + edge + [ + source 11 + target 10 + graphics [ - id 5 - graphics - [ - w 123.20000000000002 - h 54 - type "rectangle" - fill "#FFFFFF" - fill2 "#FFFFFF" - outline "#000000" - ] - LabelGraphics - [ - text "null" - outline "#000000" - fill "#FFFFFF" - fontSize 16 - fontName "Monospace" - autoSizePolicy "node_width" - anchor "t" - borderDistance 0.0 - ] - LabelGraphics - [ - text " - FSObject class - Dir class - " - fontSize 14 - fontName "Consolas" - alignment "left" - anchor "tl" - borderDistance 6 - ] + fill "#000000" + targetArrow "standard" ] - + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ node [ - id 6 + id 0 graphics [ - w 123.20000000000002 - h 54 + w 277.20000000000005 + h 82 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3450,7 +11507,7 @@ graph ] LabelGraphics [ - text "null" + text "o 1" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3462,8 +11519,10 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class " fontSize 14 fontName "Consolas" @@ -3475,10 +11534,10 @@ graph node [ - id 7 + id 1 graphics [ - w 112.2 + w 41.800000000000004 h 26 type "rectangle" fill "#FFFFFF" @@ -3487,7 +11546,7 @@ graph ] LabelGraphics [ - text "New Integers" + text "true" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3510,10 +11569,10 @@ graph node [ - id 8 + id 2 graphics [ - w 85.80000000000001 + w 50.6 h 26 type "rectangle" fill "#FFFFFF" @@ -3522,7 +11581,7 @@ graph ] LabelGraphics [ - text "New Reals" + text "false" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3545,11 +11604,11 @@ graph node [ - id 9 + id 3 graphics [ - w 103.4 - h 26 + w 107.80000000000001 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3557,7 +11616,7 @@ graph ] LabelGraphics [ - text "New Strings" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3569,6 +11628,7 @@ graph LabelGraphics [ text " + Region class " fontSize 14 fontName "Consolas" @@ -3580,11 +11640,11 @@ graph node [ - id 10 + id 4 graphics [ - w 103.4 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3592,7 +11652,7 @@ graph ] LabelGraphics [ - text "New Objects" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3604,6 +11664,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Entry class " fontSize 14 fontName "Consolas" @@ -3612,96 +11675,14 @@ graph borderDistance 6 ] ] - edge - [ - source 4 - target 6 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "root reference FileSystem" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 4 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "filesystems reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 3 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] - edge - [ - source 0 - target 5 - graphics - [ - fill "#000000" - width 3 - targetArrow "standard" - ] - LabelGraphics - [ - text "otherFSObjects reference Model" - fontSize 14 - fontName "Consolas" - configuration "AutoFlippingLabel" - model "six_pos" - position "thead" - ] - ] -] -graph -[ + node [ - id 0 + id 5 graphics [ - w 192.50000000000003 - h 54 + w 154.0 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3709,7 +11690,7 @@ graph ] LabelGraphics [ - text "o 1" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3721,8 +11702,9 @@ graph LabelGraphics [ text " - Model class DefinedPart - Model class + Vertex class + RegularState class + FinalState class " fontSize 14 fontName "Consolas" @@ -3734,11 +11716,11 @@ graph node [ - id 1 + id 6 graphics [ - w 41.800000000000004 - h 26 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3746,7 +11728,7 @@ graph ] LabelGraphics [ - text "true" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3758,6 +11740,7 @@ graph LabelGraphics [ text " + Transition class " fontSize 14 fontName "Consolas" @@ -3769,11 +11752,11 @@ graph node [ - id 2 + id 7 graphics [ - w 50.6 - h 26 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3781,7 +11764,7 @@ graph ] LabelGraphics [ - text "false" + text "null" outline "#000000" fill "#FFFFFF" fontSize 16 @@ -3793,6 +11776,9 @@ graph LabelGraphics [ text " + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -3804,11 +11790,11 @@ graph node [ - id 3 + id 8 graphics [ - w 138.60000000000002 - h 40 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3828,7 +11814,11 @@ graph LabelGraphics [ text " - FileSystem class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -3840,11 +11830,11 @@ graph node [ - id 4 + id 9 graphics [ - w 123.20000000000002 - h 54 + w 292.6 + h 96 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3864,8 +11854,11 @@ graph LabelGraphics [ text " - FSObject class - Dir class + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart " fontSize 14 fontName "Consolas" @@ -3877,11 +11870,11 @@ graph node [ - id 5 + id 10 graphics [ - w 123.20000000000002 - h 54 + w 138.60000000000002 + h 40 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3901,8 +11894,7 @@ graph LabelGraphics [ text " - FSObject class - File class + Transition class " fontSize 14 fontName "Consolas" @@ -3914,11 +11906,11 @@ graph node [ - id 6 + id 11 graphics [ - w 123.20000000000002 - h 54 + w 146.3 + h 68 type "rectangle" fill "#FFFFFF" fill2 "#FFFFFF" @@ -3938,8 +11930,9 @@ graph LabelGraphics [ text " - FSObject class - File class + Pseudostate class + Vertex class + Exit class " fontSize 14 fontName "Consolas" @@ -3951,7 +11944,7 @@ graph node [ - id 7 + id 12 graphics [ w 112.2 @@ -3986,7 +11979,7 @@ graph node [ - id 8 + id 13 graphics [ w 85.80000000000001 @@ -4021,7 +12014,7 @@ graph node [ - id 9 + id 14 graphics [ w 103.4 @@ -4056,7 +12049,7 @@ graph node [ - id 10 + id 15 graphics [ w 103.4 @@ -4089,6 +12082,84 @@ graph ] ] edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 4 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge [ source 3 target 4 @@ -4100,7 +12171,7 @@ graph ] LabelGraphics [ - text "root reference FileSystem" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4110,8 +12181,8 @@ graph ] edge [ - source 0 - target 3 + source 3 + target 5 graphics [ fill "#000000" @@ -4120,7 +12191,7 @@ graph ] LabelGraphics [ - text "filesystems reference Model" + text "vertices reference Region" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4130,8 +12201,68 @@ graph ] edge [ - source 0 - target 5 + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 graphics [ fill "#000000" @@ -4140,7 +12271,83 @@ graph ] LabelGraphics [ - text "otherFSObjects reference Model" + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 4 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" @@ -4151,7 +12358,7 @@ graph edge [ source 0 - target 6 + target 3 graphics [ fill "#000000" @@ -4160,7 +12367,7 @@ graph ] LabelGraphics [ - text "otherFSObjects reference Model" + text "regions reference CompositeElement" fontSize 14 fontName "Consolas" configuration "AutoFlippingLabel" diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png index 1fddfd99..08502c12 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi index 6b9900e2..f61f6ffb 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi @@ -1,8 +1,15 @@ - - - - - - - + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv index d1c8d98d..9e25c13a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv @@ -1,22 +1,18 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;335;2777;2544;7194393100;105;140;61;186;9;0;3 +1;1;ModelResultImpl;58;4042;5037;7589962200;537;880;485;48;20;0;6 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;120;2483;7934;1838851300;477;3162;36;100;0;2 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;InconsistencyResultImpl;20;2258;2771;12900;42;12;1;0;0 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;InconsistencyResultImpl;14;2066;3146;29000;439;14;13;0;0 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;15;1857;2520;3998461000;169;207;102;9;4;0;3 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;70;2695;2815;3409332300;111;133;61;18;3;0;5 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;16;2246;2987;3347793300;168;362;201;7;6;0;3 +1;1;ModelResultImpl;35;3137;3383;1446909200;48;0;24;0;0;2 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;6;839;711;3017372100;45;206;107;9;7;0;1 +1;1;ModelResultImpl;24;2684;30969;24516501600;27279;28245;26662;18;324;0;4 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;5;879;674;2970538700;33;111;55;7;2;0;1 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;5;882;742;2902370500;64;203;110;9;6;0;1 -Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime -1;1;ModelResultImpl;10;1041;730;3174826600;23;31;19;12;0;0;1 +1;1;ModelResultImpl;23;2143;23882;16188039300;21183;21191;20297;20;189;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;InsuficientResourcesResultImpl;18;2211;10998;6300;7933;10;95;0;0 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;InsuficientResourcesResultImpl;15;2037;5137;6800;2250;15;169;0;0 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;104;2832;6950;15113591900;777;1074;1256;1824;2107;1521;145;44;0;16 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;42;3179;15266;13359431300;12045;12060;12077;12082;12107;9023;25;176;0;9 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;646;4720;6290;14663107900;900;1000;1126;1525;1621;1177;235;34;0;17 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index a09e1cf4..7e10c75a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -17,17 +17,12 @@ - - - + + - - - - @@ -134,12 +129,6 @@ - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql index 9af35b50..a4718150 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/ecorePatterns.vql @@ -14,13 +14,13 @@ pattern loopInInheritence(a: EClass) { pattern opposite(a:EReference, b: EReference) { EReference.eOpposite(a,b); } -@Constraint(key={a}, severity="error", message="error") -pattern oppositeDifferentClass(a:EReference) { - EReference.eOpposite(a,b); - EReference.eContainingClass(a,aContaining); - EReference.eType(b,bTarget); - aContaining != bTarget; -} +//@Constraint(key={a}, severity="error", message="error") +//pattern oppositeDifferentClass(a:EReference) { +// EReference.eOpposite(a,b); +// EReference.eContainingClass(a,aContaining); +// EReference.eType(b,bTarget); +// aContaining != bTarget; +//} @Constraint(key={a}, severity="error", message="error") pattern nonSymmetricOpposite(a:EReference, b:EReference) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql deleted file mode 100644 index 02d34dcd..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql +++ /dev/null @@ -1,103 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries - -import "FamMetamodel" - -@Constraint(message="terminatorAndInformation", severity="error", key={T}) -pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { - FunctionalOutput.outgoingLinks(Out,I); - FunctionalOutput.terminator(Out,T); -} or { - InformationLink.to(I,In); - FunctionalInput.terminator(In,T); -} - -@QueryBasedFeature -pattern type(This : Function, Target : FunctionType) = { - find rootElements(_Model, This); - Target == FunctionType::Root; -} or { - neg find parent(_Child, This); - neg find rootElements(_Model, This); - Target == FunctionType::Leaf; -} or { - find parent(This, _Par); - find parent(_Child, This); - Target == FunctionType::Intermediate; -} - -pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { - FunctionalArchitectureModel.rootElements(Model, Root); -} - -pattern parent(Func : Function, Par : Function) = { - Function.parent(Func, Par); -} - -@QueryBasedFeature -pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { - FunctionalElement(This); - FunctionalArchitectureModel(Target); -} - -/* -@Constraint(message="noRoot", severity="error", key={fam}) -pattern noRoot(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasRoot(_); -} -@Constraint(message="noIntermediate", severity="error", key={fam}) -pattern noInt(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasInt(_); -} -@Constraint(message="noLeaf", severity="error", key={fam}) -pattern noLeaf(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasLeaf(_); -} -*/ - -/* -@QueryBasedFeature -pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { - find parent+(This, Parent); - find rootElements(Target, Parent); -} or { - find rootElements(Target, This); -} - -pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { - FunctionalInterface.data(FI, FD); -} - -@QueryBasedFeature -pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.outputs(This, Output); - InformationLink.from(Target, Output); -} - -@QueryBasedFeature -pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.inputs(This, Input); - InformationLink.to(Target, Input); -} - -@QueryBasedFeature -pattern connects(This : FunctionalElement, Target : FunctionalElement) = { - FunctionalElement.outgoingLinks(This,Link); - FunctionalElement.incomingLinks(Target,Link); -}*/ - -/*pattern frequency(a: Function, b : EInt) { - Function.minimumFrequency(a,b); -}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql new file mode 100644 index 00000000..307b0f9c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql @@ -0,0 +1,13 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries + +//import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" +import epackage "FamMetamodel" + +@Constraint(message="terminatorAndInformation", severity="error", key={T}) +pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { + FunctionalOutput.outgoingLinks(Out,I); + FunctionalOutput.terminator(Out,T); +} or { + InformationLink.to(I,In); + FunctionalInput.terminator(In,T); +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql new file mode 100644 index 00000000..153fec91 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql @@ -0,0 +1,103 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries + +import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" + +@Constraint(message="terminatorAndInformation", severity="error", key={T}) +pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { + FunctionalOutput.outgoingLinks(Out,I); + FunctionalOutput.terminator(Out,T); +} or { + InformationLink.to(I,In); + FunctionalInput.terminator(In,T); +} + +@QueryBasedFeature +pattern type(This : Function, Target : FunctionType) = { + find rootElements(_Model, This); + Target == FunctionType::Root; +} or { + neg find parent(_Child, This); + neg find rootElements(_Model, This); + Target == FunctionType::Leaf; +} or { + find parent(This, _Par); + find parent(_Child, This); + Target == FunctionType::Intermediate; +} + +pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { + FunctionalArchitectureModel.rootElements(Model, Root); +} + +pattern parent(Func : Function, Par : Function) = { + Function.parent(Func, Par); +} + +@QueryBasedFeature +pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { + FunctionalElement(This); + FunctionalArchitectureModel(Target); +} + +/* +@Constraint(message="noRoot", severity="error", key={fam}) +pattern noRoot(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasRoot(_); +} +@Constraint(message="noIntermediate", severity="error", key={fam}) +pattern noInt(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasInt(_); +} +@Constraint(message="noLeaf", severity="error", key={fam}) +pattern noLeaf(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasLeaf(_); +} +*/ + +/* +@QueryBasedFeature +pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { + find parent+(This, Parent); + find rootElements(Target, Parent); +} or { + find rootElements(Target, This); +} + +pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { + FunctionalInterface.data(FI, FD); +} + +@QueryBasedFeature +pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.outputs(This, Output); + InformationLink.from(Target, Output); +} + +@QueryBasedFeature +pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.inputs(This, Input); + InformationLink.to(Target, Input); +} + +@QueryBasedFeature +pattern connects(This : FunctionalElement, Target : FunctionalElement) = { + FunctionalElement.outgoingLinks(This,Link); + FunctionalElement.incomingLinks(Target,Link); +}*/ + +/*pattern frequency(a: Function, b : EInt) { + Function.minimumFrequency(a,b); +}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java index 69a6b9f4..1d3019e8 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java @@ -1,5 +1,5 @@ /** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql */ package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore index 96fd178f..a0ebcd7a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/.gitignore @@ -156,3 +156,27 @@ /Transition_M3.java /Transition_M4.java /YakinduMutatedPatterns.java +/Child.java +/ChoiceHasNoIncoming.java +/ChoiceHasNoOutgoing.java +/EntryInRegion.java +/HasMultipleIncomingTrainsition.java +/HasMultipleOutgoingTrainsition.java +/HasMultipleRegions.java +/IncomingToEntry.java +/MultipleTransitionFromEntry.java +/NoEntryInRegion.java +/NoOutgoingTransitionFromEntry.java +/NoStateInRegion.java +/NotSynchronizingStates.java +/OutgoingFromExit.java +/OutgoingFromFinal.java +/StateInRegion.java +/SynchHasNoIncoming.java +/SynchHasNoOutgoing.java +/SynchThree.java +/SynchronizedIncomingInSameRegion.java +/SynchronizedRegionDoesNotHaveMultipleRegions.java +/SynchronizedRegionsAreNotSiblings.java +/Transition.java +/TwoSynch.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/TestExecutionICSE.xtend b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/TestExecutionICSE.xtend new file mode 100644 index 00000000..41bb763d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/TestExecutionICSE.xtend @@ -0,0 +1,22 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test + +import hu.bme.mit.inf.dslreasoner.application.execution.StandaloneScriptExecutor + +class TestExecutionICSE { + def static void main(String[] args) { + val fileSystemPath = "configs/fileSystem.vsconfig"; + val ecorePath = "configs/ecore.vsconfig"; + val yakinduPath = "configs/yakindu.vsconfig"; + val famPath = "configs/fam.vsconfig"; +// val yakinduWithWFPath = "configs/yakinduWF.vsconfig"; +// val famWithWFPath = "configs/famWF.vsconfig"; + val exp1 = StandaloneScriptExecutor.executeScript(fileSystemPath); + println(exp1) +// val exp2 = StandaloneScriptExecutor.executeScript(ecorePath); +// println(exp2) + val exp3 = StandaloneScriptExecutor.executeScript(yakinduPath); + println(exp3) + val exp4 = StandaloneScriptExecutor.executeScript(famPath); + println(exp4) + } +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java index c1c75043..d8ca61ea 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/FileSystem.java @@ -62,7 +62,6 @@ public interface FileSystem extends EObject { * @return the value of the 'Live' reference list. * @see ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage#getFileSystem_Live() * @model transient="true" changeable="false" volatile="true" derived="true" - * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live'" * @generated */ EList getLive(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java index 8bbc6a74..b5ef2b66 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/FileSystemImpl.java @@ -13,7 +13,6 @@ import org.eclipse.emf.common.notify.NotificationChain; import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EStructuralFeature; import org.eclipse.emf.ecore.InternalEObject; import org.eclipse.emf.ecore.impl.ENotificationImpl; @@ -44,16 +43,6 @@ public class FileSystemImpl extends MinimalEObjectImpl.Container implements File */ protected Dir root; - /** - * The cached setting delegate for the '{@link #getLive() Live}' reference list. - * - * - * @see #getLive() - * @generated - * @ordered - */ - protected EStructuralFeature.Internal.SettingDelegate LIVE__ESETTING_DELEGATE = ((EStructuralFeature.Internal)filesystemPackage.Literals.FILE_SYSTEM__LIVE).getSettingDelegate(); - /** * * @@ -123,7 +112,11 @@ public class FileSystemImpl extends MinimalEObjectImpl.Container implements File */ @SuppressWarnings("unchecked") public EList getLive() { - return (EList)LIVE__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false); + // TODO: implement this method to return the 'Live' reference list + // Ensure that you remove @generated or mark it @generated NOT + // The list is expected to implement org.eclipse.emf.ecore.util.InternalEList and org.eclipse.emf.ecore.EStructuralFeature.Setting + // so it's likely that an appropriate subclass of org.eclipse.emf.ecore.util.EcoreEList should be used. + throw new UnsupportedOperationException(); } /** @@ -197,7 +190,7 @@ public class FileSystemImpl extends MinimalEObjectImpl.Container implements File case filesystemPackage.FILE_SYSTEM__ROOT: return root != null; case filesystemPackage.FILE_SYSTEM__LIVE: - return LIVE__ESETTING_DELEGATE.dynamicIsSet(this, null, 0); + return !getLive().isEmpty(); } return super.eIsSet(featureID); } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java index 5c6dd21e..5bd41020 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/filesystem/impl/filesystemPackageImpl.java @@ -317,8 +317,6 @@ public class filesystemPackageImpl extends EPackageImpl implements filesystemPac // Create annotations // http://www.eclipse.org/emf/2002/Ecore createEcoreAnnotations(); - // org.eclipse.viatra.query.querybasedfeature - createOrgAnnotations(); } /** @@ -337,20 +335,4 @@ public class filesystemPackageImpl extends EPackageImpl implements filesystemPac }); } - /** - * Initializes the annotations for org.eclipse.viatra.query.querybasedfeature. - * - * - * @generated - */ - protected void createOrgAnnotations() { - String source = "org.eclipse.viatra.query.querybasedfeature"; - addAnnotation - (getFileSystem_Live(), - source, - new String[] { - "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live" - }); - } - } //filesystemPackageImpl -- cgit v1.2.3-54-g00ecf From bcbd697001571ce50fd4f5299423b9bc9f77d366 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Sun, 17 Feb 2019 20:15:58 -0500 Subject: complete vsconfig files #19 --- .../configs/fam.vsconfig | 4 +- .../functionalPlugin.txt | 145 - .../metamodels/fam.ecore | 12 +- .../outputs/fam/debug/errors.txt | 15 + .../fam/debug/generated3valued.vql_deactivated | 7983 ++++++++++++++++++++ .../outputs/fam/debug/generation.logicproblem | 69 +- .../outputs/fam/debug/init.partialmodel | 7 +- .../outputs/fam/log.txt | 2 +- .../outputs/fam/models/1.gml | 3354 ++++++++ .../outputs/fam/models/1.png | Bin 68150 -> 73113 bytes .../outputs/fam/models/1.xmi | 22 +- .../outputs/fam/models/2.gml | 3356 ++++++++ .../outputs/fam/models/2.png | Bin 64057 -> 75459 bytes .../outputs/fam/models/2.xmi | 21 +- .../outputs/fam/models/3.gml | 3317 ++++++++ .../outputs/fam/models/3.png | Bin 64831 -> 75681 bytes .../outputs/fam/models/3.xmi | 22 +- .../outputs/fam/models/4.gml | 3338 ++++++++ .../outputs/fam/models/4.png | Bin 80996 -> 88715 bytes .../outputs/fam/models/4.xmi | 21 +- .../outputs/fam/models/5.gml | 3338 ++++++++ .../outputs/fam/models/5.png | Bin 66383 -> 88028 bytes .../outputs/fam/models/5.xmi | 20 +- .../outputs/fam/statistics.csv | 8 + .../yakindu/debug/generated3valued.vql_deactivated | 2925 +++++++ .../outputs/yakindu/debug/generation.logicproblem | 2 +- .../outputs/yakindu/log.txt | 2 +- .../outputs/yakindu/models/1.gml | 830 ++ .../outputs/yakindu/models/1.png | Bin 127573 -> 99990 bytes .../outputs/yakindu/models/1.xmi | 15 +- .../outputs/yakindu/models/2.gml | 832 ++ .../outputs/yakindu/models/2.png | Bin 116286 -> 98486 bytes .../outputs/yakindu/models/2.xmi | 15 +- .../outputs/yakindu/statistics.csv | 2 + .../plugin.xml | 10 +- .../pluginWorking.txt | 145 + .../pluginWorking2.txt | 141 + .../standalone/test/fam/queries/famPatterns.vql | 104 + .../standalone/test/fam/queries/famXPatterns.vql | 103 - .../test/fam/queries/TerminatorAndInformation.java | 2 +- 40 files changed, 29854 insertions(+), 328 deletions(-) delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking2.txt create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig index 8137ddf7..e56cf30c 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig @@ -3,8 +3,8 @@ import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPattern generate { metamodel = { package fam } -// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} -// partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} + constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} + partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} solver = ViatraSolver scope = { #node = 10 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt deleted file mode 100644 index ca86fe6b..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/functionalPlugin.txt +++ /dev/null @@ -1,145 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore index 05023c15..d9c8bfef 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.ecore @@ -8,7 +8,11 @@ + volatile="true" transient="true" derived="true"> + +
+ + @@ -20,7 +24,11 @@ + changeable="false" volatile="true" transient="true" derived="true"> + +
+ + (FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:130) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated index 7899a25f..b3223685 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated @@ -47045,3 +47045,7986 @@ pattern refineRelation_type_attribute_Function( find mayInRelationtype_attribute_Function(problem,interpretation,from,to); neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem index f221cce7..061a233a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem @@ -1,7 +1,7 @@ - + - + @@ -10,6 +10,8 @@ + + @@ -494,6 +496,22 @@ + + + + + + + + + + + + + + + + @@ -554,10 +572,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + @@ -577,4 +638,6 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel index 55020b90..3f2640d6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel @@ -1,5 +1,5 @@ - + @@ -86,6 +86,7 @@ + @@ -109,6 +110,9 @@ + + + @@ -122,4 +126,5 @@ + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt index 7029fce0..6386e508 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt @@ -1 +1 @@ -Model generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated! \ No newline at end of file +Model generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml index 3e4dddc2..b0a86a61 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml @@ -8342,3 +8342,3357 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png index e33711c3..158ebb0f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi index fa323f3d..3dcec4a4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi @@ -1,11 +1,13 @@ - - - - - - - - - - + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml index 383a7f99..62441d63 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml @@ -8343,3 +8343,3359 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png index 05355ee6..0222b4b1 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi index 956b6f1b..144e4fc5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi @@ -1,11 +1,12 @@ - - - - - - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml index ed77ebc2..e046559b 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml @@ -8343,3 +8343,3320 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png index 5df81bb3..a551c9fc 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi index b4259573..9e8efc63 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi @@ -1,12 +1,12 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml index 2dd09497..f41692fc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml @@ -8423,3 +8423,3341 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png index 5a2af8ba..c58be27f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi index 4ca54850..c5049270 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi @@ -1,11 +1,12 @@ - - - - - - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml index 3a9035a7..9bbf93f7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml @@ -8535,3 +8535,3341 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 361.90000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalArchitectureModel class DefinedPart + FunctionalArchitectureModel class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 192.50000000000003 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalElement class + Function class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 3 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "model reference FunctionalElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "rootElements reference FunctionalArchitectureModel" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "element reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 0 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 2 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "type attribute Function" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png index 3c09036a..a141edb0 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi index 21ac69a6..c5049270 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi @@ -1,10 +1,12 @@ - - - - - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv index f0a5df58..9f61f0e9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv @@ -18,3 +18,11 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformati 1;1;ModelResultImpl;1;928;1173;8877697600;49;109;128;149;167;83;5;2;0;3 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime 1;1;ModelResultImpl;2;1070;1291;9164916500;97;114;167;249;276;120;8;3;0;3 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;2;1595;1756;13001782700;63;89;115;147;177;94;13;3;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;189;2560;2666;10577938300;240;291;346;491;534;277;137;14;0;10 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;16;1673;1881;10488189500;142;240;275;311;375;191;21;7;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;47;1835;2309;9517642900;281;405;544;574;580;325;17;13;0;6 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated index 5ac9e1dc..f2e524ab 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generated3valued.vql_deactivated @@ -26323,3 +26323,2928 @@ pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "Pseudostate class". + */ +private pattern mustInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Pseudostate class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Pseudostate class"); +} + +/** + * An element may be an instance of type "Pseudostate class". + */ +private pattern mayInstanceOfPseudostate_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewPseudostate_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfPseudostate_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Vertex class". + */ +private pattern mustInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Vertex class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewVertex_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Vertex class"); +} + +/** + * An element may be an instance of type "Vertex class". + */ +private pattern mayInstanceOfVertex_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find scopeDisallowsNewVertex_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfVertex_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Region class". + */ +private pattern mustInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Region class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegion_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Region class"); +} + +/** + * An element may be an instance of type "Region class". + */ +private pattern mayInstanceOfRegion_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewRegion_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegion_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Transition class". + */ +private pattern mustInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Transition class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewTransition_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Transition class"); +} + +/** + * An element may be an instance of type "Transition class". + */ +private pattern mayInstanceOfTransition_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewTransition_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfTransition_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class". + */ +private pattern mustInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class"); +} + +/** + * An element may be an instance of type "Statechart class". + */ +private pattern mayInstanceOfStatechart_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Entry class". + */ +private pattern mustInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Entry class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewEntry_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Entry class"); +} + +/** + * An element may be an instance of type "Entry class". + */ +private pattern mayInstanceOfEntry_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewEntry_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfEntry_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Synchronization class". + */ +private pattern mustInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Synchronization class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Synchronization class"); +} + +/** + * An element may be an instance of type "Synchronization class". + */ +private pattern mayInstanceOfSynchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewSynchronization_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfSynchronization_class(problem,interpretation,element); } +/** + * An element must be an instance of type "State class". + */ +private pattern mustInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"State class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"State class"); +} + +/** + * An element may be an instance of type "State class". + */ +private pattern mayInstanceOfState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "RegularState class". + */ +private pattern mustInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"RegularState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"RegularState class"); +} + +/** + * An element may be an instance of type "RegularState class". + */ +private pattern mayInstanceOfRegularState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); + neg find scopeDisallowsNewRegularState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfRegularState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class". + */ +private pattern mustInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class"); +} + +/** + * An element may be an instance of type "CompositeElement class". + */ +private pattern mayInstanceOfCompositeElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Choice class". + */ +private pattern mustInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Choice class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewChoice_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Choice class"); +} + +/** + * An element may be an instance of type "Choice class". + */ +private pattern mayInstanceOfChoice_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); + neg find scopeDisallowsNewChoice_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfChoice_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Exit class". + */ +private pattern mustInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Exit class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewExit_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Exit class"); +} + +/** + * An element may be an instance of type "Exit class". + */ +private pattern mayInstanceOfExit_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find scopeDisallowsNewExit_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfExit_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FinalState class". + */ +private pattern mustInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FinalState class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FinalState class"); +} + +/** + * An element may be an instance of type "FinalState class". + */ +private pattern mayInstanceOfFinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find scopeDisallowsNewFinalState_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFinalState_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class DefinedPart". + */ +private pattern mustInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class DefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class DefinedPart". + */ +private pattern mayInstanceOfStatechart_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "Statechart class UndefinedPart". + */ +private pattern mustInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Statechart class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Statechart class UndefinedPart"); +} + +/** + * An element may be an instance of type "Statechart class UndefinedPart". + */ +private pattern mayInstanceOfStatechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewStatechart_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class DefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class DefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mustInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"CompositeElement class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"CompositeElement class UndefinedPart"); +} + +/** + * An element may be an instance of type "CompositeElement class UndefinedPart". + */ +private pattern mayInstanceOfCompositeElement_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find scopeDisallowsNewCompositeElement_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []incomingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>incomingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationincomingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingTransitions reference Vertex(source,target) + */ +private pattern mustInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingTransitions reference Vertex"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingTransitions reference Vertex(source,target) + */ +private pattern mayInRelationoutgoingTransitions_reference_Vertex( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfVertex_class(problem,interpretation,source); + find mayInstanceOfTransition_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []vertices reference Region(source,target) + */ +private pattern mustInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"vertices reference Region"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>vertices reference Region(source,target) + */ +private pattern mayInRelationvertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfRegion_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationvertices_reference_Region(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []target reference Transition(source,target) + */ +private pattern mustInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>target reference Transition(source,target) + */ +private pattern mayInRelationtarget_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtarget_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []source reference Transition(source,target) + */ +private pattern mustInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"source reference Transition"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>source reference Transition(source,target) + */ +private pattern mayInRelationsource_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfTransition_class(problem,interpretation,source); + find mayInstanceOfVertex_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationsource_reference_Transition(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsource_reference_Transition(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []regions reference CompositeElement(source,target) + */ +private pattern mustInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"regions reference CompositeElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>regions reference CompositeElement(source,target) + */ +private pattern mayInRelationregions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfCompositeElement_class(problem,interpretation,source); + find mayInstanceOfRegion_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries entryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_e1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1, var_e1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInstanceOfEntry_class(problem,interpretation,var_e1); + // r1 is exported + // e1 is exported + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_e1; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r1); + // r1 is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r1,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleEntryInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + neg find mayEquivalent(problem, interpretation, var_e1, var_e2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + // r is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_entryInRegion(problem,interpretation,var_r,var_e2); + var_e1 != var_e2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries transition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfVertex_class(problem,interpretation,var_src); + find mayInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_src); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_trg); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_src, var_trg) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfVertex_class(problem,interpretation,var_src); + find mustInstanceOfVertex_class(problem,interpretation,var_trg); + // t is exported + // src is exported + // trg is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_src; + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_trg; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries incomingToEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // t is exported + // e is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t,_var__0,var_e); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noOutgoingTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + // e is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_e,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries multipleTransitionFromEntry +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t1); + find mayInstanceOfEntry_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_t2); + var_t1 != var_t2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry( + problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + // e is exported + // t1 is exported + // t2 is exported + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t1; + find mustInstanceOfEntry_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual1); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual1); + var_virtual1 == var_t2; + var_t1 != var_t2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromExit +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mayInstanceOfExit_class(problem,interpretation,var_e); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfExit_class(problem,interpretation,var_e); + // t is exported + // e is exported + find mustInstanceOfExit_class(problem,interpretation,var_e); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_e,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries outgoingFromFinal +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mayInstanceOfTransition_class(problem,interpretation,var_t); + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mayInstanceOfFinalState_class(problem,interpretation,var_f); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mayInstanceOfTransition_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_t); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal( + problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,var_t); + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + // t is exported + // f is exported + find mustInstanceOfFinalState_class(problem,interpretation,var_f); + find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,var_f,var_virtual0); + find mustInstanceOfTransition_class(problem,interpretation,var_virtual0); + var_virtual0 == var_t; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries noStateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + // region is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion(problem,interpretation,var_region,_var__0); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries StateInRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mayInstanceOfRegion_class(problem,interpretation,var_region); + find mayInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_state); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_StateInRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_region, var_state) +{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInstanceOfState_class(problem,interpretation,var_state); + // region is exported + // state is exported + find mustInstanceOfRegion_class(problem,interpretation,var_region); + find mustInRelationvertices_reference_Region(problem,interpretation,var_region,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_state; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_c,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries choiceHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mayInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,var_c); + // c is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoOutgoing +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,_var__1); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchHasNoIncoming +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,_var__1,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedIncomingInSameRegion +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_v1); + find mayInstanceOfRegion_class(problem,interpretation,var_r); + find mayInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v2); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_v2,var_s); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t1,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,var_t2,var_s,var_v2); + var_t1 != var_t2; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_v1; + find mustInstanceOfRegion_class(problem,interpretation,var_r); + find mustInRelationvertices_reference_Region(problem,interpretation,var_r,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries notSynchronizingStates +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition(problem,interpretation,var_s); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition(problem,interpretation,var_s); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleOutgoingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + neg find mayEquivalent(problem, interpretation, var_trg1, var_trg2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleOutgoingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_trg1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v,var_trg2); + var_trg1 != var_trg2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleIncomingTrainsition +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + neg find mayEquivalent(problem, interpretation, var_src1, var_src2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleIncomingTrainsition( + problem:LogicProblem, interpretation:PartialInterpretation, + var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_v); + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_src1,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_src2,var_v); + var_src1 != var_src2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionsAreNotSiblings +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + neg find mayEquivalent(problem, interpretation, var_r1, var_r2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v1); + find mayInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_v1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual3); + find mayEquivalent(problem, interpretation, var_virtual3, var_v2); + var_r1 != var_r2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v1,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_v2,var_s); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v1); + find mustInstanceOfVertex_class(problem,interpretation,var_v2); + // s is exported + // v1 is exported + // v2 is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v1); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__1,var_s,var_v2); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r1); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r1,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_v1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_r2); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_r2,var_virtual2); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual2); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual2,var_virtual3); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual3); + var_virtual3 == var_v2; + var_r1 != var_r2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries child +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_child); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child( + problem:LogicProblem, interpretation:PartialInterpretation, + var_parent, var_child) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInstanceOfVertex_class(problem,interpretation,var_child); + // parent is exported + // child is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_parent); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_parent,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mustInRelationvertices_reference_Region(problem,interpretation,var_virtual0,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_child; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries SynchronizedRegionDoesNotHaveMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + find mayInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_v,var_s); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + find mustInstanceOfVertex_class(problem,interpretation,var_v); + // s is exported + // v is exported + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_transition(problem,interpretation,_var__0,var_s,var_v); + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_child(problem,interpretation,var_c,var_v); + neg find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions(problem,interpretation,var_c); +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries hasMultipleRegions +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + neg find mayEquivalent(problem, interpretation, var_region1, var_region2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_region1); + find mayInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mayInstanceOfRegion_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_region2); + var_region1 != var_region2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_hasMultipleRegions( + problem:LogicProblem, interpretation:PartialInterpretation, + var_composite) +{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + // composite is exported + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual0); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual0); + var_virtual0 == var_region1; + find mustInstanceOfCompositeElement_class(problem,interpretation,var_composite); + find mustInRelationregions_reference_CompositeElement(problem,interpretation,var_composite,var_virtual1); + find mustInstanceOfRegion_class(problem,interpretation,var_virtual1); + var_virtual1 == var_region2; + var_region1 != var_region2; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries synchThree +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + neg find mayEquivalent(problem, interpretation, var_t1, var_t2); + neg find mayEquivalent(problem, interpretation, var_t2, var_t3); + neg find mayEquivalent(problem, interpretation, var_t1, var_t3); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mayInstanceOfTransition_class(problem,interpretation,var_t1); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t2); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_s); + find mayInstanceOfTransition_class(problem,interpretation,var_t3); + find mayInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mayInstanceOfVertex_class(problem,interpretation,var_virtual2); + find mayEquivalent(problem, interpretation, var_virtual2, var_s); + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationtarget_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s); + // s is exported + find mustInstanceOfTransition_class(problem,interpretation,var_t1); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t1,var_virtual0); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual0); + var_virtual0 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t2); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t2,var_virtual1); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual1); + var_virtual1 == var_s; + find mustInstanceOfTransition_class(problem,interpretation,var_t3); + find mustInRelationsource_reference_Transition(problem,interpretation,var_t3,var_virtual2); + find mustInstanceOfVertex_class(problem,interpretation,var_virtual2); + var_virtual2 == var_s; + var_t1 != var_t2; + var_t2 != var_t3; + var_t1 != var_t3; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test yakindu queries twoSynch +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + neg find mayEquivalent(problem, interpretation, var_s1, var_s2); +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mayInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mayInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch( + problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + // s1 is exported + // s2 is exported + find mustInstanceOfSynchronization_class(problem,interpretation,var_s1); + find mustInstanceOfSynchronization_class(problem,interpretation,var_s2); + var_s1 != var_s2; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,source,target); }or + + { find mustInRelationvertices_reference_Region(problem,interpretation,source,target); }or + + { find mustInRelationregions_reference_CompositeElement(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_target_reference_Transition(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"target reference Transition"); + find mustInstanceOfTransition_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtarget_reference_Transition(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r1) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noEntryInRegion(problem,interpretation,var_r1); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_r) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleEntryInRegion(problem,interpretation,var_r); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_incomingToEntry(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noOutgoingTransitionFromEntry(problem,interpretation,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem:LogicProblem, interpretation:PartialInterpretation, + var_e, var_t1, var_t2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_multipleTransitionFromEntry(problem,interpretation,var_e,var_t1,var_t2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_e) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromExit(problem,interpretation,var_t,var_e); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem:LogicProblem, interpretation:PartialInterpretation, + var_t, var_f) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_outgoingFromFinal(problem,interpretation,var_t,var_f); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_region) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_noStateInRegion(problem,interpretation,var_region); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoOutgoing(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_c) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_choiceHasNoIncoming(problem,interpretation,var_c); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoOutgoing(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchHasNoIncoming(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedIncomingInSameRegion(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_notSynchronizingStates(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v1, var_v2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionsAreNotSiblings(problem,interpretation,var_s,var_v1,var_v2); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem:LogicProblem, interpretation:PartialInterpretation, + var_s, var_v) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_SynchronizedRegionDoesNotHaveMultipleRegions(problem,interpretation,var_s,var_v); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem:LogicProblem, interpretation:PartialInterpretation, + var_s) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_synchThree(problem,interpretation,var_s); +} +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem:LogicProblem, interpretation:PartialInterpretation, + var_s1, var_s2) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_yakindu_queries_twoSynch(problem,interpretation,var_s1,var_s2); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegion_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfSynchronization_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfChoice_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfVertex_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfRegularState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfEntry_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfPseudostate_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFinalState_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfExit_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfTransition_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfCompositeElement_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Transition_class_by_outgoingTransitions_reference_Vertex_with_source_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"source reference Transition"); + find mustInstanceOfVertex_class(problem,interpretation,container); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayInRelationoutgoingTransitions_reference_Vertex(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Transition_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Transition class"); + find mayInstanceOfTransition_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Entry_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Entry class"); + find mayInstanceOfEntry_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class_by_regions_reference_CompositeElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"regions reference CompositeElement"); + find mustInstanceOfCompositeElement_class(problem,interpretation,container); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayInRelationregions_reference_CompositeElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Region_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Region class"); + find mayInstanceOfRegion_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Choice_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Choice class"); + find mayInstanceOfChoice_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Synchronization_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Synchronization class"); + find mayInstanceOfSynchronization_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Statechart_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Statechart class UndefinedPart"); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_State_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"State class"); + find mayInstanceOfState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Exit_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Exit class"); + find mayInstanceOfExit_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class_by_vertices_reference_Region( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"vertices reference Region"); + find mustInstanceOfRegion_class(problem,interpretation,container); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayInRelationvertices_reference_Region(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FinalState_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FinalState class"); + find mayInstanceOfFinalState_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Transition_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Entry_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Region_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); +} +pattern refineTypeTo_Choice_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Synchronization_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_Statechart_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfVertex_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class_UndefinedPart(problem,interpretation,element); +} +pattern refineTypeTo_State_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfStatechart_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfState_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); +} +pattern refineTypeTo_Exit_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfExit_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfEntry_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfChoice_class(problem,interpretation,element); + neg find mustInstanceOfRegularState_class(problem,interpretation,element); + neg find mustInstanceOfSynchronization_class(problem,interpretation,element); + neg find mustInstanceOfExit_class(problem,interpretation,element); +} +pattern refineTypeTo_FinalState_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFinalState_class(problem,interpretation,element); + neg find mustInstanceOfPseudostate_class(problem,interpretation,element); + neg find mustInstanceOfTransition_class(problem,interpretation,element); + neg find mustInstanceOfCompositeElement_class(problem,interpretation,element); + neg find mustInstanceOfRegion_class(problem,interpretation,element); + neg find mustInstanceOfFinalState_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_incomingTransitions_reference_Vertex_and_target_reference_Transition( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"incomingTransitions reference Vertex"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"target reference Transition"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfVertex_class(problem,interpretation,from); + find mustInstanceOfTransition_class(problem,interpretation,to); + find mayInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); + neg find mustInRelationincomingTransitions_reference_Vertex(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem index 2079fe25..3696f838 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/debug/generation.logicproblem @@ -1402,7 +1402,7 @@ - + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt index 977a3efc..8d1daafe 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/log.txt @@ -1 +1 @@ -Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file +Model generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, a model is generatedModels: [1.xmi]Visualisations: [1.gml]Visualisations: [1.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedProblem is consistent, 2 models are generated!Models: [1.xmi][2.xmi]Visualisations: [1.gml][2.gml]Visualisations: [1.png][2.png]Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedUnable to solve problem, but 0 model generated!Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml index 897aa2d4..2b44b530 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.gml @@ -12790,3 +12790,833 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Exit class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png index 0b9199f4..6c9b4ffb 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi index 8136fd72..137f0943 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/1.xmi @@ -1,15 +1,14 @@ - - - - + + - - - + + + + - + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml index 77878c2e..f0112af7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.gml @@ -12376,3 +12376,835 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 277.20000000000005 + h 82 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "o 1" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Statechart class DefinedPart + CompositeElement class DefinedPart + Statechart class + CompositeElement class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 107.80000000000001 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Region class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 146.3 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Pseudostate class + Vertex class + Entry class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 154.0 + h 68 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + RegularState class + FinalState class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 138.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Transition class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 292.6 + h 96 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + Vertex class + State class + RegularState class + CompositeElement class + CompositeElement class UndefinedPart + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "incomingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingTransitions reference Vertex" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 4 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 5 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 3 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "vertices reference Region" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "target reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "source reference Transition" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 0 + target 3 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "regions reference CompositeElement" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png index 08502c12..548f8dae 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi index f61f6ffb..0d85e1cd 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/models/2.xmi @@ -1,15 +1,14 @@ - - + + + + + - + - - - - - + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv index 9e25c13a..290c841e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/yakindu/statistics.csv @@ -16,3 +16,5 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformati 1;1;ModelResultImpl;42;3179;15266;13359431300;12045;12060;12077;12082;12107;9023;25;176;0;9 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime 1;1;ModelResultImpl;646;4720;6290;14663107900;900;1000;1126;1525;1621;1177;235;34;0;17 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;564;4692;4940;13642804600;616;832;966;1014;1191;829;198;27;0;17 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index 7e10c75a..28ea4798 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -20,8 +20,8 @@ - - + + @@ -129,6 +129,12 @@ + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking.txt new file mode 100644 index 00000000..ca86fe6b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking.txt @@ -0,0 +1,145 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking2.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking2.txt new file mode 100644 index 00000000..ea39dade --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/pluginWorking2.txt @@ -0,0 +1,141 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql new file mode 100644 index 00000000..1c6a545e --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql @@ -0,0 +1,104 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries + +import epackage "FamMetamodel" + +@Constraint(message="terminatorAndInformation", severity="error", key={T}) +pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { + FunctionalOutput.outgoingLinks(Out,I); + FunctionalOutput.terminator(Out,T); +} or { + InformationLink.to(I,In); + FunctionalInput.terminator(In,T); +} + +/* +@QueryBasedFeature +pattern type(This : Function, Target : FunctionType) = { + find rootElements(_Model, This); + Target == FunctionType::Root; +} or { + neg find parent(_Child, This); + neg find rootElements(_Model, This); + Target == FunctionType::Leaf; +} or { + find parent(This, _Par); + find parent(_Child, This); + Target == FunctionType::Intermediate; +} + +pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { + FunctionalArchitectureModel.rootElements(Model, Root); +} + +pattern parent(Func : Function, Par : Function) = { + Function.parent(Func, Par); +} + +@QueryBasedFeature +pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { + FunctionalElement(This); + FunctionalArchitectureModel(Target); +} + +/* +@Constraint(message="noRoot", severity="error", key={fam}) +pattern noRoot(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasRoot(_); +} +@Constraint(message="noIntermediate", severity="error", key={fam}) +pattern noInt(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasInt(_); +} +@Constraint(message="noLeaf", severity="error", key={fam}) +pattern noLeaf(fam: FunctionalArchitectureModel) { + FunctionalArchitectureModel(fam); + neg find hasLeaf(_); +} +*/ + +/* +@QueryBasedFeature +pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { + find parent+(This, Parent); + find rootElements(Target, Parent); +} or { + find rootElements(Target, This); +} + +pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { + FunctionalInterface.data(FI, FD); +} + +@QueryBasedFeature +pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { + find interfaceData(This, Target); +} + +@QueryBasedFeature +pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.outputs(This, Output); + InformationLink.from(Target, Output); +} + +@QueryBasedFeature +pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { + FunctionalElement.interface.inputs(This, Input); + InformationLink.to(Target, Input); +} + +@QueryBasedFeature +pattern connects(This : FunctionalElement, Target : FunctionalElement) = { + FunctionalElement.outgoingLinks(This,Link); + FunctionalElement.incomingLinks(Target,Link); +}*/ + +/*pattern frequency(a: Function, b : EInt) { + Function.minimumFrequency(a,b); +}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql deleted file mode 100644 index 153fec91..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famXPatterns.vql +++ /dev/null @@ -1,103 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries - -import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" - -@Constraint(message="terminatorAndInformation", severity="error", key={T}) -pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { - FunctionalOutput.outgoingLinks(Out,I); - FunctionalOutput.terminator(Out,T); -} or { - InformationLink.to(I,In); - FunctionalInput.terminator(In,T); -} - -@QueryBasedFeature -pattern type(This : Function, Target : FunctionType) = { - find rootElements(_Model, This); - Target == FunctionType::Root; -} or { - neg find parent(_Child, This); - neg find rootElements(_Model, This); - Target == FunctionType::Leaf; -} or { - find parent(This, _Par); - find parent(_Child, This); - Target == FunctionType::Intermediate; -} - -pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { - FunctionalArchitectureModel.rootElements(Model, Root); -} - -pattern parent(Func : Function, Par : Function) = { - Function.parent(Func, Par); -} - -@QueryBasedFeature -pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { - FunctionalElement(This); - FunctionalArchitectureModel(Target); -} - -/* -@Constraint(message="noRoot", severity="error", key={fam}) -pattern noRoot(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasRoot(_); -} -@Constraint(message="noIntermediate", severity="error", key={fam}) -pattern noInt(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasInt(_); -} -@Constraint(message="noLeaf", severity="error", key={fam}) -pattern noLeaf(fam: FunctionalArchitectureModel) { - FunctionalArchitectureModel(fam); - neg find hasLeaf(_); -} -*/ - -/* -@QueryBasedFeature -pattern model(This : FunctionalElement, Target : FunctionalArchitectureModel) = { - find parent+(This, Parent); - find rootElements(Target, Parent); -} or { - find rootElements(Target, This); -} - -pattern interfaceData(FI : FunctionalInterface, FD : FunctionalData) = { - FunctionalInterface.data(FI, FD); -} - -@QueryBasedFeature -pattern inputs(This : FunctionalInterface, Target : FunctionalInput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outputs(This : FunctionalInterface, Target : FunctionalOutput) = { - find interfaceData(This, Target); -} - -@QueryBasedFeature -pattern outgoingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.outputs(This, Output); - InformationLink.from(Target, Output); -} - -@QueryBasedFeature -pattern incomingLinks(This : FunctionalElement, Target : InformationLink) = { - FunctionalElement.interface.inputs(This, Input); - InformationLink.to(Target, Input); -} - -@QueryBasedFeature -pattern connects(This : FunctionalElement, Target : FunctionalElement) = { - FunctionalElement.outgoingLinks(This,Link); - FunctionalElement.incomingLinks(Target,Link); -}*/ - -/*pattern frequency(a: Function, b : EInt) { - Function.minimumFrequency(a,b); -}*/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java index 1d3019e8..69a6b9f4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java @@ -1,5 +1,5 @@ /** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql + * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql */ package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; -- cgit v1.2.3-54-g00ecf From b42fb7517302ff158a61920a63d8682c31565619 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Wed, 20 Mar 2019 20:39:28 -0400 Subject: Add gitignore, commit everything --- .../.gitignore | 2 + .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1705 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2535 -> 2526 bytes .../inputs/FamPatterns.vql | 4 +- .../META-INF/MANIFEST.MF | 28 +- .../dslreasoner/domains/alloyexamples/.gitignore | 8 + .../domains/alloyexamples/ContentInNotLive.java | 741 +++++++++++++++++++++ .../domains/alloyexamples/DirectSupertype.java | 692 +++++++++++++++++++ .../dslreasoner/domains/alloyexamples/Live.java | 730 ++++++++++++++++++++ .../domains/alloyexamples/LoopInInheritence.java | 548 +++++++++++++++ .../alloyexamples/NonSymmetricOpposite.java | 707 ++++++++++++++++++++ .../domains/alloyexamples/Opposite.java | 693 +++++++++++++++++++ .../alloyexamples/OppositeDifferentClass.java | 577 ++++++++++++++++ .../domains/alloyexamples/PatternContent.java | 693 +++++++++++++++++++ .../META-INF/MANIFEST.MF | 20 +- .../.classpath | 1 + .../META-INF/MANIFEST.MF | 5 +- .../build.properties | 3 +- .../.classpath | 1 + .../build.properties | 3 +- .../.classpath | 7 - .../.project | 29 - .../META-INF/MANIFEST.MF | 7 - .../model/logic2vampire.aird | 30 - .../model/logic2vampire.ecore | 4 - .../model/logic2vampire.genmodel | 14 - .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../vampireLanguage/VLSFiniteModel.java | 20 - .../vampireLanguage/VLSFunctionFof.java | 69 -- .../dslreasoner/vampireLanguage/VLSTrying.java | 52 -- .../vampireLanguage/impl/VLSFiniteModelImpl.java | 43 -- .../vampireLanguage/impl/VLSFunctionFofImpl.java | 240 ------- .../vampireLanguage/impl/VLSTryingImpl.java | 178 ----- .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../.gitignore | 1 + .../ecse/dslreasoner/vampire/queries/VLSAnd.java | 533 --------------- .../dslreasoner/vampire/queries/VLSAnnotation.java | 533 --------------- .../dslreasoner/vampire/queries/VLSComment.java | 533 --------------- .../dslreasoner/vampire/queries/VLSEquivalent.java | 533 --------------- .../vampire/queries/VLSExistentialQuantifier.java | 533 --------------- .../dslreasoner/vampire/queries/VLSFofFormula.java | 533 --------------- .../dslreasoner/vampire/queries/VLSFunction.java | 533 --------------- .../vampire/queries/VLSFunctionFof.java | 533 --------------- .../dslreasoner/vampire/queries/VLSInequality.java | 533 --------------- .../ecse/dslreasoner/vampire/queries/VLSOr.java | 535 --------------- .../vampire/queries/VLSUnaryNegation.java | 533 --------------- .../vampire/queries/VLSUniversalQuantifier.java | 533 --------------- .../vampire/queries/VampireQueries.java | 174 ----- .../.gitignore | 2 + ...c2VampireLanguageMapper_ContainmentMapper.xtend | 14 +- ...guageMapper_TypeMapperTrace_FilteredTypes.xtend | 18 - .../.VampireAnalyzerConfiguration.xtendbin | Bin 2399 -> 2399 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 5892 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18129 -> 18128 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4215 -> 4215 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 7649 -> 7604 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 8210 -> 8210 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 9263 -> 9263 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 12311 -> 12311 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 10377 -> 10377 bytes ...geMapper_TypeMapperTrace_FilteredTypes.xtendbin | Bin 2643 -> 0 bytes ...anguageMapper_TypeMapper_FilteredTypes.xtendbin | Bin 8564 -> 0 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 4908 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes ...ic2VampireLanguageMapper_ContainmentMapper.java | 11 +- ...nguageMapper_TypeMapperTrace_FilteredTypes.java | 20 - .../metamodels/fam.aird | 633 ++++++++++++++++++ .../plugin.xml | 2 + .../standalone/test/fam/queries/famPatterns.vql | 4 +- .../standalone/test/fam/queries/famSPatterns.vql | 13 - .../.gitignore | 3 + .../output/FAMTest/vampireProblem.tptp | 22 +- .../output/VampireTest/vampireProblem.tptp | 7 - .../dslreasoner/vampire/icse/GeneralTest.xtend | 13 +- .../dslreasoner/vampire/icseTests/FAMTest.xtend | 103 --- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 6358 -> 6358 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 4068 -> 4068 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 4115 -> 4115 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 8486 -> 8212 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 4054 -> 4054 bytes .../ecse/dslreasoner/vampire/icse/GeneralTest.java | 2 +- .../ecse/dslreasoner/vampire/icseTest/.gitignore | 1 - .../dslreasoner/vampire/test/.DslTest.xtendbin | Bin 5966 -> 0 bytes .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes .../ecse/dslreasoner/vampire/test/FAMTest.java | 111 --- .../hu/bme/mit/inf/dslreasoner/run/.gitignore | 2 - .../.classpath | 1 + .../META-INF/MANIFEST.MF | 29 +- .../build.properties | 5 +- 106 files changed, 6117 insertions(+), 7621 deletions(-) create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/ContentInNotLive.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/DirectSupertype.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Live.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/LoopInInheritence.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/NonSymmetricOpposite.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Opposite.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/OppositeDifferentClass.java create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/PatternContent.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.classpath delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.project delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/META-INF/MANIFEST.MF delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.aird delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.ecore delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.genmodel delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFiniteModel.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFunctionFof.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTrying.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFiniteModelImpl.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFunctionFofImpl.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTryingImpl.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnd.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnnotation.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSComment.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSEquivalent.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSExistentialQuantifier.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFofFormula.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunction.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunctionFof.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSInequality.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSOr.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUnaryNegation.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUniversalQuantifier.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VampireQueries.java delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtend delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtendbin delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper_FilteredTypes.xtendbin delete mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.aird delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/VampireTest/vampireProblem.tptp delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icseTests/FAMTest.xtend delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icseTest/.gitignore delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.DslTest.xtendbin delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/FAMTest.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/hu/bme/mit/inf/dslreasoner/run/.gitignore (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/.gitignore b/Application/hu.bme.mit.inf.dslreasoner.application.ide/.gitignore index ae3c1726..d95727ab 100644 --- a/Application/hu.bme.mit.inf.dslreasoner.application.ide/.gitignore +++ b/Application/hu.bme.mit.inf.dslreasoner.application.ide/.gitignore @@ -1 +1,3 @@ /bin/ +/xtend-gen/ +/src-gen/ \ No newline at end of file diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index ca156c38..eca39970 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index 51888916..6d4d9077 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Domains/Examples/ModelGenExampleFAM_standalone/inputs/FamPatterns.vql b/Domains/Examples/ModelGenExampleFAM_standalone/inputs/FamPatterns.vql index 34394ef6..3966d0af 100644 --- a/Domains/Examples/ModelGenExampleFAM_standalone/inputs/FamPatterns.vql +++ b/Domains/Examples/ModelGenExampleFAM_standalone/inputs/FamPatterns.vql @@ -1,7 +1,7 @@ package hu.bme.mit.inf.dslreasoner.domains.fam -import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" -//import epackage "platform:/resource/ModelGenExampleFAM/inputs/FamMetamodel.ecore"; +//import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" +import epackage "platform:/resource/ModelGenExampleFAM/inputs/FamMetamodel.ecore"; @Constraint(message="terminatorAndInformation", severity="error", key={T}) pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/META-INF/MANIFEST.MF b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/META-INF/MANIFEST.MF index 41726ae6..85d7e580 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/META-INF/MANIFEST.MF +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/META-INF/MANIFEST.MF @@ -6,20 +6,20 @@ Bundle-Version: 1.0.0.qualifier Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin -Export-Package: hu.bme.mit.inf.dslreasoner.domains.alloyexamples, - hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem, - hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.impl, - hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.util, - hu.bme.mit.inf.dslreasoner.domains.alloyexamples.util -Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.viatra.query.runtime, - org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - org.eclipse.emf.emfstore.common, - com.google.guava, - org.eclipse.xtext.xbase.lib, - org.eclipse.xtend.lib, - org.eclipse.xtend.lib.macro +Export-Package: hu.bme.mit.inf.dslreasoner.domains.alloyexamples, + hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem, + hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.impl, + hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.util, + hu.bme.mit.inf.dslreasoner.domains.alloyexamples.util +Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, + org.eclipse.viatra.query.runtime, + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport, + org.eclipse.emf.emfstore.common, + com.google.guava, + org.eclipse.xtext.xbase.lib, + org.eclipse.xtend.lib, + org.eclipse.xtend.lib.macro Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy Import-Package: org.apache.log4j diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/.gitignore b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/.gitignore index 9d608403..52338993 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/.gitignore +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/.gitignore @@ -34,3 +34,11 @@ /OppositeMatcher.java /PatternContentMatch.java /PatternContentMatcher.java +/.ContentInNotLive.java._trace +/.DirectSupertype.java._trace +/.Live.java._trace +/.LoopInInheritence.java._trace +/.NonSymmetricOpposite.java._trace +/.Opposite.java._trace +/.OppositeDifferentClass.java._trace +/.PatternContent.java._trace diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/ContentInNotLive.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/ContentInNotLive.java new file mode 100644 index 00000000..38d48ddb --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/ContentInNotLive.java @@ -0,0 +1,741 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/FileSystem.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.Dir; +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject; +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Live; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(key={child}, severity="error", message="error")
+ *         pattern contentInNotLive(parent : Dir, child: FSObject) {
+ *         	Dir.contents(parent,child);
+ *         	neg find live(_,parent);
+ *         } or {
+ *         	Dir.contents(parent,child);
+ *         	neg find live(_,child);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class ContentInNotLive extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.contentInNotLive pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private Dir fParent; + + private FSObject fChild; + + private static List parameterNames = makeImmutableList("parent", "child"); + + private Match(final Dir pParent, final FSObject pChild) { + this.fParent = pParent; + this.fChild = pChild; + } + + @Override + public Object get(final String parameterName) { + if ("parent".equals(parameterName)) return this.fParent; + if ("child".equals(parameterName)) return this.fChild; + return null; + } + + public Dir getParent() { + return this.fParent; + } + + public FSObject getChild() { + return this.fChild; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("parent".equals(parameterName) ) { + this.fParent = (Dir) newValue; + return true; + } + if ("child".equals(parameterName) ) { + this.fChild = (FSObject) newValue; + return true; + } + return false; + } + + public void setParent(final Dir pParent) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fParent = pParent; + } + + public void setChild(final FSObject pChild) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fChild = pChild; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.contentInNotLive"; + } + + @Override + public List parameterNames() { + return ContentInNotLive.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fParent, fChild}; + } + + @Override + public ContentInNotLive.Match toImmutable() { + return isMutable() ? newMatch(fParent, fChild) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"parent\"=" + prettyPrintValue(fParent) + ", "); + result.append("\"child\"=" + prettyPrintValue(fChild)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fParent, fChild); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof ContentInNotLive.Match)) { + ContentInNotLive.Match other = (ContentInNotLive.Match) obj; + return Objects.equals(fParent, other.fParent) && Objects.equals(fChild, other.fChild); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public ContentInNotLive specification() { + return ContentInNotLive.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static ContentInNotLive.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static ContentInNotLive.Match newMutableMatch(final Dir pParent, final FSObject pChild) { + return new Mutable(pParent, pChild); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the (partial) match object. + * + */ + public static ContentInNotLive.Match newMatch(final Dir pParent, final FSObject pChild) { + return new Immutable(pParent, pChild); + } + + private static final class Mutable extends ContentInNotLive.Match { + Mutable(final Dir pParent, final FSObject pChild) { + super(pParent, pChild); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends ContentInNotLive.Match { + Immutable(final Dir pParent, final FSObject pChild) { + super(pParent, pChild); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.contentInNotLive pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(key={child}, severity="error", message="error")
+   * pattern contentInNotLive(parent : Dir, child: FSObject) {
+   * 	Dir.contents(parent,child);
+   * 	neg find live(_,parent);
+   * } or {
+   * 	Dir.contents(parent,child);
+   * 	neg find live(_,child);
+   * }
+   * 
+ * + * @see Match + * @see ContentInNotLive + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static ContentInNotLive.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static ContentInNotLive.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_PARENT = 0; + + private final static int POSITION_CHILD = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(ContentInNotLive.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final Dir pParent, final FSObject pChild) { + return rawStreamAllMatches(new Object[]{pParent, pChild}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final Dir pParent, final FSObject pChild) { + return rawStreamAllMatches(new Object[]{pParent, pChild}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final Dir pParent, final FSObject pChild) { + return rawGetOneArbitraryMatch(new Object[]{pParent, pChild}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final Dir pParent, final FSObject pChild) { + return rawHasMatch(new Object[]{pParent, pChild}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final Dir pParent, final FSObject pChild) { + return rawCountMatches(new Object[]{pParent, pChild}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final Dir pParent, final FSObject pChild, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pParent, pChild}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pParent the fixed value of pattern parameter parent, or null if not bound. + * @param pChild the fixed value of pattern parameter child, or null if not bound. + * @return the (partial) match object. + * + */ + public ContentInNotLive.Match newMatch(final Dir pParent, final FSObject pChild) { + return ContentInNotLive.Match.newMatch(pParent, pChild); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream

rawStreamAllValuesOfparent(final Object[] parameters) { + return rawStreamAllValues(POSITION_PARENT, parameters).map(Dir.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent() { + return rawStreamAllValuesOfparent(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent() { + return rawStreamAllValuesOfparent(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent(final ContentInNotLive.Match partialMatch) { + return rawStreamAllValuesOfparent(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfparent(final FSObject pChild) { + return rawStreamAllValuesOfparent(new Object[]{null, pChild}); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent(final ContentInNotLive.Match partialMatch) { + return rawStreamAllValuesOfparent(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for parent. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfparent(final FSObject pChild) { + return rawStreamAllValuesOfparent(new Object[]{null, pChild}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfchild(final Object[] parameters) { + return rawStreamAllValues(POSITION_CHILD, parameters).map(FSObject.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild() { + return rawStreamAllValuesOfchild(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild() { + return rawStreamAllValuesOfchild(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for child. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild(final ContentInNotLive.Match partialMatch) { + return rawStreamAllValuesOfchild(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for child. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfchild(final Dir pParent) { + return rawStreamAllValuesOfchild(new Object[]{pParent, null}); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild(final ContentInNotLive.Match partialMatch) { + return rawStreamAllValuesOfchild(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for child. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfchild(final Dir pParent) { + return rawStreamAllValuesOfchild(new Object[]{pParent, null}).collect(Collectors.toSet()); + } + + @Override + protected ContentInNotLive.Match tupleToMatch(final Tuple t) { + try { + return ContentInNotLive.Match.newMatch((Dir) t.get(POSITION_PARENT), (FSObject) t.get(POSITION_CHILD)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected ContentInNotLive.Match arrayToMatch(final Object[] match) { + try { + return ContentInNotLive.Match.newMatch((Dir) match[POSITION_PARENT], (FSObject) match[POSITION_CHILD]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected ContentInNotLive.Match arrayToMatchMutable(final Object[] match) { + try { + return ContentInNotLive.Match.newMutableMatch((Dir) match[POSITION_PARENT], (FSObject) match[POSITION_CHILD]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return ContentInNotLive.instance(); + } + } + + private ContentInNotLive() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static ContentInNotLive instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected ContentInNotLive.Matcher instantiate(final ViatraQueryEngine engine) { + return ContentInNotLive.Matcher.on(engine); + } + + @Override + public ContentInNotLive.Matcher instantiate() { + return ContentInNotLive.Matcher.create(); + } + + @Override + public ContentInNotLive.Match newEmptyMatch() { + return ContentInNotLive.Match.newEmptyMatch(); + } + + @Override + public ContentInNotLive.Match newMatch(final Object... parameters) { + return ContentInNotLive.Match.newMatch((hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.Dir) parameters[0], (hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.ContentInNotLive (visibility: PUBLIC, simpleName: ContentInNotLive, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.ContentInNotLive, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.ContentInNotLive (visibility: PUBLIC, simpleName: ContentInNotLive, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.ContentInNotLive, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static ContentInNotLive INSTANCE = new ContentInNotLive(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static ContentInNotLive.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_parent = new PParameter("parent", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.Dir", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "Dir")), PParameterDirection.INOUT); + + private final PParameter parameter_child = new PParameter("child", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "FSObject")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_parent, parameter_child); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.contentInNotLive"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("parent","child"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_parent = body.getOrCreateVariableByName("parent"); + PVariable var_child = body.getOrCreateVariableByName("child"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_child), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_parent, parameter_parent), + new ExportedParameter(body, var_child, parameter_child) + )); + // Dir.contents(parent,child) + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FS", "Dir", "contents"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + new Equality(body, var__virtual_0_, var_child); + // neg find live(_,parent) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_parent), Live.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_parent = body.getOrCreateVariableByName("parent"); + PVariable var_child = body.getOrCreateVariableByName("child"); + PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_child), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_parent, parameter_parent), + new ExportedParameter(body, var_child, parameter_child) + )); + // Dir.contents(parent,child) + new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_parent, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FS", "Dir", "contents"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + new Equality(body, var__virtual_0_, var_child); + // neg find live(_,child) + new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_child), Live.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("child") + })); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/DirectSupertype.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/DirectSupertype.java new file mode 100644 index 00000000..ffa846a0 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/DirectSupertype.java @@ -0,0 +1,692 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Ecore.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern directSupertype(a: EClass, b:EClass) {
+ *         	EClass.eSuperTypes(a,b);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class DirectSupertype extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.directSupertype pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private EClass fA; + + private EClass fB; + + private static List parameterNames = makeImmutableList("a", "b"); + + private Match(final EClass pA, final EClass pB) { + this.fA = pA; + this.fB = pB; + } + + @Override + public Object get(final String parameterName) { + if ("a".equals(parameterName)) return this.fA; + if ("b".equals(parameterName)) return this.fB; + return null; + } + + public EClass getA() { + return this.fA; + } + + public EClass getB() { + return this.fB; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("a".equals(parameterName) ) { + this.fA = (EClass) newValue; + return true; + } + if ("b".equals(parameterName) ) { + this.fB = (EClass) newValue; + return true; + } + return false; + } + + public void setA(final EClass pA) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fA = pA; + } + + public void setB(final EClass pB) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fB = pB; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.directSupertype"; + } + + @Override + public List parameterNames() { + return DirectSupertype.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fA, fB}; + } + + @Override + public DirectSupertype.Match toImmutable() { + return isMutable() ? newMatch(fA, fB) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"a\"=" + prettyPrintValue(fA) + ", "); + result.append("\"b\"=" + prettyPrintValue(fB)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fA, fB); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof DirectSupertype.Match)) { + DirectSupertype.Match other = (DirectSupertype.Match) obj; + return Objects.equals(fA, other.fA) && Objects.equals(fB, other.fB); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public DirectSupertype specification() { + return DirectSupertype.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static DirectSupertype.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static DirectSupertype.Match newMutableMatch(final EClass pA, final EClass pB) { + return new Mutable(pA, pB); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public static DirectSupertype.Match newMatch(final EClass pA, final EClass pB) { + return new Immutable(pA, pB); + } + + private static final class Mutable extends DirectSupertype.Match { + Mutable(final EClass pA, final EClass pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends DirectSupertype.Match { + Immutable(final EClass pA, final EClass pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.directSupertype pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern directSupertype(a: EClass, b:EClass) {
+   * 	EClass.eSuperTypes(a,b);
+   * }
+   * 
+ * + * @see Match + * @see DirectSupertype + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static DirectSupertype.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static DirectSupertype.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_A = 0; + + private final static int POSITION_B = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(DirectSupertype.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final EClass pA, final EClass pB) { + return rawStreamAllMatches(new Object[]{pA, pB}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final EClass pA, final EClass pB) { + return rawStreamAllMatches(new Object[]{pA, pB}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final EClass pA, final EClass pB) { + return rawGetOneArbitraryMatch(new Object[]{pA, pB}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final EClass pA, final EClass pB) { + return rawHasMatch(new Object[]{pA, pB}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final EClass pA, final EClass pB) { + return rawCountMatches(new Object[]{pA, pB}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final EClass pA, final EClass pB, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pA, pB}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public DirectSupertype.Match newMatch(final EClass pA, final EClass pB) { + return DirectSupertype.Match.newMatch(pA, pB); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfa(final Object[] parameters) { + return rawStreamAllValues(POSITION_A, parameters).map(EClass.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final DirectSupertype.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final EClass pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final DirectSupertype.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final EClass pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfb(final Object[] parameters) { + return rawStreamAllValues(POSITION_B, parameters).map(EClass.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final DirectSupertype.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final EClass pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final DirectSupertype.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final EClass pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}).collect(Collectors.toSet()); + } + + @Override + protected DirectSupertype.Match tupleToMatch(final Tuple t) { + try { + return DirectSupertype.Match.newMatch((EClass) t.get(POSITION_A), (EClass) t.get(POSITION_B)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected DirectSupertype.Match arrayToMatch(final Object[] match) { + try { + return DirectSupertype.Match.newMatch((EClass) match[POSITION_A], (EClass) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected DirectSupertype.Match arrayToMatchMutable(final Object[] match) { + try { + return DirectSupertype.Match.newMutableMatch((EClass) match[POSITION_A], (EClass) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return DirectSupertype.instance(); + } + } + + private DirectSupertype() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static DirectSupertype instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected DirectSupertype.Matcher instantiate(final ViatraQueryEngine engine) { + return DirectSupertype.Matcher.on(engine); + } + + @Override + public DirectSupertype.Matcher instantiate() { + return DirectSupertype.Matcher.create(); + } + + @Override + public DirectSupertype.Match newEmptyMatch() { + return DirectSupertype.Match.newEmptyMatch(); + } + + @Override + public DirectSupertype.Match newMatch(final Object... parameters) { + return DirectSupertype.Match.newMatch((org.eclipse.emf.ecore.EClass) parameters[0], (org.eclipse.emf.ecore.EClass) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.DirectSupertype (visibility: PUBLIC, simpleName: DirectSupertype, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.DirectSupertype, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.DirectSupertype (visibility: PUBLIC, simpleName: DirectSupertype, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.DirectSupertype, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static DirectSupertype INSTANCE = new DirectSupertype(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static DirectSupertype.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_a = new PParameter("a", "org.eclipse.emf.ecore.EClass", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EClass")), PParameterDirection.INOUT); + + private final PParameter parameter_b = new PParameter("b", "org.eclipse.emf.ecore.EClass", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EClass")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_a, parameter_b); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.directSupertype"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("a","b"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_a = body.getOrCreateVariableByName("a"); + PVariable var_b = body.getOrCreateVariableByName("b"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_b), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_a, parameter_a), + new ExportedParameter(body, var_b, parameter_b) + )); + // EClass.eSuperTypes(a,b) + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass", "eSuperTypes"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + new Equality(body, var__virtual_0_, var_b); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Live.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Live.java new file mode 100644 index 00000000..7bc2f458 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Live.java @@ -0,0 +1,730 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/FileSystem.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject; +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FileSystem; +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.PatternContent; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.BinaryTransitiveClosure; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}QueryBasedFeature
+ *         pattern live(this: FileSystem, l: FSObject) {
+ *         	FileSystem.root(this,l);
+ *         } or {
+ *         	FileSystem.root(this,root);
+ *         	find patternContent+(root,l);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class Live extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private FileSystem fThis; + + private FSObject fL; + + private static List parameterNames = makeImmutableList("this", "l"); + + private Match(final FileSystem pThis, final FSObject pL) { + this.fThis = pThis; + this.fL = pL; + } + + @Override + public Object get(final String parameterName) { + if ("this".equals(parameterName)) return this.fThis; + if ("l".equals(parameterName)) return this.fL; + return null; + } + + public FileSystem getThis() { + return this.fThis; + } + + public FSObject getL() { + return this.fL; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("this".equals(parameterName) ) { + this.fThis = (FileSystem) newValue; + return true; + } + if ("l".equals(parameterName) ) { + this.fL = (FSObject) newValue; + return true; + } + return false; + } + + public void setThis(final FileSystem pThis) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fThis = pThis; + } + + public void setL(final FSObject pL) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fL = pL; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live"; + } + + @Override + public List parameterNames() { + return Live.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fThis, fL}; + } + + @Override + public Live.Match toImmutable() { + return isMutable() ? newMatch(fThis, fL) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"this\"=" + prettyPrintValue(fThis) + ", "); + result.append("\"l\"=" + prettyPrintValue(fL)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fThis, fL); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof Live.Match)) { + Live.Match other = (Live.Match) obj; + return Objects.equals(fThis, other.fThis) && Objects.equals(fL, other.fL); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public Live specification() { + return Live.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static Live.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static Live.Match newMutableMatch(final FileSystem pThis, final FSObject pL) { + return new Mutable(pThis, pL); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return the (partial) match object. + * + */ + public static Live.Match newMatch(final FileSystem pThis, final FSObject pL) { + return new Immutable(pThis, pL); + } + + private static final class Mutable extends Live.Match { + Mutable(final FileSystem pThis, final FSObject pL) { + super(pThis, pL); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends Live.Match { + Immutable(final FileSystem pThis, final FSObject pL) { + super(pThis, pL); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}QueryBasedFeature
+   * pattern live(this: FileSystem, l: FSObject) {
+   * 	FileSystem.root(this,l);
+   * } or {
+   * 	FileSystem.root(this,root);
+   * 	find patternContent+(root,l);
+   * }
+   * 
+ * + * @see Match + * @see Live + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static Live.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static Live.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_THIS = 0; + + private final static int POSITION_L = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Live.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final FileSystem pThis, final FSObject pL) { + return rawStreamAllMatches(new Object[]{pThis, pL}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final FileSystem pThis, final FSObject pL) { + return rawStreamAllMatches(new Object[]{pThis, pL}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final FileSystem pThis, final FSObject pL) { + return rawGetOneArbitraryMatch(new Object[]{pThis, pL}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final FileSystem pThis, final FSObject pL) { + return rawHasMatch(new Object[]{pThis, pL}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final FileSystem pThis, final FSObject pL) { + return rawCountMatches(new Object[]{pThis, pL}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final FileSystem pThis, final FSObject pL, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pThis, pL}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pThis the fixed value of pattern parameter this, or null if not bound. + * @param pL the fixed value of pattern parameter l, or null if not bound. + * @return the (partial) match object. + * + */ + public Live.Match newMatch(final FileSystem pThis, final FSObject pL) { + return Live.Match.newMatch(pThis, pL); + } + + /** + * Retrieve the set of values that occur in matches for this. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfthis(final Object[] parameters) { + return rawStreamAllValues(POSITION_THIS, parameters).map(FileSystem.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for this. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfthis() { + return rawStreamAllValuesOfthis(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for this. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfthis() { + return rawStreamAllValuesOfthis(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for this. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfthis(final Live.Match partialMatch) { + return rawStreamAllValuesOfthis(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for this. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfthis(final FSObject pL) { + return rawStreamAllValuesOfthis(new Object[]{null, pL}); + } + + /** + * Retrieve the set of values that occur in matches for this. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfthis(final Live.Match partialMatch) { + return rawStreamAllValuesOfthis(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for this. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfthis(final FSObject pL) { + return rawStreamAllValuesOfthis(new Object[]{null, pL}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for l. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfl(final Object[] parameters) { + return rawStreamAllValues(POSITION_L, parameters).map(FSObject.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for l. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfl() { + return rawStreamAllValuesOfl(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for l. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfl() { + return rawStreamAllValuesOfl(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for l. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfl(final Live.Match partialMatch) { + return rawStreamAllValuesOfl(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for l. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfl(final FileSystem pThis) { + return rawStreamAllValuesOfl(new Object[]{pThis, null}); + } + + /** + * Retrieve the set of values that occur in matches for l. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfl(final Live.Match partialMatch) { + return rawStreamAllValuesOfl(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for l. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfl(final FileSystem pThis) { + return rawStreamAllValuesOfl(new Object[]{pThis, null}).collect(Collectors.toSet()); + } + + @Override + protected Live.Match tupleToMatch(final Tuple t) { + try { + return Live.Match.newMatch((FileSystem) t.get(POSITION_THIS), (FSObject) t.get(POSITION_L)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected Live.Match arrayToMatch(final Object[] match) { + try { + return Live.Match.newMatch((FileSystem) match[POSITION_THIS], (FSObject) match[POSITION_L]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected Live.Match arrayToMatchMutable(final Object[] match) { + try { + return Live.Match.newMutableMatch((FileSystem) match[POSITION_THIS], (FSObject) match[POSITION_L]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return Live.instance(); + } + } + + private Live() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static Live instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected Live.Matcher instantiate(final ViatraQueryEngine engine) { + return Live.Matcher.on(engine); + } + + @Override + public Live.Matcher instantiate() { + return Live.Matcher.create(); + } + + @Override + public Live.Match newEmptyMatch() { + return Live.Match.newEmptyMatch(); + } + + @Override + public Live.Match newMatch(final Object... parameters) { + return Live.Match.newMatch((hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FileSystem) parameters[0], (hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Live (visibility: PUBLIC, simpleName: Live, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Live, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Live (visibility: PUBLIC, simpleName: Live, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Live, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static Live INSTANCE = new Live(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static Live.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_this = new PParameter("this", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FileSystem", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "FileSystem")), PParameterDirection.INOUT); + + private final PParameter parameter_l = new PParameter("l", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "FSObject")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_this, parameter_l); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.live"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("this","l"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_this = body.getOrCreateVariableByName("this"); + PVariable var_l = body.getOrCreateVariableByName("l"); + new TypeConstraint(body, Tuples.flatTupleOf(var_this), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FileSystem"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_l), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_this, parameter_this), + new ExportedParameter(body, var_l, parameter_l) + )); + // FileSystem.root(this,l) + new TypeConstraint(body, Tuples.flatTupleOf(var_this), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FileSystem"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_this, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FS", "FileSystem", "root"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + new Equality(body, var__virtual_0_, var_l); + bodies.add(body); + } + { + PBody body = new PBody(this); + PVariable var_this = body.getOrCreateVariableByName("this"); + PVariable var_l = body.getOrCreateVariableByName("l"); + PVariable var_root = body.getOrCreateVariableByName("root"); + new TypeConstraint(body, Tuples.flatTupleOf(var_this), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FileSystem"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_l), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_this, parameter_this), + new ExportedParameter(body, var_l, parameter_l) + )); + // FileSystem.root(this,root) + new TypeConstraint(body, Tuples.flatTupleOf(var_this), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FileSystem"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_this, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FS", "FileSystem", "root"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + new Equality(body, var__virtual_0_, var_root); + // find patternContent+(root,l) + new BinaryTransitiveClosure(body, Tuples.flatTupleOf(var_root, var_l), PatternContent.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("QueryBasedFeature"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/LoopInInheritence.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/LoopInInheritence.java new file mode 100644 index 00000000..55afe7d0 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/LoopInInheritence.java @@ -0,0 +1,548 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Ecore.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.DirectSupertype; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.BinaryTransitiveClosure; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(key={a}, severity="error", message="error")
+ *         pattern loopInInheritence(a: EClass) {
+ *         	find directSupertype+(a,a);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class LoopInInheritence extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.loopInInheritence pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private EClass fA; + + private static List parameterNames = makeImmutableList("a"); + + private Match(final EClass pA) { + this.fA = pA; + } + + @Override + public Object get(final String parameterName) { + if ("a".equals(parameterName)) return this.fA; + return null; + } + + public EClass getA() { + return this.fA; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("a".equals(parameterName) ) { + this.fA = (EClass) newValue; + return true; + } + return false; + } + + public void setA(final EClass pA) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fA = pA; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.loopInInheritence"; + } + + @Override + public List parameterNames() { + return LoopInInheritence.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fA}; + } + + @Override + public LoopInInheritence.Match toImmutable() { + return isMutable() ? newMatch(fA) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"a\"=" + prettyPrintValue(fA)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fA); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof LoopInInheritence.Match)) { + LoopInInheritence.Match other = (LoopInInheritence.Match) obj; + return Objects.equals(fA, other.fA); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public LoopInInheritence specification() { + return LoopInInheritence.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static LoopInInheritence.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static LoopInInheritence.Match newMutableMatch(final EClass pA) { + return new Mutable(pA); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the (partial) match object. + * + */ + public static LoopInInheritence.Match newMatch(final EClass pA) { + return new Immutable(pA); + } + + private static final class Mutable extends LoopInInheritence.Match { + Mutable(final EClass pA) { + super(pA); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends LoopInInheritence.Match { + Immutable(final EClass pA) { + super(pA); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.loopInInheritence pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(key={a}, severity="error", message="error")
+   * pattern loopInInheritence(a: EClass) {
+   * 	find directSupertype+(a,a);
+   * }
+   * 
+ * + * @see Match + * @see LoopInInheritence + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static LoopInInheritence.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static LoopInInheritence.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_A = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(LoopInInheritence.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final EClass pA) { + return rawStreamAllMatches(new Object[]{pA}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final EClass pA) { + return rawStreamAllMatches(new Object[]{pA}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final EClass pA) { + return rawGetOneArbitraryMatch(new Object[]{pA}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final EClass pA) { + return rawHasMatch(new Object[]{pA}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final EClass pA) { + return rawCountMatches(new Object[]{pA}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final EClass pA, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pA}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the (partial) match object. + * + */ + public LoopInInheritence.Match newMatch(final EClass pA) { + return LoopInInheritence.Match.newMatch(pA); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfa(final Object[] parameters) { + return rawStreamAllValues(POSITION_A, parameters).map(EClass.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()); + } + + @Override + protected LoopInInheritence.Match tupleToMatch(final Tuple t) { + try { + return LoopInInheritence.Match.newMatch((EClass) t.get(POSITION_A)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected LoopInInheritence.Match arrayToMatch(final Object[] match) { + try { + return LoopInInheritence.Match.newMatch((EClass) match[POSITION_A]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected LoopInInheritence.Match arrayToMatchMutable(final Object[] match) { + try { + return LoopInInheritence.Match.newMutableMatch((EClass) match[POSITION_A]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return LoopInInheritence.instance(); + } + } + + private LoopInInheritence() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static LoopInInheritence instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected LoopInInheritence.Matcher instantiate(final ViatraQueryEngine engine) { + return LoopInInheritence.Matcher.on(engine); + } + + @Override + public LoopInInheritence.Matcher instantiate() { + return LoopInInheritence.Matcher.create(); + } + + @Override + public LoopInInheritence.Match newEmptyMatch() { + return LoopInInheritence.Match.newEmptyMatch(); + } + + @Override + public LoopInInheritence.Match newMatch(final Object... parameters) { + return LoopInInheritence.Match.newMatch((org.eclipse.emf.ecore.EClass) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.LoopInInheritence (visibility: PUBLIC, simpleName: LoopInInheritence, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.LoopInInheritence, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.LoopInInheritence (visibility: PUBLIC, simpleName: LoopInInheritence, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.LoopInInheritence, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static LoopInInheritence INSTANCE = new LoopInInheritence(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static LoopInInheritence.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_a = new PParameter("a", "org.eclipse.emf.ecore.EClass", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EClass")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_a); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.loopInInheritence"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("a"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_a = body.getOrCreateVariableByName("a"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_a, parameter_a) + )); + // find directSupertype+(a,a) + new BinaryTransitiveClosure(body, Tuples.flatTupleOf(var_a, var_a), DirectSupertype.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("a") + })); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/NonSymmetricOpposite.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/NonSymmetricOpposite.java new file mode 100644 index 00000000..5b24ef84 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/NonSymmetricOpposite.java @@ -0,0 +1,707 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Ecore.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Opposite; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(key={a}, severity="error", message="error")
+ *         pattern nonSymmetricOpposite(a:EReference, b:EReference) {
+ *         	find opposite(a,b);
+ *         	neg find opposite(b,a);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class NonSymmetricOpposite extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.nonSymmetricOpposite pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private EReference fA; + + private EReference fB; + + private static List parameterNames = makeImmutableList("a", "b"); + + private Match(final EReference pA, final EReference pB) { + this.fA = pA; + this.fB = pB; + } + + @Override + public Object get(final String parameterName) { + if ("a".equals(parameterName)) return this.fA; + if ("b".equals(parameterName)) return this.fB; + return null; + } + + public EReference getA() { + return this.fA; + } + + public EReference getB() { + return this.fB; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("a".equals(parameterName) ) { + this.fA = (EReference) newValue; + return true; + } + if ("b".equals(parameterName) ) { + this.fB = (EReference) newValue; + return true; + } + return false; + } + + public void setA(final EReference pA) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fA = pA; + } + + public void setB(final EReference pB) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fB = pB; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.nonSymmetricOpposite"; + } + + @Override + public List parameterNames() { + return NonSymmetricOpposite.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fA, fB}; + } + + @Override + public NonSymmetricOpposite.Match toImmutable() { + return isMutable() ? newMatch(fA, fB) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"a\"=" + prettyPrintValue(fA) + ", "); + result.append("\"b\"=" + prettyPrintValue(fB)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fA, fB); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof NonSymmetricOpposite.Match)) { + NonSymmetricOpposite.Match other = (NonSymmetricOpposite.Match) obj; + return Objects.equals(fA, other.fA) && Objects.equals(fB, other.fB); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public NonSymmetricOpposite specification() { + return NonSymmetricOpposite.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static NonSymmetricOpposite.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static NonSymmetricOpposite.Match newMutableMatch(final EReference pA, final EReference pB) { + return new Mutable(pA, pB); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public static NonSymmetricOpposite.Match newMatch(final EReference pA, final EReference pB) { + return new Immutable(pA, pB); + } + + private static final class Mutable extends NonSymmetricOpposite.Match { + Mutable(final EReference pA, final EReference pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends NonSymmetricOpposite.Match { + Immutable(final EReference pA, final EReference pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.nonSymmetricOpposite pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(key={a}, severity="error", message="error")
+   * pattern nonSymmetricOpposite(a:EReference, b:EReference) {
+   * 	find opposite(a,b);
+   * 	neg find opposite(b,a);
+   * }
+   * 
+ * + * @see Match + * @see NonSymmetricOpposite + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static NonSymmetricOpposite.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static NonSymmetricOpposite.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_A = 0; + + private final static int POSITION_B = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NonSymmetricOpposite.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final EReference pA, final EReference pB) { + return rawStreamAllMatches(new Object[]{pA, pB}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final EReference pA, final EReference pB) { + return rawStreamAllMatches(new Object[]{pA, pB}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final EReference pA, final EReference pB) { + return rawGetOneArbitraryMatch(new Object[]{pA, pB}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final EReference pA, final EReference pB) { + return rawHasMatch(new Object[]{pA, pB}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final EReference pA, final EReference pB) { + return rawCountMatches(new Object[]{pA, pB}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final EReference pA, final EReference pB, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pA, pB}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public NonSymmetricOpposite.Match newMatch(final EReference pA, final EReference pB) { + return NonSymmetricOpposite.Match.newMatch(pA, pB); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfa(final Object[] parameters) { + return rawStreamAllValues(POSITION_A, parameters).map(EReference.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final NonSymmetricOpposite.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final EReference pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final NonSymmetricOpposite.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final EReference pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfb(final Object[] parameters) { + return rawStreamAllValues(POSITION_B, parameters).map(EReference.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final NonSymmetricOpposite.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final EReference pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final NonSymmetricOpposite.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final EReference pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}).collect(Collectors.toSet()); + } + + @Override + protected NonSymmetricOpposite.Match tupleToMatch(final Tuple t) { + try { + return NonSymmetricOpposite.Match.newMatch((EReference) t.get(POSITION_A), (EReference) t.get(POSITION_B)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected NonSymmetricOpposite.Match arrayToMatch(final Object[] match) { + try { + return NonSymmetricOpposite.Match.newMatch((EReference) match[POSITION_A], (EReference) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected NonSymmetricOpposite.Match arrayToMatchMutable(final Object[] match) { + try { + return NonSymmetricOpposite.Match.newMutableMatch((EReference) match[POSITION_A], (EReference) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return NonSymmetricOpposite.instance(); + } + } + + private NonSymmetricOpposite() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static NonSymmetricOpposite instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected NonSymmetricOpposite.Matcher instantiate(final ViatraQueryEngine engine) { + return NonSymmetricOpposite.Matcher.on(engine); + } + + @Override + public NonSymmetricOpposite.Matcher instantiate() { + return NonSymmetricOpposite.Matcher.create(); + } + + @Override + public NonSymmetricOpposite.Match newEmptyMatch() { + return NonSymmetricOpposite.Match.newEmptyMatch(); + } + + @Override + public NonSymmetricOpposite.Match newMatch(final Object... parameters) { + return NonSymmetricOpposite.Match.newMatch((org.eclipse.emf.ecore.EReference) parameters[0], (org.eclipse.emf.ecore.EReference) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.NonSymmetricOpposite (visibility: PUBLIC, simpleName: NonSymmetricOpposite, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.NonSymmetricOpposite, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.NonSymmetricOpposite (visibility: PUBLIC, simpleName: NonSymmetricOpposite, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.NonSymmetricOpposite, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static NonSymmetricOpposite INSTANCE = new NonSymmetricOpposite(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static NonSymmetricOpposite.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_a = new PParameter("a", "org.eclipse.emf.ecore.EReference", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EReference")), PParameterDirection.INOUT); + + private final PParameter parameter_b = new PParameter("b", "org.eclipse.emf.ecore.EReference", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EReference")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_a, parameter_b); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.nonSymmetricOpposite"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("a","b"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_a = body.getOrCreateVariableByName("a"); + PVariable var_b = body.getOrCreateVariableByName("b"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_b), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_a, parameter_a), + new ExportedParameter(body, var_b, parameter_b) + )); + // find opposite(a,b) + new PositivePatternCall(body, Tuples.flatTupleOf(var_a, var_b), Opposite.instance().getInternalQueryRepresentation()); + // neg find opposite(b,a) + new NegativePatternCall(body, Tuples.flatTupleOf(var_b, var_a), Opposite.instance().getInternalQueryRepresentation()); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("a") + })); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Opposite.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Opposite.java new file mode 100644 index 00000000..a8c3507d --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Opposite.java @@ -0,0 +1,693 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Ecore.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern opposite(a:EReference, b: EReference) {
+ *         	EReference.eOpposite(a,b);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class Opposite extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.opposite pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private EReference fA; + + private EReference fB; + + private static List parameterNames = makeImmutableList("a", "b"); + + private Match(final EReference pA, final EReference pB) { + this.fA = pA; + this.fB = pB; + } + + @Override + public Object get(final String parameterName) { + if ("a".equals(parameterName)) return this.fA; + if ("b".equals(parameterName)) return this.fB; + return null; + } + + public EReference getA() { + return this.fA; + } + + public EReference getB() { + return this.fB; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("a".equals(parameterName) ) { + this.fA = (EReference) newValue; + return true; + } + if ("b".equals(parameterName) ) { + this.fB = (EReference) newValue; + return true; + } + return false; + } + + public void setA(final EReference pA) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fA = pA; + } + + public void setB(final EReference pB) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fB = pB; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.opposite"; + } + + @Override + public List parameterNames() { + return Opposite.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fA, fB}; + } + + @Override + public Opposite.Match toImmutable() { + return isMutable() ? newMatch(fA, fB) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"a\"=" + prettyPrintValue(fA) + ", "); + result.append("\"b\"=" + prettyPrintValue(fB)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fA, fB); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof Opposite.Match)) { + Opposite.Match other = (Opposite.Match) obj; + return Objects.equals(fA, other.fA) && Objects.equals(fB, other.fB); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public Opposite specification() { + return Opposite.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static Opposite.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static Opposite.Match newMutableMatch(final EReference pA, final EReference pB) { + return new Mutable(pA, pB); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public static Opposite.Match newMatch(final EReference pA, final EReference pB) { + return new Immutable(pA, pB); + } + + private static final class Mutable extends Opposite.Match { + Mutable(final EReference pA, final EReference pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends Opposite.Match { + Immutable(final EReference pA, final EReference pB) { + super(pA, pB); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.opposite pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern opposite(a:EReference, b: EReference) {
+   * 	EReference.eOpposite(a,b);
+   * }
+   * 
+ * + * @see Match + * @see Opposite + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static Opposite.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static Opposite.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_A = 0; + + private final static int POSITION_B = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Opposite.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final EReference pA, final EReference pB) { + return rawStreamAllMatches(new Object[]{pA, pB}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final EReference pA, final EReference pB) { + return rawStreamAllMatches(new Object[]{pA, pB}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final EReference pA, final EReference pB) { + return rawGetOneArbitraryMatch(new Object[]{pA, pB}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final EReference pA, final EReference pB) { + return rawHasMatch(new Object[]{pA, pB}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final EReference pA, final EReference pB) { + return rawCountMatches(new Object[]{pA, pB}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final EReference pA, final EReference pB, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pA, pB}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param pB the fixed value of pattern parameter b, or null if not bound. + * @return the (partial) match object. + * + */ + public Opposite.Match newMatch(final EReference pA, final EReference pB) { + return Opposite.Match.newMatch(pA, pB); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfa(final Object[] parameters) { + return rawStreamAllValues(POSITION_A, parameters).map(EReference.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final Opposite.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for a. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa(final EReference pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final Opposite.Match partialMatch) { + return rawStreamAllValuesOfa(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa(final EReference pB) { + return rawStreamAllValuesOfa(new Object[]{null, pB}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfb(final Object[] parameters) { + return rawStreamAllValues(POSITION_B, parameters).map(EReference.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb() { + return rawStreamAllValuesOfb(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final Opposite.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for b. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfb(final EReference pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final Opposite.Match partialMatch) { + return rawStreamAllValuesOfb(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for b. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfb(final EReference pA) { + return rawStreamAllValuesOfb(new Object[]{pA, null}).collect(Collectors.toSet()); + } + + @Override + protected Opposite.Match tupleToMatch(final Tuple t) { + try { + return Opposite.Match.newMatch((EReference) t.get(POSITION_A), (EReference) t.get(POSITION_B)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected Opposite.Match arrayToMatch(final Object[] match) { + try { + return Opposite.Match.newMatch((EReference) match[POSITION_A], (EReference) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected Opposite.Match arrayToMatchMutable(final Object[] match) { + try { + return Opposite.Match.newMutableMatch((EReference) match[POSITION_A], (EReference) match[POSITION_B]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return Opposite.instance(); + } + } + + private Opposite() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static Opposite instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected Opposite.Matcher instantiate(final ViatraQueryEngine engine) { + return Opposite.Matcher.on(engine); + } + + @Override + public Opposite.Matcher instantiate() { + return Opposite.Matcher.create(); + } + + @Override + public Opposite.Match newEmptyMatch() { + return Opposite.Match.newEmptyMatch(); + } + + @Override + public Opposite.Match newMatch(final Object... parameters) { + return Opposite.Match.newMatch((org.eclipse.emf.ecore.EReference) parameters[0], (org.eclipse.emf.ecore.EReference) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Opposite (visibility: PUBLIC, simpleName: Opposite, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Opposite, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Opposite (visibility: PUBLIC, simpleName: Opposite, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Opposite, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static Opposite INSTANCE = new Opposite(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static Opposite.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_a = new PParameter("a", "org.eclipse.emf.ecore.EReference", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EReference")), PParameterDirection.INOUT); + + private final PParameter parameter_b = new PParameter("b", "org.eclipse.emf.ecore.EReference", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EReference")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_a, parameter_b); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.opposite"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("a","b"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_a = body.getOrCreateVariableByName("a"); + PVariable var_b = body.getOrCreateVariableByName("b"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_b), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_a, parameter_a), + new ExportedParameter(body, var_b, parameter_b) + )); + // EReference.eOpposite(a,b) + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference", "eOpposite"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + new Equality(body, var__virtual_0_, var_b); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/OppositeDifferentClass.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/OppositeDifferentClass.java new file mode 100644 index 00000000..0f8b6357 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/OppositeDifferentClass.java @@ -0,0 +1,577 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/Ecore.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; +import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         {@literal @}Constraint(key={a}, severity="error", message="error")
+ *         pattern oppositeDifferentClass(a:EReference) {
+ *         	EReference.eOpposite(a,b);
+ *         	EReference.eContainingClass(a,aContaining);
+ *         	EReference.eType(b,bTarget);
+ *         	aContaining != bTarget;
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class OppositeDifferentClass extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.oppositeDifferentClass pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private EReference fA; + + private static List parameterNames = makeImmutableList("a"); + + private Match(final EReference pA) { + this.fA = pA; + } + + @Override + public Object get(final String parameterName) { + if ("a".equals(parameterName)) return this.fA; + return null; + } + + public EReference getA() { + return this.fA; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("a".equals(parameterName) ) { + this.fA = (EReference) newValue; + return true; + } + return false; + } + + public void setA(final EReference pA) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fA = pA; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.oppositeDifferentClass"; + } + + @Override + public List parameterNames() { + return OppositeDifferentClass.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fA}; + } + + @Override + public OppositeDifferentClass.Match toImmutable() { + return isMutable() ? newMatch(fA) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"a\"=" + prettyPrintValue(fA)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fA); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof OppositeDifferentClass.Match)) { + OppositeDifferentClass.Match other = (OppositeDifferentClass.Match) obj; + return Objects.equals(fA, other.fA); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public OppositeDifferentClass specification() { + return OppositeDifferentClass.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static OppositeDifferentClass.Match newEmptyMatch() { + return new Mutable(null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static OppositeDifferentClass.Match newMutableMatch(final EReference pA) { + return new Mutable(pA); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the (partial) match object. + * + */ + public static OppositeDifferentClass.Match newMatch(final EReference pA) { + return new Immutable(pA); + } + + private static final class Mutable extends OppositeDifferentClass.Match { + Mutable(final EReference pA) { + super(pA); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends OppositeDifferentClass.Match { + Immutable(final EReference pA) { + super(pA); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.oppositeDifferentClass pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * {@literal @}Constraint(key={a}, severity="error", message="error")
+   * pattern oppositeDifferentClass(a:EReference) {
+   * 	EReference.eOpposite(a,b);
+   * 	EReference.eContainingClass(a,aContaining);
+   * 	EReference.eType(b,bTarget);
+   * 	aContaining != bTarget;
+   * }
+   * 
+ * + * @see Match + * @see OppositeDifferentClass + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static OppositeDifferentClass.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static OppositeDifferentClass.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_A = 0; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(OppositeDifferentClass.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final EReference pA) { + return rawStreamAllMatches(new Object[]{pA}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final EReference pA) { + return rawStreamAllMatches(new Object[]{pA}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final EReference pA) { + return rawGetOneArbitraryMatch(new Object[]{pA}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final EReference pA) { + return rawHasMatch(new Object[]{pA}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final EReference pA) { + return rawCountMatches(new Object[]{pA}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final EReference pA, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pA}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pA the fixed value of pattern parameter a, or null if not bound. + * @return the (partial) match object. + * + */ + public OppositeDifferentClass.Match newMatch(final EReference pA) { + return OppositeDifferentClass.Match.newMatch(pA); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfa(final Object[] parameters) { + return rawStreamAllValues(POSITION_A, parameters).map(EReference.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for a. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfa() { + return rawStreamAllValuesOfa(emptyArray()); + } + + @Override + protected OppositeDifferentClass.Match tupleToMatch(final Tuple t) { + try { + return OppositeDifferentClass.Match.newMatch((EReference) t.get(POSITION_A)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected OppositeDifferentClass.Match arrayToMatch(final Object[] match) { + try { + return OppositeDifferentClass.Match.newMatch((EReference) match[POSITION_A]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected OppositeDifferentClass.Match arrayToMatchMutable(final Object[] match) { + try { + return OppositeDifferentClass.Match.newMutableMatch((EReference) match[POSITION_A]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return OppositeDifferentClass.instance(); + } + } + + private OppositeDifferentClass() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static OppositeDifferentClass instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected OppositeDifferentClass.Matcher instantiate(final ViatraQueryEngine engine) { + return OppositeDifferentClass.Matcher.on(engine); + } + + @Override + public OppositeDifferentClass.Matcher instantiate() { + return OppositeDifferentClass.Matcher.create(); + } + + @Override + public OppositeDifferentClass.Match newEmptyMatch() { + return OppositeDifferentClass.Match.newEmptyMatch(); + } + + @Override + public OppositeDifferentClass.Match newMatch(final Object... parameters) { + return OppositeDifferentClass.Match.newMatch((org.eclipse.emf.ecore.EReference) parameters[0]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.OppositeDifferentClass (visibility: PUBLIC, simpleName: OppositeDifferentClass, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.OppositeDifferentClass, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.OppositeDifferentClass (visibility: PUBLIC, simpleName: OppositeDifferentClass, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.OppositeDifferentClass, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static OppositeDifferentClass INSTANCE = new OppositeDifferentClass(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static OppositeDifferentClass.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_a = new PParameter("a", "org.eclipse.emf.ecore.EReference", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.eclipse.org/emf/2002/Ecore", "EReference")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_a); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.oppositeDifferentClass"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("a"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_a = body.getOrCreateVariableByName("a"); + PVariable var_b = body.getOrCreateVariableByName("b"); + PVariable var_aContaining = body.getOrCreateVariableByName("aContaining"); + PVariable var_bTarget = body.getOrCreateVariableByName("bTarget"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_a, parameter_a) + )); + // EReference.eOpposite(a,b) + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference", "eOpposite"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + new Equality(body, var__virtual_0_, var_b); + // EReference.eContainingClass(a,aContaining) + new TypeConstraint(body, Tuples.flatTupleOf(var_a), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_a, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.eclipse.org/emf/2002/Ecore", "EStructuralFeature", "eContainingClass"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClass"))); + new Equality(body, var__virtual_1_, var_aContaining); + // EReference.eType(b,bTarget) + new TypeConstraint(body, Tuples.flatTupleOf(var_b), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EReference"))); + PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_b, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.eclipse.org/emf/2002/Ecore", "ETypedElement", "eType"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.eclipse.org/emf/2002/Ecore", "EClassifier"))); + new Equality(body, var__virtual_2_, var_bTarget); + // aContaining != bTarget + new Inequality(body, var_aContaining, var_bTarget); + bodies.add(body); + } + { + PAnnotation annotation = new PAnnotation("Constraint"); + annotation.addAttribute("key", Arrays.asList(new Object[] { + new ParameterReference("a") + })); + annotation.addAttribute("severity", "error"); + annotation.addAttribute("message", "error"); + addAnnotation(annotation); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/PatternContent.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/PatternContent.java new file mode 100644 index 00000000..f9bab96e --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/src-gen/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/PatternContent.java @@ -0,0 +1,693 @@ +/** + * Generated from platform:/resource/hu.bme.mit.inf.dslreasoner.domains.alloyexamples/patterns/hu/bme/mit/inf/dslreasoner/domains/alloyexamples/FileSystem.vql + */ +package hu.bme.mit.inf.dslreasoner.domains.alloyexamples; + +import hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject; +import java.util.Arrays; +import java.util.Collection; +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Objects; +import java.util.Optional; +import java.util.Set; +import java.util.function.Consumer; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import org.apache.log4j.Logger; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.viatra.query.runtime.api.IPatternMatch; +import org.eclipse.viatra.query.runtime.api.IQuerySpecification; +import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; +import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; +import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; +import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; +import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; +import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; +import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; +import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; +import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; +import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; +import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; +import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; + +/** + * A pattern-specific query specification that can instantiate Matcher in a type-safe way. + * + *

Original source: + *

+ *         pattern patternContent(o1: FSObject, o2: FSObject) {
+ *         	Dir.contents(o1,o2);
+ *         }
+ * 
+ * + * @see Matcher + * @see Match + * + */ +@SuppressWarnings("all") +public final class PatternContent extends BaseGeneratedEMFQuerySpecification { + /** + * Pattern-specific match representation of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.patternContent pattern, + * to be used in conjunction with {@link Matcher}. + * + *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. + * Each instance is a (possibly partial) substitution of pattern parameters, + * usable to represent a match of the pattern in the result of a query, + * or to specify the bound (fixed) input parameters when issuing a query. + * + * @see Matcher + * + */ + public static abstract class Match extends BasePatternMatch { + private FSObject fO1; + + private FSObject fO2; + + private static List parameterNames = makeImmutableList("o1", "o2"); + + private Match(final FSObject pO1, final FSObject pO2) { + this.fO1 = pO1; + this.fO2 = pO2; + } + + @Override + public Object get(final String parameterName) { + if ("o1".equals(parameterName)) return this.fO1; + if ("o2".equals(parameterName)) return this.fO2; + return null; + } + + public FSObject getO1() { + return this.fO1; + } + + public FSObject getO2() { + return this.fO2; + } + + @Override + public boolean set(final String parameterName, final Object newValue) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + if ("o1".equals(parameterName) ) { + this.fO1 = (FSObject) newValue; + return true; + } + if ("o2".equals(parameterName) ) { + this.fO2 = (FSObject) newValue; + return true; + } + return false; + } + + public void setO1(final FSObject pO1) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fO1 = pO1; + } + + public void setO2(final FSObject pO2) { + if (!isMutable()) throw new java.lang.UnsupportedOperationException(); + this.fO2 = pO2; + } + + @Override + public String patternName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.patternContent"; + } + + @Override + public List parameterNames() { + return PatternContent.Match.parameterNames; + } + + @Override + public Object[] toArray() { + return new Object[]{fO1, fO2}; + } + + @Override + public PatternContent.Match toImmutable() { + return isMutable() ? newMatch(fO1, fO2) : this; + } + + @Override + public String prettyPrint() { + StringBuilder result = new StringBuilder(); + result.append("\"o1\"=" + prettyPrintValue(fO1) + ", "); + result.append("\"o2\"=" + prettyPrintValue(fO2)); + return result.toString(); + } + + @Override + public int hashCode() { + return Objects.hash(fO1, fO2); + } + + @Override + public boolean equals(final Object obj) { + if (this == obj) + return true; + if (obj == null) { + return false; + } + if ((obj instanceof PatternContent.Match)) { + PatternContent.Match other = (PatternContent.Match) obj; + return Objects.equals(fO1, other.fO1) && Objects.equals(fO2, other.fO2); + } else { + // this should be infrequent + if (!(obj instanceof IPatternMatch)) { + return false; + } + IPatternMatch otherSig = (IPatternMatch) obj; + return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); + } + } + + @Override + public PatternContent specification() { + return PatternContent.instance(); + } + + /** + * Returns an empty, mutable match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @return the empty match. + * + */ + public static PatternContent.Match newEmptyMatch() { + return new Mutable(null, null); + } + + /** + * Returns a mutable (partial) match. + * Fields of the mutable match can be filled to create a partial match, usable as matcher input. + * + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return the new, mutable (partial) match object. + * + */ + public static PatternContent.Match newMutableMatch(final FSObject pO1, final FSObject pO2) { + return new Mutable(pO1, pO2); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return the (partial) match object. + * + */ + public static PatternContent.Match newMatch(final FSObject pO1, final FSObject pO2) { + return new Immutable(pO1, pO2); + } + + private static final class Mutable extends PatternContent.Match { + Mutable(final FSObject pO1, final FSObject pO2) { + super(pO1, pO2); + } + + @Override + public boolean isMutable() { + return true; + } + } + + private static final class Immutable extends PatternContent.Match { + Immutable(final FSObject pO1, final FSObject pO2) { + super(pO1, pO2); + } + + @Override + public boolean isMutable() { + return false; + } + } + } + + /** + * Generated pattern matcher API of the hu.bme.mit.inf.dslreasoner.domains.alloyexamples.patternContent pattern, + * providing pattern-specific query methods. + * + *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, + * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. + * + *

Matches of the pattern will be represented as {@link Match}. + * + *

Original source: + *

+   * pattern patternContent(o1: FSObject, o2: FSObject) {
+   * 	Dir.contents(o1,o2);
+   * }
+   * 
+ * + * @see Match + * @see PatternContent + * + */ + public static class Matcher extends BaseMatcher { + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + public static PatternContent.Matcher on(final ViatraQueryEngine engine) { + // check if matcher already exists + Matcher matcher = engine.getExistingMatcher(querySpecification()); + if (matcher == null) { + matcher = (Matcher)engine.getMatcher(querySpecification()); + } + return matcher; + } + + /** + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * @return an initialized matcher + * @noreference This method is for internal matcher initialization by the framework, do not call it manually. + * + */ + public static PatternContent.Matcher create() { + return new Matcher(); + } + + private final static int POSITION_O1 = 0; + + private final static int POSITION_O2 = 1; + + private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(PatternContent.Matcher.class); + + /** + * Initializes the pattern matcher within an existing VIATRA Query engine. + * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. + * + * @param engine the existing VIATRA Query engine in which this matcher will be created. + * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation + * + */ + private Matcher() { + super(querySpecification()); + } + + /** + * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return matches represented as a Match object. + * + */ + public Collection getAllMatches(final FSObject pO1, final FSObject pO2) { + return rawStreamAllMatches(new Object[]{pO1, pO2}).collect(Collectors.toSet()); + } + + /** + * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return a stream of matches represented as a Match object. + * + */ + public Stream streamAllMatches(final FSObject pO1, final FSObject pO2) { + return rawStreamAllMatches(new Object[]{pO1, pO2}); + } + + /** + * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return a match represented as a Match object, or null if no match is found. + * + */ + public Optional getOneArbitraryMatch(final FSObject pO1, final FSObject pO2) { + return rawGetOneArbitraryMatch(new Object[]{pO1, pO2}); + } + + /** + * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, + * under any possible substitution of the unspecified parameters (if any). + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return true if the input is a valid (partial) match of the pattern. + * + */ + public boolean hasMatch(final FSObject pO1, final FSObject pO2) { + return rawHasMatch(new Object[]{pO1, pO2}); + } + + /** + * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return the number of pattern matches found. + * + */ + public int countMatches(final FSObject pO1, final FSObject pO2) { + return rawCountMatches(new Object[]{pO1, pO2}); + } + + /** + * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. + * Neither determinism nor randomness of selection is guaranteed. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @param processor the action that will process the selected match. + * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked + * + */ + public boolean forOneArbitraryMatch(final FSObject pO1, final FSObject pO2, final Consumer processor) { + return rawForOneArbitraryMatch(new Object[]{pO1, pO2}, processor); + } + + /** + * Returns a new (partial) match. + * This can be used e.g. to call the matcher with a partial match. + *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. + * @param pO1 the fixed value of pattern parameter o1, or null if not bound. + * @param pO2 the fixed value of pattern parameter o2, or null if not bound. + * @return the (partial) match object. + * + */ + public PatternContent.Match newMatch(final FSObject pO1, final FSObject pO2) { + return PatternContent.Match.newMatch(pO1, pO2); + } + + /** + * Retrieve the set of values that occur in matches for o1. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfo1(final Object[] parameters) { + return rawStreamAllValues(POSITION_O1, parameters).map(FSObject.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for o1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo1() { + return rawStreamAllValuesOfo1(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for o1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo1() { + return rawStreamAllValuesOfo1(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for o1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo1(final PatternContent.Match partialMatch) { + return rawStreamAllValuesOfo1(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for o1. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo1(final FSObject pO2) { + return rawStreamAllValuesOfo1(new Object[]{null, pO2}); + } + + /** + * Retrieve the set of values that occur in matches for o1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo1(final PatternContent.Match partialMatch) { + return rawStreamAllValuesOfo1(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for o1. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo1(final FSObject pO2) { + return rawStreamAllValuesOfo1(new Object[]{null, pO2}).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for o2. + * @return the Set of all values or empty set if there are no matches + * + */ + protected Stream rawStreamAllValuesOfo2(final Object[] parameters) { + return rawStreamAllValues(POSITION_O2, parameters).map(FSObject.class::cast); + } + + /** + * Retrieve the set of values that occur in matches for o2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo2() { + return rawStreamAllValuesOfo2(emptyArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for o2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo2() { + return rawStreamAllValuesOfo2(emptyArray()); + } + + /** + * Retrieve the set of values that occur in matches for o2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo2(final PatternContent.Match partialMatch) { + return rawStreamAllValuesOfo2(partialMatch.toArray()); + } + + /** + * Retrieve the set of values that occur in matches for o2. + *

+ * NOTE: It is important not to modify the source model while the stream is being processed. + * If the match set of the pattern changes during processing, the contents of the stream is undefined. + * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. + * + * @return the Stream of all values or empty set if there are no matches + * + */ + public Stream streamAllValuesOfo2(final FSObject pO1) { + return rawStreamAllValuesOfo2(new Object[]{pO1, null}); + } + + /** + * Retrieve the set of values that occur in matches for o2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo2(final PatternContent.Match partialMatch) { + return rawStreamAllValuesOfo2(partialMatch.toArray()).collect(Collectors.toSet()); + } + + /** + * Retrieve the set of values that occur in matches for o2. + * @return the Set of all values or empty set if there are no matches + * + */ + public Set getAllValuesOfo2(final FSObject pO1) { + return rawStreamAllValuesOfo2(new Object[]{pO1, null}).collect(Collectors.toSet()); + } + + @Override + protected PatternContent.Match tupleToMatch(final Tuple t) { + try { + return PatternContent.Match.newMatch((FSObject) t.get(POSITION_O1), (FSObject) t.get(POSITION_O2)); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in tuple not properly typed!",e); + return null; + } + } + + @Override + protected PatternContent.Match arrayToMatch(final Object[] match) { + try { + return PatternContent.Match.newMatch((FSObject) match[POSITION_O1], (FSObject) match[POSITION_O2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + @Override + protected PatternContent.Match arrayToMatchMutable(final Object[] match) { + try { + return PatternContent.Match.newMutableMatch((FSObject) match[POSITION_O1], (FSObject) match[POSITION_O2]); + } catch(ClassCastException e) { + LOGGER.error("Element(s) in array not properly typed!",e); + return null; + } + } + + /** + * @return the singleton instance of the query specification of this pattern + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static IQuerySpecification querySpecification() { + return PatternContent.instance(); + } + } + + private PatternContent() { + super(GeneratedPQuery.INSTANCE); + } + + /** + * @return the singleton instance of the query specification + * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded + * + */ + public static PatternContent instance() { + try{ + return LazyHolder.INSTANCE; + } catch (ExceptionInInitializerError err) { + throw processInitializerError(err); + } + } + + @Override + protected PatternContent.Matcher instantiate(final ViatraQueryEngine engine) { + return PatternContent.Matcher.on(engine); + } + + @Override + public PatternContent.Matcher instantiate() { + return PatternContent.Matcher.create(); + } + + @Override + public PatternContent.Match newEmptyMatch() { + return PatternContent.Match.newEmptyMatch(); + } + + @Override + public PatternContent.Match newMatch(final Object... parameters) { + return PatternContent.Match.newMatch((hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject) parameters[0], (hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject) parameters[1]); + } + + /** + * Inner class allowing the singleton instance of {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.PatternContent (visibility: PUBLIC, simpleName: PatternContent, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.PatternContent, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * not at the class load time of the outer class, + * but rather at the first call to {@link JvmGenericType: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.PatternContent (visibility: PUBLIC, simpleName: PatternContent, identifier: hu.bme.mit.inf.dslreasoner.domains.alloyexamples.PatternContent, deprecated: ) (abstract: false, static: false, final: true, packageName: hu.bme.mit.inf.dslreasoner.domains.alloyexamples) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * + *

This workaround is required e.g. to support recursion. + * + */ + private static class LazyHolder { + private final static PatternContent INSTANCE = new PatternContent(); + + /** + * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. + * This initialization order is required to support indirect recursion. + * + *

The static initializer is defined using a helper field to work around limitations of the code generator. + * + */ + private final static Object STATIC_INITIALIZER = ensureInitialized(); + + public static Object ensureInitialized() { + INSTANCE.ensureInitializedInternal(); + return null; + } + } + + private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { + private final static PatternContent.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + + private final PParameter parameter_o1 = new PParameter("o1", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "FSObject")), PParameterDirection.INOUT); + + private final PParameter parameter_o2 = new PParameter("o2", "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.Filesystem.FSObject", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FS", "FSObject")), PParameterDirection.INOUT); + + private final List parameters = Arrays.asList(parameter_o1, parameter_o2); + + private GeneratedPQuery() { + super(PVisibility.PUBLIC); + } + + @Override + public String getFullyQualifiedName() { + return "hu.bme.mit.inf.dslreasoner.domains.alloyexamples.patternContent"; + } + + @Override + public List getParameterNames() { + return Arrays.asList("o1","o2"); + } + + @Override + public List getParameters() { + return parameters; + } + + @Override + public Set doGetContainedBodies() { + setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); + Set bodies = new LinkedHashSet<>(); + { + PBody body = new PBody(this); + PVariable var_o1 = body.getOrCreateVariableByName("o1"); + PVariable var_o2 = body.getOrCreateVariableByName("o2"); + new TypeConstraint(body, Tuples.flatTupleOf(var_o1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + new TypeConstraint(body, Tuples.flatTupleOf(var_o2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + body.setSymbolicParameters(Arrays.asList( + new ExportedParameter(body, var_o1, parameter_o1), + new ExportedParameter(body, var_o2, parameter_o2) + )); + // Dir.contents(o1,o2) + new TypeConstraint(body, Tuples.flatTupleOf(var_o1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "Dir"))); + PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); + new TypeConstraint(body, Tuples.flatTupleOf(var_o1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FS", "Dir", "contents"))); + new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FS", "FSObject"))); + new Equality(body, var__virtual_0_, var_o2); + bodies.add(body); + } + return bodies; + } + } +} diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF index f15381b2..f2fd2ff3 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF @@ -6,17 +6,15 @@ Bundle-Version: 1.0.0.qualifier Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin -Export-Package: hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm, - hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl, - hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.util, - hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu, - hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu.mutated, - hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu.mutated.util, - hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu.util -Require-Bundle: org.eclipse.viatra.query.runtime, - org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - com.google.guava;bundle-version="15.0.0" +Export-Package: hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm, + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl, + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.util, + hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu, + hu.bme.mit.inf.dslreasoner.partialsnapshot_mavo.yakindu.mutated +Require-Bundle: org.eclipse.viatra.query.runtime, + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport, + com.google.guava;bundle-version="15.0.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy Import-Package: org.apache.log4j diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/.classpath b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/.classpath index e84a3295..a9e661c7 100644 --- a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/.classpath +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/.classpath @@ -7,5 +7,6 @@ + diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF index 8e1bba03..27b81f93 100644 --- a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF @@ -3,7 +3,6 @@ Bundle-ManifestVersion: 2 Bundle-Name: %pluginName Bundle-SymbolicName: hu.bme.mit.inf.dslreasoner.logic.model;singleton:=true Bundle-Version: 1.0.0.qualifier -Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: hu.bme.mit.inf.dslreasoner.logic.model.builder, @@ -30,7 +29,7 @@ Require-Bundle: org.eclipse.core.runtime, org.eclipse.viatra.query.runtime;bundle-version="1.3.0", org.apache.commons.lang;bundle-version="2.6.0", org.eclipse.emf.ecore.xmi;bundle-version="2.13.0" +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 +Bundle-ActivationPolicy: lazy Import-Package: org.apache.log4j Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.logic.model -Bundle-ActivationPolicy: lazy -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/build.properties b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/build.properties index 9403fc5f..c18a0403 100644 --- a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/build.properties +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/build.properties @@ -8,5 +8,6 @@ source.. = ecore-gen/,\ src/,\ xtend-gen/,\ patterns/,\ - vql-gen/ + vql-gen/,\ + src-gen/ output.. = bin/ diff --git a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/.classpath b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/.classpath index de68b5f7..a29b9deb 100644 --- a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/.classpath +++ b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/.classpath @@ -7,5 +7,6 @@ + diff --git a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/build.properties b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/build.properties index 685c072b..1eb934ae 100644 --- a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/build.properties +++ b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/build.properties @@ -6,5 +6,6 @@ jars.compile.order = . source.. = src/,\ queries/,\ xtend-gen/,\ - vql-gen/ + vql-gen/,\ + src-gen/ output.. = bin/ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.classpath b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.classpath deleted file mode 100644 index a0c6dd9c..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.project b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.project deleted file mode 100644 index 85d1308e..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/.project +++ /dev/null @@ -1,29 +0,0 @@ - - - ca.mcgill.ecse.dslreasoner.trace.logic2vampire - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.sirius.nature.modelingproject - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/META-INF/MANIFEST.MF b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/META-INF/MANIFEST.MF deleted file mode 100644 index f4f91de8..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/META-INF/MANIFEST.MF +++ /dev/null @@ -1,7 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: ca.mcgill.ecse.dslreasoner.trace.logic2vampire -Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.trace.logic2vampire; singleton:=true -Bundle-Version: 0.1.0.qualifier -Require-Bundle: org.eclipse.emf.ecore;visibility:=reexport, - org.eclipse.core.runtime diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.aird b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.aird deleted file mode 100644 index 4fda4ff6..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.aird +++ /dev/null @@ -1,30 +0,0 @@ - - - - logic2vampire.ecore - logic2vampire.genmodel - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.ecore b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.ecore deleted file mode 100644 index 0cdf6d7f..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.ecore +++ /dev/null @@ -1,4 +0,0 @@ - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.genmodel b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.genmodel deleted file mode 100644 index 32de743d..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.trace.logic2vampire/model/logic2vampire.genmodel +++ /dev/null @@ -1,14 +0,0 @@ - - - logic2vampire.ecore - - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 035b992e..416a4ced 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 3a2b0f09..4c3a5366 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index b8a39035..b9e07a68 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index c462e145..f51dce03 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 2d3b2709..23bdd607 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 8640966e..438765b1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 183e5e40..fb05770c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 7c2fb4bf..1626ed6c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFiniteModel.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFiniteModel.java deleted file mode 100644 index bfd23d8d..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFiniteModel.java +++ /dev/null @@ -1,20 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'VLS Finite Model'. - * - * - * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSFiniteModel() - * @model - * @generated - */ -public interface VLSFiniteModel extends EObject -{ -} // VLSFiniteModel diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFunctionFof.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFunctionFof.java deleted file mode 100644 index d151685f..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSFunctionFof.java +++ /dev/null @@ -1,69 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage; - -import org.eclipse.emf.common.util.EList; - -/** - * - * A representation of the model object 'VLS Function Fof'. - * - * - *

- * The following features are supported: - *

- *
    - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof#getFunctor Functor}
  • - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof#getTerms Terms}
  • - *
- * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSFunctionFof() - * @model - * @generated - */ -public interface VLSFunctionFof extends VLSTerm -{ - /** - * Returns the value of the 'Functor' attribute. - * - *

- * If the meaning of the 'Functor' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Functor' attribute. - * @see #setFunctor(String) - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSFunctionFof_Functor() - * @model - * @generated - */ - String getFunctor(); - - /** - * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof#getFunctor Functor}' attribute. - * - * - * @param value the new value of the 'Functor' attribute. - * @see #getFunctor() - * @generated - */ - void setFunctor(String value); - - /** - * Returns the value of the 'Terms' containment reference list. - * The list contents are of type {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm}. - * - *

- * If the meaning of the 'Terms' containment reference list isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Terms' containment reference list. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSFunctionFof_Terms() - * @model containment="true" - * @generated - */ - EList getTerms(); - -} // VLSFunctionFof diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTrying.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTrying.java deleted file mode 100644 index c2080a9c..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTrying.java +++ /dev/null @@ -1,52 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * A representation of the model object 'VLS Trying'. - * - * - *

- * The following features are supported: - *

- *
    - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTrying#getName Name}
  • - *
- * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSTrying() - * @model - * @generated - */ -public interface VLSTrying extends EObject -{ - /** - * Returns the value of the 'Name' attribute. - * - *

- * If the meaning of the 'Name' attribute isn't clear, - * there really should be more of a description here... - *

- * - * @return the value of the 'Name' attribute. - * @see #setName(String) - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSTrying_Name() - * @model - * @generated - */ - String getName(); - - /** - * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTrying#getName Name}' attribute. - * - * - * @param value the new value of the 'Name' attribute. - * @see #getName() - * @generated - */ - void setName(String value); - -} // VLSTrying diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFiniteModelImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFiniteModelImpl.java deleted file mode 100644 index dfbbf6ed..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFiniteModelImpl.java +++ /dev/null @@ -1,43 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage.impl; - -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFiniteModel; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; - -/** - * - * An implementation of the model object 'VLS Finite Model'. - * - * - * @generated - */ -public class VLSFiniteModelImpl extends MinimalEObjectImpl.Container implements VLSFiniteModel -{ - /** - * - * - * @generated - */ - protected VLSFiniteModelImpl() - { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() - { - return VampireLanguagePackage.Literals.VLS_FINITE_MODEL; - } - -} //VLSFiniteModelImpl diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFunctionFofImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFunctionFofImpl.java deleted file mode 100644 index 6d1c538b..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSFunctionFofImpl.java +++ /dev/null @@ -1,240 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage.impl; - -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage; - -import java.util.Collection; - -import org.eclipse.emf.common.notify.Notification; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; - -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.InternalEList; - -/** - * - * An implementation of the model object 'VLS Function Fof'. - * - *

- * The following features are implemented: - *

- *
    - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSFunctionFofImpl#getFunctor Functor}
  • - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSFunctionFofImpl#getTerms Terms}
  • - *
- * - * @generated - */ -public class VLSFunctionFofImpl extends VLSTermImpl implements VLSFunctionFof -{ - /** - * The default value of the '{@link #getFunctor() Functor}' attribute. - * - * - * @see #getFunctor() - * @generated - * @ordered - */ - protected static final String FUNCTOR_EDEFAULT = null; - - /** - * The cached value of the '{@link #getFunctor() Functor}' attribute. - * - * - * @see #getFunctor() - * @generated - * @ordered - */ - protected String functor = FUNCTOR_EDEFAULT; - - /** - * The cached value of the '{@link #getTerms() Terms}' containment reference list. - * - * - * @see #getTerms() - * @generated - * @ordered - */ - protected EList terms; - - /** - * - * - * @generated - */ - protected VLSFunctionFofImpl() - { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() - { - return VampireLanguagePackage.Literals.VLS_FUNCTION_FOF; - } - - /** - * - * - * @generated - */ - public String getFunctor() - { - return functor; - } - - /** - * - * - * @generated - */ - public void setFunctor(String newFunctor) - { - String oldFunctor = functor; - functor = newFunctor; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, VampireLanguagePackage.VLS_FUNCTION_FOF__FUNCTOR, oldFunctor, functor)); - } - - /** - * - * - * @generated - */ - public EList getTerms() - { - if (terms == null) - { - terms = new EObjectContainmentEList(VLSTerm.class, this, VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS); - } - return terms; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS: - return ((InternalEList)getTerms()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_FUNCTION_FOF__FUNCTOR: - return getFunctor(); - case VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS: - return getTerms(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_FUNCTION_FOF__FUNCTOR: - setFunctor((String)newValue); - return; - case VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS: - getTerms().clear(); - getTerms().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_FUNCTION_FOF__FUNCTOR: - setFunctor(FUNCTOR_EDEFAULT); - return; - case VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS: - getTerms().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_FUNCTION_FOF__FUNCTOR: - return FUNCTOR_EDEFAULT == null ? functor != null : !FUNCTOR_EDEFAULT.equals(functor); - case VampireLanguagePackage.VLS_FUNCTION_FOF__TERMS: - return terms != null && !terms.isEmpty(); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (functor: "); - result.append(functor); - result.append(')'); - return result.toString(); - } - -} //VLSFunctionFofImpl diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTryingImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTryingImpl.java deleted file mode 100644 index 40e62d9e..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTryingImpl.java +++ /dev/null @@ -1,178 +0,0 @@ -/** - * generated by Xtext 2.12.0 - */ -package ca.mcgill.ecse.dslreasoner.vampireLanguage.impl; - -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTrying; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage; - -import org.eclipse.emf.common.notify.Notification; - -import org.eclipse.emf.ecore.EClass; - -import org.eclipse.emf.ecore.impl.ENotificationImpl; -import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; - -/** - * - * An implementation of the model object 'VLS Trying'. - * - *

- * The following features are implemented: - *

- *
    - *
  • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTryingImpl#getName Name}
  • - *
- * - * @generated - */ -public class VLSTryingImpl extends MinimalEObjectImpl.Container implements VLSTrying -{ - /** - * The default value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected static final String NAME_EDEFAULT = null; - - /** - * The cached value of the '{@link #getName() Name}' attribute. - * - * - * @see #getName() - * @generated - * @ordered - */ - protected String name = NAME_EDEFAULT; - - /** - * - * - * @generated - */ - protected VLSTryingImpl() - { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() - { - return VampireLanguagePackage.Literals.VLS_TRYING; - } - - /** - * - * - * @generated - */ - public String getName() - { - return name; - } - - /** - * - * - * @generated - */ - public void setName(String newName) - { - String oldName = name; - name = newName; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, VampireLanguagePackage.VLS_TRYING__NAME, oldName, name)); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_TRYING__NAME: - return getName(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @Override - public void eSet(int featureID, Object newValue) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_TRYING__NAME: - setName((String)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_TRYING__NAME: - setName(NAME_EDEFAULT); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) - { - switch (featureID) - { - case VampireLanguagePackage.VLS_TRYING__NAME: - return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name); - } - return super.eIsSet(featureID); - } - - /** - * - * - * @generated - */ - @Override - public String toString() - { - if (eIsProxy()) return super.toString(); - - StringBuffer result = new StringBuffer(super.toString()); - result.append(" (name: "); - result.append(name); - result.append(')'); - return result.toString(); - } - -} //VLSTryingImpl diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 415d0cc9..c38505ea 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index 9d43d4a1..3ab52ff6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index d3a5a764..e845ff1e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index dd4b1eaa..d45af918 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index a3a95c68..cc9d50ce 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 88c7412c..0418e131 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/.gitignore b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/.gitignore index ae3c1726..39fc9cc5 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/.gitignore +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/.gitignore @@ -1 +1,2 @@ /bin/ +/src-gen/ \ No newline at end of file diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnd.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnd.java deleted file mode 100644 index 23d9293f..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnd.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSAnd(term: VLSAnd){
- *         	VLSAnd(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSAnd extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd"; - } - - @Override - public List parameterNames() { - return VLSAnd.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSAnd.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSAnd.Match)) { - VLSAnd.Match other = (VLSAnd.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSAnd specification() { - return VLSAnd.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSAnd.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSAnd.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSAnd.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSAnd.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSAnd.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSAnd(term: VLSAnd){
-   * 	VLSAnd(term);
-   * }
-   * 
- * - * @see Match - * @see VLSAnd - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSAnd.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSAnd.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSAnd.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSAnd.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd pTerm) { - return VLSAnd.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSAnd.Match tupleToMatch(final Tuple t) { - try { - return VLSAnd.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSAnd.Match arrayToMatch(final Object[] match) { - try { - return VLSAnd.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSAnd.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSAnd.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSAnd.instance(); - } - } - - private VLSAnd() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSAnd instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSAnd.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSAnd.Matcher.on(engine); - } - - @Override - public VLSAnd.Matcher instantiate() { - return VLSAnd.Matcher.create(); - } - - @Override - public VLSAnd.Match newEmptyMatch() { - return VLSAnd.Match.newEmptyMatch(); - } - - @Override - public VLSAnd.Match newMatch(final Object... parameters) { - return VLSAnd.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd (visibility: PUBLIC, simpleName: VLSAnd, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd (visibility: PUBLIC, simpleName: VLSAnd, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSAnd INSTANCE = new VLSAnd(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSAnd.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnd")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnd"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSAnd(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnd"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnnotation.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnnotation.java deleted file mode 100644 index 282d813f..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSAnnotation.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSAnnotation(term: VLSAnnotation){
- *         	VLSAnnotation(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSAnnotation extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation"; - } - - @Override - public List parameterNames() { - return VLSAnnotation.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSAnnotation.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSAnnotation.Match)) { - VLSAnnotation.Match other = (VLSAnnotation.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSAnnotation specification() { - return VLSAnnotation.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSAnnotation.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSAnnotation.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSAnnotation.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSAnnotation.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSAnnotation.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSAnnotation(term: VLSAnnotation){
-   * 	VLSAnnotation(term);
-   * }
-   * 
- * - * @see Match - * @see VLSAnnotation - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSAnnotation.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSAnnotation.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSAnnotation.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSAnnotation.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation pTerm) { - return VLSAnnotation.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSAnnotation.Match tupleToMatch(final Tuple t) { - try { - return VLSAnnotation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSAnnotation.Match arrayToMatch(final Object[] match) { - try { - return VLSAnnotation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSAnnotation.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSAnnotation.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSAnnotation.instance(); - } - } - - private VLSAnnotation() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSAnnotation instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSAnnotation.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSAnnotation.Matcher.on(engine); - } - - @Override - public VLSAnnotation.Matcher instantiate() { - return VLSAnnotation.Matcher.create(); - } - - @Override - public VLSAnnotation.Match newEmptyMatch() { - return VLSAnnotation.Match.newEmptyMatch(); - } - - @Override - public VLSAnnotation.Match newMatch(final Object... parameters) { - return VLSAnnotation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation (visibility: PUBLIC, simpleName: VLSAnnotation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation (visibility: PUBLIC, simpleName: VLSAnnotation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSAnnotation INSTANCE = new VLSAnnotation(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSAnnotation.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnnotation", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnnotation")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnnotation"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSAnnotation(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSAnnotation"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSComment.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSComment.java deleted file mode 100644 index ec2bfef3..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSComment.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSComment(term: VLSComment){
- *         	VLSComment(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSComment extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment"; - } - - @Override - public List parameterNames() { - return VLSComment.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSComment.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSComment.Match)) { - VLSComment.Match other = (VLSComment.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSComment specification() { - return VLSComment.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSComment.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSComment.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSComment.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSComment.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSComment.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSComment(term: VLSComment){
-   * 	VLSComment(term);
-   * }
-   * 
- * - * @see Match - * @see VLSComment - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSComment.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSComment.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSComment.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSComment.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment pTerm) { - return VLSComment.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSComment.Match tupleToMatch(final Tuple t) { - try { - return VLSComment.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSComment.Match arrayToMatch(final Object[] match) { - try { - return VLSComment.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSComment.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSComment.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSComment.instance(); - } - } - - private VLSComment() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSComment instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSComment.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSComment.Matcher.on(engine); - } - - @Override - public VLSComment.Matcher instantiate() { - return VLSComment.Matcher.create(); - } - - @Override - public VLSComment.Match newEmptyMatch() { - return VLSComment.Match.newEmptyMatch(); - } - - @Override - public VLSComment.Match newMatch(final Object... parameters) { - return VLSComment.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment (visibility: PUBLIC, simpleName: VLSComment, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment (visibility: PUBLIC, simpleName: VLSComment, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSComment INSTANCE = new VLSComment(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSComment.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSComment", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSComment")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSComment"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSComment(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSComment"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSEquivalent.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSEquivalent.java deleted file mode 100644 index 5a174fed..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSEquivalent.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSEquivalent(term: VLSEquivalent){
- *         	VLSEquivalent(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSEquivalent extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent"; - } - - @Override - public List parameterNames() { - return VLSEquivalent.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSEquivalent.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSEquivalent.Match)) { - VLSEquivalent.Match other = (VLSEquivalent.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSEquivalent specification() { - return VLSEquivalent.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSEquivalent.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSEquivalent.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSEquivalent.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSEquivalent.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSEquivalent.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSEquivalent(term: VLSEquivalent){
-   * 	VLSEquivalent(term);
-   * }
-   * 
- * - * @see Match - * @see VLSEquivalent - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSEquivalent.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSEquivalent.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSEquivalent.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSEquivalent.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent pTerm) { - return VLSEquivalent.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSEquivalent.Match tupleToMatch(final Tuple t) { - try { - return VLSEquivalent.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSEquivalent.Match arrayToMatch(final Object[] match) { - try { - return VLSEquivalent.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSEquivalent.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSEquivalent.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSEquivalent.instance(); - } - } - - private VLSEquivalent() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSEquivalent instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSEquivalent.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSEquivalent.Matcher.on(engine); - } - - @Override - public VLSEquivalent.Matcher instantiate() { - return VLSEquivalent.Matcher.create(); - } - - @Override - public VLSEquivalent.Match newEmptyMatch() { - return VLSEquivalent.Match.newEmptyMatch(); - } - - @Override - public VLSEquivalent.Match newMatch(final Object... parameters) { - return VLSEquivalent.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent (visibility: PUBLIC, simpleName: VLSEquivalent, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent (visibility: PUBLIC, simpleName: VLSEquivalent, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSEquivalent INSTANCE = new VLSEquivalent(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSEquivalent.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSEquivalent")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSEquivalent"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSEquivalent(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSEquivalent"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSExistentialQuantifier.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSExistentialQuantifier.java deleted file mode 100644 index 137e4ca0..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSExistentialQuantifier.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSExistentialQuantifier(term: VLSExistentialQuantifier){
- *         	VLSExistentialQuantifier(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSExistentialQuantifier extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier"; - } - - @Override - public List parameterNames() { - return VLSExistentialQuantifier.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSExistentialQuantifier.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSExistentialQuantifier.Match)) { - VLSExistentialQuantifier.Match other = (VLSExistentialQuantifier.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSExistentialQuantifier specification() { - return VLSExistentialQuantifier.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSExistentialQuantifier.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSExistentialQuantifier.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSExistentialQuantifier.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSExistentialQuantifier.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSExistentialQuantifier.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSExistentialQuantifier(term: VLSExistentialQuantifier){
-   * 	VLSExistentialQuantifier(term);
-   * }
-   * 
- * - * @see Match - * @see VLSExistentialQuantifier - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSExistentialQuantifier.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSExistentialQuantifier.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSExistentialQuantifier.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSExistentialQuantifier.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier pTerm) { - return VLSExistentialQuantifier.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSExistentialQuantifier.Match tupleToMatch(final Tuple t) { - try { - return VLSExistentialQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSExistentialQuantifier.Match arrayToMatch(final Object[] match) { - try { - return VLSExistentialQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSExistentialQuantifier.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSExistentialQuantifier.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSExistentialQuantifier.instance(); - } - } - - private VLSExistentialQuantifier() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSExistentialQuantifier instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSExistentialQuantifier.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSExistentialQuantifier.Matcher.on(engine); - } - - @Override - public VLSExistentialQuantifier.Matcher instantiate() { - return VLSExistentialQuantifier.Matcher.create(); - } - - @Override - public VLSExistentialQuantifier.Match newEmptyMatch() { - return VLSExistentialQuantifier.Match.newEmptyMatch(); - } - - @Override - public VLSExistentialQuantifier.Match newMatch(final Object... parameters) { - return VLSExistentialQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier (visibility: PUBLIC, simpleName: VLSExistentialQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier (visibility: PUBLIC, simpleName: VLSExistentialQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSExistentialQuantifier INSTANCE = new VLSExistentialQuantifier(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSExistentialQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSExistentialQuantifier")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSExistentialQuantifier"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSExistentialQuantifier(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSExistentialQuantifier"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFofFormula.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFofFormula.java deleted file mode 100644 index f55f408a..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFofFormula.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSFofFormula(term: VLSFofFormula){
- *         	VLSFofFormula(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSFofFormula extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula"; - } - - @Override - public List parameterNames() { - return VLSFofFormula.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSFofFormula.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSFofFormula.Match)) { - VLSFofFormula.Match other = (VLSFofFormula.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSFofFormula specification() { - return VLSFofFormula.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSFofFormula.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSFofFormula.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSFofFormula.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSFofFormula.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSFofFormula.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSFofFormula(term: VLSFofFormula){
-   * 	VLSFofFormula(term);
-   * }
-   * 
- * - * @see Match - * @see VLSFofFormula - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSFofFormula.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSFofFormula.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSFofFormula.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSFofFormula.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula pTerm) { - return VLSFofFormula.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSFofFormula.Match tupleToMatch(final Tuple t) { - try { - return VLSFofFormula.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSFofFormula.Match arrayToMatch(final Object[] match) { - try { - return VLSFofFormula.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSFofFormula.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSFofFormula.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSFofFormula.instance(); - } - } - - private VLSFofFormula() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSFofFormula instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSFofFormula.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSFofFormula.Matcher.on(engine); - } - - @Override - public VLSFofFormula.Matcher instantiate() { - return VLSFofFormula.Matcher.create(); - } - - @Override - public VLSFofFormula.Match newEmptyMatch() { - return VLSFofFormula.Match.newEmptyMatch(); - } - - @Override - public VLSFofFormula.Match newMatch(final Object... parameters) { - return VLSFofFormula.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula (visibility: PUBLIC, simpleName: VLSFofFormula, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula (visibility: PUBLIC, simpleName: VLSFofFormula, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSFofFormula INSTANCE = new VLSFofFormula(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSFofFormula.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFofFormula")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFofFormula"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSFofFormula(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFofFormula"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunction.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunction.java deleted file mode 100644 index f81a6e1a..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunction.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSFunction(term: VLSFunction){
- *         	VLSFunction(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSFunction extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction"; - } - - @Override - public List parameterNames() { - return VLSFunction.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSFunction.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSFunction.Match)) { - VLSFunction.Match other = (VLSFunction.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSFunction specification() { - return VLSFunction.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSFunction.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSFunction.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSFunction.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSFunction.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSFunction.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSFunction(term: VLSFunction){
-   * 	VLSFunction(term);
-   * }
-   * 
- * - * @see Match - * @see VLSFunction - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSFunction.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSFunction.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSFunction.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSFunction.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction pTerm) { - return VLSFunction.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSFunction.Match tupleToMatch(final Tuple t) { - try { - return VLSFunction.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSFunction.Match arrayToMatch(final Object[] match) { - try { - return VLSFunction.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSFunction.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSFunction.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSFunction.instance(); - } - } - - private VLSFunction() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSFunction instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSFunction.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSFunction.Matcher.on(engine); - } - - @Override - public VLSFunction.Matcher instantiate() { - return VLSFunction.Matcher.create(); - } - - @Override - public VLSFunction.Match newEmptyMatch() { - return VLSFunction.Match.newEmptyMatch(); - } - - @Override - public VLSFunction.Match newMatch(final Object... parameters) { - return VLSFunction.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction (visibility: PUBLIC, simpleName: VLSFunction, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction (visibility: PUBLIC, simpleName: VLSFunction, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSFunction INSTANCE = new VLSFunction(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSFunction.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunction")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunction"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSFunction(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunction"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunctionFof.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunctionFof.java deleted file mode 100644 index 86a3b95c..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSFunctionFof.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSFunctionFof(term: VLSFunctionFof){
- *         	VLSFunctionFof(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSFunctionFof extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof"; - } - - @Override - public List parameterNames() { - return VLSFunctionFof.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSFunctionFof.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSFunctionFof.Match)) { - VLSFunctionFof.Match other = (VLSFunctionFof.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSFunctionFof specification() { - return VLSFunctionFof.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSFunctionFof.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSFunctionFof.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSFunctionFof.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSFunctionFof.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSFunctionFof.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSFunctionFof(term: VLSFunctionFof){
-   * 	VLSFunctionFof(term);
-   * }
-   * 
- * - * @see Match - * @see VLSFunctionFof - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSFunctionFof.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSFunctionFof.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSFunctionFof.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSFunctionFof.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof pTerm) { - return VLSFunctionFof.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSFunctionFof.Match tupleToMatch(final Tuple t) { - try { - return VLSFunctionFof.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSFunctionFof.Match arrayToMatch(final Object[] match) { - try { - return VLSFunctionFof.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSFunctionFof.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSFunctionFof.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSFunctionFof.instance(); - } - } - - private VLSFunctionFof() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSFunctionFof instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSFunctionFof.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSFunctionFof.Matcher.on(engine); - } - - @Override - public VLSFunctionFof.Matcher instantiate() { - return VLSFunctionFof.Matcher.create(); - } - - @Override - public VLSFunctionFof.Match newEmptyMatch() { - return VLSFunctionFof.Match.newEmptyMatch(); - } - - @Override - public VLSFunctionFof.Match newMatch(final Object... parameters) { - return VLSFunctionFof.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof (visibility: PUBLIC, simpleName: VLSFunctionFof, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof (visibility: PUBLIC, simpleName: VLSFunctionFof, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSFunctionFof INSTANCE = new VLSFunctionFof(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSFunctionFof.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunctionFof", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunctionFof")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunctionFof"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSFunctionFof(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSFunctionFof"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSInequality.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSInequality.java deleted file mode 100644 index 0dd35ed9..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSInequality.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSInequality(term: VLSInequality){
- *         	VLSInequality(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSInequality extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality"; - } - - @Override - public List parameterNames() { - return VLSInequality.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSInequality.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSInequality.Match)) { - VLSInequality.Match other = (VLSInequality.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSInequality specification() { - return VLSInequality.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSInequality.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSInequality.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSInequality.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSInequality.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSInequality.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSInequality(term: VLSInequality){
-   * 	VLSInequality(term);
-   * }
-   * 
- * - * @see Match - * @see VLSInequality - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSInequality.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSInequality.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSInequality.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSInequality.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality pTerm) { - return VLSInequality.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSInequality.Match tupleToMatch(final Tuple t) { - try { - return VLSInequality.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSInequality.Match arrayToMatch(final Object[] match) { - try { - return VLSInequality.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSInequality.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSInequality.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSInequality.instance(); - } - } - - private VLSInequality() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSInequality instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSInequality.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSInequality.Matcher.on(engine); - } - - @Override - public VLSInequality.Matcher instantiate() { - return VLSInequality.Matcher.create(); - } - - @Override - public VLSInequality.Match newEmptyMatch() { - return VLSInequality.Match.newEmptyMatch(); - } - - @Override - public VLSInequality.Match newMatch(final Object... parameters) { - return VLSInequality.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality (visibility: PUBLIC, simpleName: VLSInequality, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality (visibility: PUBLIC, simpleName: VLSInequality, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSInequality INSTANCE = new VLSInequality(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSInequality.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSInequality", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSInequality")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSInequality"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSInequality(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSInequality"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSOr.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSOr.java deleted file mode 100644 index 0d8e0648..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSOr.java +++ /dev/null @@ -1,535 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         //VLSFormula
- *         pattern VLSOr(term: VLSOr){
- *         	VLSOr(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSOr extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr"; - } - - @Override - public List parameterNames() { - return VLSOr.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSOr.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSOr.Match)) { - VLSOr.Match other = (VLSOr.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSOr specification() { - return VLSOr.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSOr.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSOr.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSOr.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSOr.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSOr.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * //VLSFormula
-   * pattern VLSOr(term: VLSOr){
-   * 	VLSOr(term);
-   * }
-   * 
- * - * @see Match - * @see VLSOr - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSOr.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSOr.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSOr.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSOr.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr pTerm) { - return VLSOr.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSOr.Match tupleToMatch(final Tuple t) { - try { - return VLSOr.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSOr.Match arrayToMatch(final Object[] match) { - try { - return VLSOr.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSOr.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSOr.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSOr.instance(); - } - } - - private VLSOr() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSOr instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSOr.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSOr.Matcher.on(engine); - } - - @Override - public VLSOr.Matcher instantiate() { - return VLSOr.Matcher.create(); - } - - @Override - public VLSOr.Match newEmptyMatch() { - return VLSOr.Match.newEmptyMatch(); - } - - @Override - public VLSOr.Match newMatch(final Object... parameters) { - return VLSOr.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr (visibility: PUBLIC, simpleName: VLSOr, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr (visibility: PUBLIC, simpleName: VLSOr, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSOr INSTANCE = new VLSOr(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSOr.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSOr")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSOr"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSOr(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSOr"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUnaryNegation.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUnaryNegation.java deleted file mode 100644 index b6290aab..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUnaryNegation.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSUnaryNegation(term: VLSUnaryNegation){
- *         	VLSUnaryNegation(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSUnaryNegation extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation"; - } - - @Override - public List parameterNames() { - return VLSUnaryNegation.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSUnaryNegation.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSUnaryNegation.Match)) { - VLSUnaryNegation.Match other = (VLSUnaryNegation.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSUnaryNegation specification() { - return VLSUnaryNegation.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSUnaryNegation.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSUnaryNegation.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSUnaryNegation.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSUnaryNegation.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSUnaryNegation.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSUnaryNegation(term: VLSUnaryNegation){
-   * 	VLSUnaryNegation(term);
-   * }
-   * 
- * - * @see Match - * @see VLSUnaryNegation - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSUnaryNegation.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSUnaryNegation.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSUnaryNegation.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSUnaryNegation.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation pTerm) { - return VLSUnaryNegation.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSUnaryNegation.Match tupleToMatch(final Tuple t) { - try { - return VLSUnaryNegation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSUnaryNegation.Match arrayToMatch(final Object[] match) { - try { - return VLSUnaryNegation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSUnaryNegation.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSUnaryNegation.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSUnaryNegation.instance(); - } - } - - private VLSUnaryNegation() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSUnaryNegation instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSUnaryNegation.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSUnaryNegation.Matcher.on(engine); - } - - @Override - public VLSUnaryNegation.Matcher instantiate() { - return VLSUnaryNegation.Matcher.create(); - } - - @Override - public VLSUnaryNegation.Match newEmptyMatch() { - return VLSUnaryNegation.Match.newEmptyMatch(); - } - - @Override - public VLSUnaryNegation.Match newMatch(final Object... parameters) { - return VLSUnaryNegation.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation (visibility: PUBLIC, simpleName: VLSUnaryNegation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation (visibility: PUBLIC, simpleName: VLSUnaryNegation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSUnaryNegation INSTANCE = new VLSUnaryNegation(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSUnaryNegation.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUnaryNegation", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUnaryNegation")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUnaryNegation"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSUnaryNegation(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUnaryNegation"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUniversalQuantifier.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUniversalQuantifier.java deleted file mode 100644 index 0dab9771..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VLSUniversalQuantifier.java +++ /dev/null @@ -1,533 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern VLSUniversalQuantifier(term: VLSUniversalQuantifier){
- *         	VLSUniversalQuantifier(term);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class VLSUniversalQuantifier extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier fTerm; - - private static List parameterNames = makeImmutableList("term"); - - private Match(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - this.fTerm = pTerm; - } - - @Override - public Object get(final String parameterName) { - if ("term".equals(parameterName)) return this.fTerm; - return null; - } - - public ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier getTerm() { - return this.fTerm; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("term".equals(parameterName) ) { - this.fTerm = (ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier) newValue; - return true; - } - return false; - } - - public void setTerm(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTerm = pTerm; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier"; - } - - @Override - public List parameterNames() { - return VLSUniversalQuantifier.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fTerm}; - } - - @Override - public VLSUniversalQuantifier.Match toImmutable() { - return isMutable() ? newMatch(fTerm) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"term\"=" + prettyPrintValue(fTerm)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fTerm); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof VLSUniversalQuantifier.Match)) { - VLSUniversalQuantifier.Match other = (VLSUniversalQuantifier.Match) obj; - return Objects.equals(fTerm, other.fTerm); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public VLSUniversalQuantifier specification() { - return VLSUniversalQuantifier.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static VLSUniversalQuantifier.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static VLSUniversalQuantifier.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return new Mutable(pTerm); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public static VLSUniversalQuantifier.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return new Immutable(pTerm); - } - - private static final class Mutable extends VLSUniversalQuantifier.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends VLSUniversalQuantifier.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - super(pTerm); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern VLSUniversalQuantifier(term: VLSUniversalQuantifier){
-   * 	VLSUniversalQuantifier(term);
-   * }
-   * 
- * - * @see Match - * @see VLSUniversalQuantifier - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static VLSUniversalQuantifier.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static VLSUniversalQuantifier.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_TERM = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(VLSUniversalQuantifier.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return rawStreamAllMatches(new Object[]{pTerm}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return rawGetOneArbitraryMatch(new Object[]{pTerm}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return rawHasMatch(new Object[]{pTerm}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return rawCountMatches(new Object[]{pTerm}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pTerm}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pTerm the fixed value of pattern parameter term, or null if not bound. - * @return the (partial) match object. - * - */ - public VLSUniversalQuantifier.Match newMatch(final ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier pTerm) { - return VLSUniversalQuantifier.Match.newMatch(pTerm); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfterm(final Object[] parameters) { - return rawStreamAllValues(POSITION_TERM, parameters).map(ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for term. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfterm() { - return rawStreamAllValuesOfterm(emptyArray()); - } - - @Override - protected VLSUniversalQuantifier.Match tupleToMatch(final Tuple t) { - try { - return VLSUniversalQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier) t.get(POSITION_TERM)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected VLSUniversalQuantifier.Match arrayToMatch(final Object[] match) { - try { - return VLSUniversalQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected VLSUniversalQuantifier.Match arrayToMatchMutable(final Object[] match) { - try { - return VLSUniversalQuantifier.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier) match[POSITION_TERM]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return VLSUniversalQuantifier.instance(); - } - } - - private VLSUniversalQuantifier() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static VLSUniversalQuantifier instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected VLSUniversalQuantifier.Matcher instantiate(final ViatraQueryEngine engine) { - return VLSUniversalQuantifier.Matcher.on(engine); - } - - @Override - public VLSUniversalQuantifier.Matcher instantiate() { - return VLSUniversalQuantifier.Matcher.create(); - } - - @Override - public VLSUniversalQuantifier.Match newEmptyMatch() { - return VLSUniversalQuantifier.Match.newEmptyMatch(); - } - - @Override - public VLSUniversalQuantifier.Match newMatch(final Object... parameters) { - return VLSUniversalQuantifier.Match.newMatch((ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier (visibility: PUBLIC, simpleName: VLSUniversalQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier (visibility: PUBLIC, simpleName: VLSUniversalQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static VLSUniversalQuantifier INSTANCE = new VLSUniversalQuantifier(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSUniversalQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUniversalQuantifier")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_term); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("term"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_term = body.getOrCreateVariableByName("term"); - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUniversalQuantifier"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_term, parameter_term) - )); - // VLSUniversalQuantifier(term) - new TypeConstraint(body, Tuples.flatTupleOf(var_term), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUniversalQuantifier"))); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VampireQueries.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VampireQueries.java deleted file mode 100644 index e3518cd6..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/VampireQueries.java +++ /dev/null @@ -1,174 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.queries/src/ca/mcgill/ecse/dslreasoner/vampire/queries/vampireQueries.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnd; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSAnnotation; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSComment; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSEquivalent; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSExistentialQuantifier; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFofFormula; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunction; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSFunctionFof; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSInequality; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSOr; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUnaryNegation; -import ca.mcgill.ecse.dslreasoner.vampire.queries.VLSUniversalQuantifier; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedPatternGroup; - -/** - * A pattern group formed of all public patterns defined in vampireQueries.vql. - * - *

Use the static instance as any {@link interface org.eclipse.viatra.query.runtime.api.IQueryGroup}, to conveniently prepare - * a VIATRA Query engine for matching all patterns originally defined in file vampireQueries.vql, - * in order to achieve better performance than one-by-one on-demand matcher initialization. - * - *

From package ca.mcgill.ecse.dslreasoner.vampire.queries, the group contains the definition of the following patterns:

    - *
  • VLSComment
  • - *
  • VLSFofFormula
  • - *
  • VLSAnnotation
  • - *
  • VLSOr
  • - *
  • VLSAnd
  • - *
  • VLSEquivalent
  • - *
  • VLSFunction
  • - *
  • VLSExistentialQuantifier
  • - *
  • VLSUniversalQuantifier
  • - *
  • VLSUnaryNegation
  • - *
  • VLSInequality
  • - *
  • VLSFunctionFof
  • - *
- * - * @see IQueryGroup - * - */ -@SuppressWarnings("all") -public final class VampireQueries extends BaseGeneratedPatternGroup { - /** - * Access the pattern group. - * - * @return the singleton instance of the group - * @throws ViatraQueryRuntimeException if there was an error loading the generated code of pattern specifications - * - */ - public static VampireQueries instance() { - if (INSTANCE == null) { - INSTANCE = new VampireQueries(); - } - return INSTANCE; - } - - private static VampireQueries INSTANCE; - - private VampireQueries() { - querySpecifications.add(VLSComment.instance()); - querySpecifications.add(VLSFofFormula.instance()); - querySpecifications.add(VLSAnnotation.instance()); - querySpecifications.add(VLSOr.instance()); - querySpecifications.add(VLSAnd.instance()); - querySpecifications.add(VLSEquivalent.instance()); - querySpecifications.add(VLSFunction.instance()); - querySpecifications.add(VLSExistentialQuantifier.instance()); - querySpecifications.add(VLSUniversalQuantifier.instance()); - querySpecifications.add(VLSUnaryNegation.instance()); - querySpecifications.add(VLSInequality.instance()); - querySpecifications.add(VLSFunctionFof.instance()); - } - - public VLSComment getVLSComment() { - return VLSComment.instance(); - } - - public VLSComment.Matcher getVLSComment(final ViatraQueryEngine engine) { - return VLSComment.Matcher.on(engine); - } - - public VLSFofFormula getVLSFofFormula() { - return VLSFofFormula.instance(); - } - - public VLSFofFormula.Matcher getVLSFofFormula(final ViatraQueryEngine engine) { - return VLSFofFormula.Matcher.on(engine); - } - - public VLSAnnotation getVLSAnnotation() { - return VLSAnnotation.instance(); - } - - public VLSAnnotation.Matcher getVLSAnnotation(final ViatraQueryEngine engine) { - return VLSAnnotation.Matcher.on(engine); - } - - public VLSOr getVLSOr() { - return VLSOr.instance(); - } - - public VLSOr.Matcher getVLSOr(final ViatraQueryEngine engine) { - return VLSOr.Matcher.on(engine); - } - - public VLSAnd getVLSAnd() { - return VLSAnd.instance(); - } - - public VLSAnd.Matcher getVLSAnd(final ViatraQueryEngine engine) { - return VLSAnd.Matcher.on(engine); - } - - public VLSEquivalent getVLSEquivalent() { - return VLSEquivalent.instance(); - } - - public VLSEquivalent.Matcher getVLSEquivalent(final ViatraQueryEngine engine) { - return VLSEquivalent.Matcher.on(engine); - } - - public VLSFunction getVLSFunction() { - return VLSFunction.instance(); - } - - public VLSFunction.Matcher getVLSFunction(final ViatraQueryEngine engine) { - return VLSFunction.Matcher.on(engine); - } - - public VLSExistentialQuantifier getVLSExistentialQuantifier() { - return VLSExistentialQuantifier.instance(); - } - - public VLSExistentialQuantifier.Matcher getVLSExistentialQuantifier(final ViatraQueryEngine engine) { - return VLSExistentialQuantifier.Matcher.on(engine); - } - - public VLSUniversalQuantifier getVLSUniversalQuantifier() { - return VLSUniversalQuantifier.instance(); - } - - public VLSUniversalQuantifier.Matcher getVLSUniversalQuantifier(final ViatraQueryEngine engine) { - return VLSUniversalQuantifier.Matcher.on(engine); - } - - public VLSUnaryNegation getVLSUnaryNegation() { - return VLSUnaryNegation.instance(); - } - - public VLSUnaryNegation.Matcher getVLSUnaryNegation(final ViatraQueryEngine engine) { - return VLSUnaryNegation.Matcher.on(engine); - } - - public VLSInequality getVLSInequality() { - return VLSInequality.instance(); - } - - public VLSInequality.Matcher getVLSInequality(final ViatraQueryEngine engine) { - return VLSInequality.Matcher.on(engine); - } - - public VLSFunctionFof getVLSFunctionFof() { - return VLSFunctionFof.instance(); - } - - public VLSFunctionFof.Matcher getVLSFunctionFof(final ViatraQueryEngine engine) { - return VLSFunctionFof.Matcher.on(engine); - } -} diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/.gitignore b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/.gitignore index ae3c1726..8d2cfe73 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/.gitignore +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/.gitignore @@ -1 +1,3 @@ /bin/ +/src-gen/ +/xtend-gen/ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend index 0820f47d..ff5a192e 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend @@ -81,6 +81,14 @@ class Logic2VampireLanguageMapper_ContainmentMapper { val fromType = (l.parameters.get(0) as ComplexTypeReference).referred as Type val toType = (l.parameters.get(1) as ComplexTypeReference).referred as Type + val listForAnd = newArrayList +// listForAnd.add(support.duplicate(fromType.lookup(trace.type2Predicate), varB)) + listForAnd.add(support.duplicate((l as RelationDeclaration).lookup(trace.rel2Predicate), varList)) +// listForAnd.add(createVLSInequality => [ +// it.left = support.duplicate(varA) +// it.right = support.duplicate(varB) +// ]) + val relFormula = createVLSFofFormula => [ it.name = support.toIDMultiple("containment", relName) it.fofRole = "axiom" @@ -91,11 +99,7 @@ class Logic2VampireLanguageMapper_ContainmentMapper { it.left = support.duplicate(toType.lookup(trace.type2Predicate), varA) it.right = createVLSExistentialQuantifier => [ it.variables += support.duplicate(varB) - it.operand = createVLSAnd => [ - it.left = support.duplicate(fromType.lookup(trace.type2Predicate), varB) - it.right = support.duplicate((l as RelationDeclaration).lookup(trace.rel2Predicate), - varList) - ] + it.operand = support.unfoldAnd(listForAnd) ] createVLSEquality => [ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtend deleted file mode 100644 index aba47edb..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtend +++ /dev/null @@ -1,18 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder - -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.DefinedElement -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type -import java.util.HashMap -import java.util.Map - -class Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes implements Logic2VampireLanguageMapper_TypeMapperTrace{ - -// public var VLSFofFormula objectSuperClass - public val Map type2Predicate = new HashMap; - public val Map element2Predicate = new HashMap - public val Map type2PossibleNot = new HashMap - public val Map type2And = new HashMap - -} \ No newline at end of file diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index b86e8068..be554f99 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 8e50f399..0ee9b884 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 99ba52b8..8e96ba14 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 0210a300..ee720e29 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 7b01a284..528da797 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 9f455fdd..a1204329 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 0b91349d..3413fc3f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index 07e249ce..a53a998a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 115249ba..f265f6a3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index 2e86d0c7..efde8350 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtendbin deleted file mode 100644 index e870dabc..00000000 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.xtendbin and /dev/null differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper_FilteredTypes.xtendbin deleted file mode 100644 index ed198ef6..00000000 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper_FilteredTypes.xtendbin and /dev/null differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index cf8e4acd..2cabecc8 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 07d5b7b4..57844580 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 983108a2..24898f59 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 4442cdea..a9589e7e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java index da0e5615..8c0ae38d 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java @@ -3,7 +3,6 @@ package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapper; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapperTrace; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapper_Support; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSAnd; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSConstant; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquality; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent; @@ -118,6 +117,8 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { TypeReference _get_1 = l_1.getParameters().get(1); Type _referred_1 = ((ComplexTypeReference) _get_1).getReferred(); final Type toType = ((Type) _referred_1); + final ArrayList listForAnd = CollectionLiterals.newArrayList(); + listForAnd.add(this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_1), trace.rel2Predicate), varList)); VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); final Procedure1 _function_3 = (VLSFofFormula it) -> { it.setName(this.support.toIDMultiple("containment", relName)); @@ -135,13 +136,7 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { EList _variables_1 = it_3.getVariables(); VLSVariable _duplicate_1 = this.support.duplicate(varB); _variables_1.add(_duplicate_1); - VLSAnd _createVLSAnd = this.factory.createVLSAnd(); - final Procedure1 _function_7 = (VLSAnd it_4) -> { - it_4.setLeft(this.support.duplicate(CollectionsUtil.lookup(fromType, trace.type2Predicate), varB)); - it_4.setRight(this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_1), trace.rel2Predicate), varList)); - }; - VLSAnd _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSAnd, _function_7); - it_3.setOperand(_doubleArrow); + it_3.setOperand(this.support.unfoldAnd(listForAnd)); }; VLSExistentialQuantifier _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSExistentialQuantifier, _function_6); it_2.setRight(_doubleArrow); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.java deleted file mode 100644 index f7c6cb70..00000000 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes.java +++ /dev/null @@ -1,20 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder; - -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapper_TypeMapperTrace; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm; -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.DefinedElement; -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; -import java.util.HashMap; -import java.util.Map; - -@SuppressWarnings("all") -public class Logic2VampireLanguageMapper_TypeMapperTrace_FilteredTypes implements Logic2VampireLanguageMapper_TypeMapperTrace { - public final Map type2Predicate = new HashMap(); - - public final Map element2Predicate = new HashMap(); - - public final Map type2PossibleNot = new HashMap(); - - public final Map type2And = new HashMap(); -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.aird b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.aird new file mode 100644 index 00000000..75ed2fbb --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/fam.aird @@ -0,0 +1,633 @@ + + + + fam.ecore + fam.genmodel + + + + + + + + + + + + + + + + + + + + + + + bold + + + + + + + bold + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bold + + + + bold + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + italic + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + bold + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + italic + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + labelSize + bold + + + labelSize + + + + + + + + + + labelSize + + + labelSize + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bold + + + bold + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index 28ea4798..a2a573fc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -23,6 +23,8 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql index 1c6a545e..7e0db222 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql @@ -25,7 +25,7 @@ pattern type(This : Function, Target : FunctionType) = { find parent(_Child, This); Target == FunctionType::Intermediate; } - +*/ pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { FunctionalArchitectureModel.rootElements(Model, Root); } @@ -33,7 +33,7 @@ pattern rootElements(Model: FunctionalArchitectureModel, Root : Function) = { pattern parent(Func : Function, Par : Function) = { Function.parent(Func, Par); } - +/* @QueryBasedFeature pattern model(This:FunctionalElement, Target: FunctionalArchitectureModel) { FunctionalElement(This); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql deleted file mode 100644 index 307b0f9c..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famSPatterns.vql +++ /dev/null @@ -1,13 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries - -//import epackage "http://www.inf.mit.bme.hu/viatrasolver/example/fam" -import epackage "FamMetamodel" - -@Constraint(message="terminatorAndInformation", severity="error", key={T}) -pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = { - FunctionalOutput.outgoingLinks(Out,I); - FunctionalOutput.terminator(Out,T); -} or { - InformationLink.to(I,In); - FunctionalInput.terminator(In,T); -} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.gitignore index ae3c1726..7d818ce2 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.gitignore +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.gitignore @@ -1 +1,4 @@ /bin/ +/xtend-gen/ +/src-gen/ +/output/* diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp index 3109ccc2..5c3ef527 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp @@ -5,13 +5,13 @@ fof ( enumScope_FunctionType_Intermediate , axiom , ! [ A ] : ( A = eo2 <=> e_In fof ( enumScope_FunctionType_Leaf , axiom , ! [ A ] : ( A = eo3 <=> e_Leaf_FunctionType ( A ) ) ) . fof ( inheritanceHierarchyHandler , axiom , ! [ A ] : ( object ( A ) <=> ( ( t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ~ t_FAMTerminator ( A ) & ( t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . fof ( typeScope_min_object , axiom , ! [ A ] : ( ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = o5 | ( A = o6 | ( A = eo1 | ( A = eo2 | A = eo3 ) ) ) ) ) ) ) ) => object ( A ) ) ) . -fof ( typeScope_max_object , axiom , ! [ A ] : ( object ( A ) => ( A = eo1 | ( A = eo2 | ( A = eo3 | ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = o5 | ( A = o6 | ( A = o7 | A = o8 ) ) ) ) ) ) ) ) ) ) ) ) . +fof ( typeScope_max_object , axiom , ! [ A ] : ( object ( A ) => ( A = eo1 | ( A = eo2 | ( A = eo3 | ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = o5 | ( A = o6 | ( A = o7 | ( A = o8 | ( A = o9 | ( A = o10 | ( A = o11 | ( A = o12 | ( A = o13 | ( A = o14 | ( A = o15 | ( A = o16 | ( A = o17 | ( A = o18 | ( A = o19 | ( A = o20 | ( A = o21 | ( A = o22 | ( A = o23 | ( A = o24 | ( A = o25 | ( A = o26 | ( A = o27 | ( A = o28 | ( A = o29 | ( A = o30 | ( A = o31 | ( A = o32 | ( A = o33 | ( A = o34 | ( A = o35 | ( A = o36 | ( A = o37 | ( A = o38 | ( A = o39 | A = o40 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . fof ( typeScope_min_t_FunctionalInterface , axiom , ! [ A ] : ( ( A = o2 | A = o3 ) => ( t_FunctionalInterface ( A ) & object ( A ) ) ) ) . fof ( typeScope_min_t_Function , axiom , ! [ A ] : ( A = o4 => ( t_Function ( A ) & object ( A ) ) ) ) . fof ( typeScope_min_t_FunctionalOutput , axiom , ! [ A ] : ( ( A = o5 | ( A = o6 | A = o7 ) ) => ( t_FunctionalOutput ( A ) & object ( A ) ) ) ) . -fof ( typeScope_max_t_Function , axiom , ! [ A ] : ( ( t_Function ( A ) & object ( A ) ) => ( A = o4 | A = o8 ) ) ) . +fof ( typeScope_max_t_Function , axiom , ! [ A ] : ( ( t_Function ( A ) & object ( A ) ) => ( A = o4 | ( A = o8 | ( A = o9 | ( A = o10 | A = o11 ) ) ) ) ) ) . fof ( typeScope_max_t_FunctionalOutput , axiom , ! [ A ] : ( ( t_FunctionalOutput ( A ) & object ( A ) ) => ( A = o5 | ( A = o6 | ( A = o7 | A = o8 ) ) ) ) ) . -fof ( typeUniqueness , axiom , eo1 != eo2 & ( eo1 != eo3 & ( eo2 != eo3 & ( eo1 != o1 & ( eo2 != o1 & ( eo3 != o1 & ( eo1 != o2 & ( eo2 != o2 & ( eo3 != o2 & ( o1 != o2 & ( eo1 != o3 & ( eo2 != o3 & ( eo3 != o3 & ( o1 != o3 & ( o2 != o3 & ( eo1 != o4 & ( eo2 != o4 & ( eo3 != o4 & ( o1 != o4 & ( o2 != o4 & ( o3 != o4 & ( eo1 != o5 & ( eo2 != o5 & ( eo3 != o5 & ( o1 != o5 & ( o2 != o5 & ( o3 != o5 & ( o4 != o5 & ( eo1 != o6 & ( eo2 != o6 & ( eo3 != o6 & ( o1 != o6 & ( o2 != o6 & ( o3 != o6 & ( o4 != o6 & ( o5 != o6 & ( eo1 != o7 & ( eo2 != o7 & ( eo3 != o7 & ( o1 != o7 & ( o2 != o7 & ( o3 != o7 & ( o4 != o7 & ( o5 != o7 & ( o6 != o7 & ( eo1 != o8 & ( eo2 != o8 & ( eo3 != o8 & ( o1 != o8 & ( o2 != o8 & ( o3 != o8 & ( o4 != o8 & ( o5 != o8 & ( o6 != o8 & o7 != o8 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . +fof ( typeUniqueness , axiom , eo1 != eo2 & ( eo1 != eo3 & ( eo2 != eo3 & ( eo1 != o1 & ( eo2 != o1 & ( eo3 != o1 & ( eo1 != o2 & ( eo2 != o2 & ( eo3 != o2 & ( o1 != o2 & ( eo1 != o3 & ( eo2 != o3 & ( eo3 != o3 & ( o1 != o3 & ( o2 != o3 & ( eo1 != o4 & ( eo2 != o4 & ( eo3 != o4 & ( o1 != o4 & ( o2 != o4 & ( o3 != o4 & ( eo1 != o5 & ( eo2 != o5 & ( eo3 != o5 & ( o1 != o5 & ( o2 != o5 & ( o3 != o5 & ( o4 != o5 & ( eo1 != o6 & ( eo2 != o6 & ( eo3 != o6 & ( o1 != o6 & ( o2 != o6 & ( o3 != o6 & ( o4 != o6 & ( o5 != o6 & ( eo1 != o7 & ( eo2 != o7 & ( eo3 != o7 & ( o1 != o7 & ( o2 != o7 & ( o3 != o7 & ( o4 != o7 & ( o5 != o7 & ( o6 != o7 & ( eo1 != o8 & ( eo2 != o8 & ( eo3 != o8 & ( o1 != o8 & ( o2 != o8 & ( o3 != o8 & ( o4 != o8 & ( o5 != o8 & ( o6 != o8 & ( o7 != o8 & ( eo1 != o9 & ( eo2 != o9 & ( eo3 != o9 & ( o1 != o9 & ( o2 != o9 & ( o3 != o9 & ( o4 != o9 & ( o5 != o9 & ( o6 != o9 & ( o7 != o9 & ( o8 != o9 & ( eo1 != o10 & ( eo2 != o10 & ( eo3 != o10 & ( o1 != o10 & ( o2 != o10 & ( o3 != o10 & ( o4 != o10 & ( o5 != o10 & ( o6 != o10 & ( o7 != o10 & ( o8 != o10 & ( o9 != o10 & ( eo1 != o11 & ( eo2 != o11 & ( eo3 != o11 & ( o1 != o11 & ( o2 != o11 & ( o3 != o11 & ( o4 != o11 & ( o5 != o11 & ( o6 != o11 & ( o7 != o11 & ( o8 != o11 & ( o9 != o11 & ( o10 != o11 & ( eo1 != o12 & ( eo2 != o12 & ( eo3 != o12 & ( o1 != o12 & ( o2 != o12 & ( o3 != o12 & ( o4 != o12 & ( o5 != o12 & ( o6 != o12 & ( o7 != o12 & ( o8 != o12 & ( o9 != o12 & ( o10 != o12 & ( o11 != o12 & ( eo1 != o13 & ( eo2 != o13 & ( eo3 != o13 & ( o1 != o13 & ( o2 != o13 & ( o3 != o13 & ( o4 != o13 & ( o5 != o13 & ( o6 != o13 & ( o7 != o13 & ( o8 != o13 & ( o9 != o13 & ( o10 != o13 & ( o11 != o13 & ( o12 != o13 & ( eo1 != o14 & ( eo2 != o14 & ( eo3 != o14 & ( o1 != o14 & ( o2 != o14 & ( o3 != o14 & ( o4 != o14 & ( o5 != o14 & ( o6 != o14 & ( o7 != o14 & ( o8 != o14 & ( o9 != o14 & ( o10 != o14 & ( o11 != o14 & ( o12 != o14 & ( o13 != o14 & ( eo1 != o15 & ( eo2 != o15 & ( eo3 != o15 & ( o1 != o15 & ( o2 != o15 & ( o3 != o15 & ( o4 != o15 & ( o5 != o15 & ( o6 != o15 & ( o7 != o15 & ( o8 != o15 & ( o9 != o15 & ( o10 != o15 & ( o11 != o15 & ( o12 != o15 & ( o13 != o15 & ( o14 != o15 & ( eo1 != o16 & ( eo2 != o16 & ( eo3 != o16 & ( o1 != o16 & ( o2 != o16 & ( o3 != o16 & ( o4 != o16 & ( o5 != o16 & ( o6 != o16 & ( o7 != o16 & ( o8 != o16 & ( o9 != o16 & ( o10 != o16 & ( o11 != o16 & ( o12 != o16 & ( o13 != o16 & ( o14 != o16 & ( o15 != o16 & ( eo1 != o17 & ( eo2 != o17 & ( eo3 != o17 & ( o1 != o17 & ( o2 != o17 & ( o3 != o17 & ( o4 != o17 & ( o5 != o17 & ( o6 != o17 & ( o7 != o17 & ( o8 != o17 & ( o9 != o17 & ( o10 != o17 & ( o11 != o17 & ( o12 != o17 & ( o13 != o17 & ( o14 != o17 & ( o15 != o17 & ( o16 != o17 & ( eo1 != o18 & ( eo2 != o18 & ( eo3 != o18 & ( o1 != o18 & ( o2 != o18 & ( o3 != o18 & ( o4 != o18 & ( o5 != o18 & ( o6 != o18 & ( o7 != o18 & ( o8 != o18 & ( o9 != o18 & ( o10 != o18 & ( o11 != o18 & ( o12 != o18 & ( o13 != o18 & ( o14 != o18 & ( o15 != o18 & ( o16 != o18 & ( o17 != o18 & ( eo1 != o19 & ( eo2 != o19 & ( eo3 != o19 & ( o1 != o19 & ( o2 != o19 & ( o3 != o19 & ( o4 != o19 & ( o5 != o19 & ( o6 != o19 & ( o7 != o19 & ( o8 != o19 & ( o9 != o19 & ( o10 != o19 & ( o11 != o19 & ( o12 != o19 & ( o13 != o19 & ( o14 != o19 & ( o15 != o19 & ( o16 != o19 & ( o17 != o19 & ( o18 != o19 & ( eo1 != o20 & ( eo2 != o20 & ( eo3 != o20 & ( o1 != o20 & ( o2 != o20 & ( o3 != o20 & ( o4 != o20 & ( o5 != o20 & ( o6 != o20 & ( o7 != o20 & ( o8 != o20 & ( o9 != o20 & ( o10 != o20 & ( o11 != o20 & ( o12 != o20 & ( o13 != o20 & ( o14 != o20 & ( o15 != o20 & ( o16 != o20 & ( o17 != o20 & ( o18 != o20 & ( o19 != o20 & ( eo1 != o21 & ( eo2 != o21 & ( eo3 != o21 & ( o1 != o21 & ( o2 != o21 & ( o3 != o21 & ( o4 != o21 & ( o5 != o21 & ( o6 != o21 & ( o7 != o21 & ( o8 != o21 & ( o9 != o21 & ( o10 != o21 & ( o11 != o21 & ( o12 != o21 & ( o13 != o21 & ( o14 != o21 & ( o15 != o21 & ( o16 != o21 & ( o17 != o21 & ( o18 != o21 & ( o19 != o21 & ( o20 != o21 & ( eo1 != o22 & ( eo2 != o22 & ( eo3 != o22 & ( o1 != o22 & ( o2 != o22 & ( o3 != o22 & ( o4 != o22 & ( o5 != o22 & ( o6 != o22 & ( o7 != o22 & ( o8 != o22 & ( o9 != o22 & ( o10 != o22 & ( o11 != o22 & ( o12 != o22 & ( o13 != o22 & ( o14 != o22 & ( o15 != o22 & ( o16 != o22 & ( o17 != o22 & ( o18 != o22 & ( o19 != o22 & ( o20 != o22 & ( o21 != o22 & ( eo1 != o23 & ( eo2 != o23 & ( eo3 != o23 & ( o1 != o23 & ( o2 != o23 & ( o3 != o23 & ( o4 != o23 & ( o5 != o23 & ( o6 != o23 & ( o7 != o23 & ( o8 != o23 & ( o9 != o23 & ( o10 != o23 & ( o11 != o23 & ( o12 != o23 & ( o13 != o23 & ( o14 != o23 & ( o15 != o23 & ( o16 != o23 & ( o17 != o23 & ( o18 != o23 & ( o19 != o23 & ( o20 != o23 & ( o21 != o23 & ( o22 != o23 & ( eo1 != o24 & ( eo2 != o24 & ( eo3 != o24 & ( o1 != o24 & ( o2 != o24 & ( o3 != o24 & ( o4 != o24 & ( o5 != o24 & ( o6 != o24 & ( o7 != o24 & ( o8 != o24 & ( o9 != o24 & ( o10 != o24 & ( o11 != o24 & ( o12 != o24 & ( o13 != o24 & ( o14 != o24 & ( o15 != o24 & ( o16 != o24 & ( o17 != o24 & ( o18 != o24 & ( o19 != o24 & ( o20 != o24 & ( o21 != o24 & ( o22 != o24 & ( o23 != o24 & ( eo1 != o25 & ( eo2 != o25 & ( eo3 != o25 & ( o1 != o25 & ( o2 != o25 & ( o3 != o25 & ( o4 != o25 & ( o5 != o25 & ( o6 != o25 & ( o7 != o25 & ( o8 != o25 & ( o9 != o25 & ( o10 != o25 & ( o11 != o25 & ( o12 != o25 & ( o13 != o25 & ( o14 != o25 & ( o15 != o25 & ( o16 != o25 & ( o17 != o25 & ( o18 != o25 & ( o19 != o25 & ( o20 != o25 & ( o21 != o25 & ( o22 != o25 & ( o23 != o25 & ( o24 != o25 & ( eo1 != o26 & ( eo2 != o26 & ( eo3 != o26 & ( o1 != o26 & ( o2 != o26 & ( o3 != o26 & ( o4 != o26 & ( o5 != o26 & ( o6 != o26 & ( o7 != o26 & ( o8 != o26 & ( o9 != o26 & ( o10 != o26 & ( o11 != o26 & ( o12 != o26 & ( o13 != o26 & ( o14 != o26 & ( o15 != o26 & ( o16 != o26 & ( o17 != o26 & ( o18 != o26 & ( o19 != o26 & ( o20 != o26 & ( o21 != o26 & ( o22 != o26 & ( o23 != o26 & ( o24 != o26 & ( o25 != o26 & ( eo1 != o27 & ( eo2 != o27 & ( eo3 != o27 & ( o1 != o27 & ( o2 != o27 & ( o3 != o27 & ( o4 != o27 & ( o5 != o27 & ( o6 != o27 & ( o7 != o27 & ( o8 != o27 & ( o9 != o27 & ( o10 != o27 & ( o11 != o27 & ( o12 != o27 & ( o13 != o27 & ( o14 != o27 & ( o15 != o27 & ( o16 != o27 & ( o17 != o27 & ( o18 != o27 & ( o19 != o27 & ( o20 != o27 & ( o21 != o27 & ( o22 != o27 & ( o23 != o27 & ( o24 != o27 & ( o25 != o27 & ( o26 != o27 & ( eo1 != o28 & ( eo2 != o28 & ( eo3 != o28 & ( o1 != o28 & ( o2 != o28 & ( o3 != o28 & ( o4 != o28 & ( o5 != o28 & ( o6 != o28 & ( o7 != o28 & ( o8 != o28 & ( o9 != o28 & ( o10 != o28 & ( o11 != o28 & ( o12 != o28 & ( o13 != o28 & ( o14 != o28 & ( o15 != o28 & ( o16 != o28 & ( o17 != o28 & ( o18 != o28 & ( o19 != o28 & ( o20 != o28 & ( o21 != o28 & ( o22 != o28 & ( o23 != o28 & ( o24 != o28 & ( o25 != o28 & ( o26 != o28 & ( o27 != o28 & ( eo1 != o29 & ( eo2 != o29 & ( eo3 != o29 & ( o1 != o29 & ( o2 != o29 & ( o3 != o29 & ( o4 != o29 & ( o5 != o29 & ( o6 != o29 & ( o7 != o29 & ( o8 != o29 & ( o9 != o29 & ( o10 != o29 & ( o11 != o29 & ( o12 != o29 & ( o13 != o29 & ( o14 != o29 & ( o15 != o29 & ( o16 != o29 & ( o17 != o29 & ( o18 != o29 & ( o19 != o29 & ( o20 != o29 & ( o21 != o29 & ( o22 != o29 & ( o23 != o29 & ( o24 != o29 & ( o25 != o29 & ( o26 != o29 & ( o27 != o29 & ( o28 != o29 & ( eo1 != o30 & ( eo2 != o30 & ( eo3 != o30 & ( o1 != o30 & ( o2 != o30 & ( o3 != o30 & ( o4 != o30 & ( o5 != o30 & ( o6 != o30 & ( o7 != o30 & ( o8 != o30 & ( o9 != o30 & ( o10 != o30 & ( o11 != o30 & ( o12 != o30 & ( o13 != o30 & ( o14 != o30 & ( o15 != o30 & ( o16 != o30 & ( o17 != o30 & ( o18 != o30 & ( o19 != o30 & ( o20 != o30 & ( o21 != o30 & ( o22 != o30 & ( o23 != o30 & ( o24 != o30 & ( o25 != o30 & ( o26 != o30 & ( o27 != o30 & ( o28 != o30 & ( o29 != o30 & ( eo1 != o31 & ( eo2 != o31 & ( eo3 != o31 & ( o1 != o31 & ( o2 != o31 & ( o3 != o31 & ( o4 != o31 & ( o5 != o31 & ( o6 != o31 & ( o7 != o31 & ( o8 != o31 & ( o9 != o31 & ( o10 != o31 & ( o11 != o31 & ( o12 != o31 & ( o13 != o31 & ( o14 != o31 & ( o15 != o31 & ( o16 != o31 & ( o17 != o31 & ( o18 != o31 & ( o19 != o31 & ( o20 != o31 & ( o21 != o31 & ( o22 != o31 & ( o23 != o31 & ( o24 != o31 & ( o25 != o31 & ( o26 != o31 & ( o27 != o31 & ( o28 != o31 & ( o29 != o31 & ( o30 != o31 & ( eo1 != o32 & ( eo2 != o32 & ( eo3 != o32 & ( o1 != o32 & ( o2 != o32 & ( o3 != o32 & ( o4 != o32 & ( o5 != o32 & ( o6 != o32 & ( o7 != o32 & ( o8 != o32 & ( o9 != o32 & ( o10 != o32 & ( o11 != o32 & ( o12 != o32 & ( o13 != o32 & ( o14 != o32 & ( o15 != o32 & ( o16 != o32 & ( o17 != o32 & ( o18 != o32 & ( o19 != o32 & ( o20 != o32 & ( o21 != o32 & ( o22 != o32 & ( o23 != o32 & ( o24 != o32 & ( o25 != o32 & ( o26 != o32 & ( o27 != o32 & ( o28 != o32 & ( o29 != o32 & ( o30 != o32 & ( o31 != o32 & ( eo1 != o33 & ( eo2 != o33 & ( eo3 != o33 & ( o1 != o33 & ( o2 != o33 & ( o3 != o33 & ( o4 != o33 & ( o5 != o33 & ( o6 != o33 & ( o7 != o33 & ( o8 != o33 & ( o9 != o33 & ( o10 != o33 & ( o11 != o33 & ( o12 != o33 & ( o13 != o33 & ( o14 != o33 & ( o15 != o33 & ( o16 != o33 & ( o17 != o33 & ( o18 != o33 & ( o19 != o33 & ( o20 != o33 & ( o21 != o33 & ( o22 != o33 & ( o23 != o33 & ( o24 != o33 & ( o25 != o33 & ( o26 != o33 & ( o27 != o33 & ( o28 != o33 & ( o29 != o33 & ( o30 != o33 & ( o31 != o33 & ( o32 != o33 & ( eo1 != o34 & ( eo2 != o34 & ( eo3 != o34 & ( o1 != o34 & ( o2 != o34 & ( o3 != o34 & ( o4 != o34 & ( o5 != o34 & ( o6 != o34 & ( o7 != o34 & ( o8 != o34 & ( o9 != o34 & ( o10 != o34 & ( o11 != o34 & ( o12 != o34 & ( o13 != o34 & ( o14 != o34 & ( o15 != o34 & ( o16 != o34 & ( o17 != o34 & ( o18 != o34 & ( o19 != o34 & ( o20 != o34 & ( o21 != o34 & ( o22 != o34 & ( o23 != o34 & ( o24 != o34 & ( o25 != o34 & ( o26 != o34 & ( o27 != o34 & ( o28 != o34 & ( o29 != o34 & ( o30 != o34 & ( o31 != o34 & ( o32 != o34 & ( o33 != o34 & ( eo1 != o35 & ( eo2 != o35 & ( eo3 != o35 & ( o1 != o35 & ( o2 != o35 & ( o3 != o35 & ( o4 != o35 & ( o5 != o35 & ( o6 != o35 & ( o7 != o35 & ( o8 != o35 & ( o9 != o35 & ( o10 != o35 & ( o11 != o35 & ( o12 != o35 & ( o13 != o35 & ( o14 != o35 & ( o15 != o35 & ( o16 != o35 & ( o17 != o35 & ( o18 != o35 & ( o19 != o35 & ( o20 != o35 & ( o21 != o35 & ( o22 != o35 & ( o23 != o35 & ( o24 != o35 & ( o25 != o35 & ( o26 != o35 & ( o27 != o35 & ( o28 != o35 & ( o29 != o35 & ( o30 != o35 & ( o31 != o35 & ( o32 != o35 & ( o33 != o35 & ( o34 != o35 & ( eo1 != o36 & ( eo2 != o36 & ( eo3 != o36 & ( o1 != o36 & ( o2 != o36 & ( o3 != o36 & ( o4 != o36 & ( o5 != o36 & ( o6 != o36 & ( o7 != o36 & ( o8 != o36 & ( o9 != o36 & ( o10 != o36 & ( o11 != o36 & ( o12 != o36 & ( o13 != o36 & ( o14 != o36 & ( o15 != o36 & ( o16 != o36 & ( o17 != o36 & ( o18 != o36 & ( o19 != o36 & ( o20 != o36 & ( o21 != o36 & ( o22 != o36 & ( o23 != o36 & ( o24 != o36 & ( o25 != o36 & ( o26 != o36 & ( o27 != o36 & ( o28 != o36 & ( o29 != o36 & ( o30 != o36 & ( o31 != o36 & ( o32 != o36 & ( o33 != o36 & ( o34 != o36 & ( o35 != o36 & ( eo1 != o37 & ( eo2 != o37 & ( eo3 != o37 & ( o1 != o37 & ( o2 != o37 & ( o3 != o37 & ( o4 != o37 & ( o5 != o37 & ( o6 != o37 & ( o7 != o37 & ( o8 != o37 & ( o9 != o37 & ( o10 != o37 & ( o11 != o37 & ( o12 != o37 & ( o13 != o37 & ( o14 != o37 & ( o15 != o37 & ( o16 != o37 & ( o17 != o37 & ( o18 != o37 & ( o19 != o37 & ( o20 != o37 & ( o21 != o37 & ( o22 != o37 & ( o23 != o37 & ( o24 != o37 & ( o25 != o37 & ( o26 != o37 & ( o27 != o37 & ( o28 != o37 & ( o29 != o37 & ( o30 != o37 & ( o31 != o37 & ( o32 != o37 & ( o33 != o37 & ( o34 != o37 & ( o35 != o37 & ( o36 != o37 & ( eo1 != o38 & ( eo2 != o38 & ( eo3 != o38 & ( o1 != o38 & ( o2 != o38 & ( o3 != o38 & ( o4 != o38 & ( o5 != o38 & ( o6 != o38 & ( o7 != o38 & ( o8 != o38 & ( o9 != o38 & ( o10 != o38 & ( o11 != o38 & ( o12 != o38 & ( o13 != o38 & ( o14 != o38 & ( o15 != o38 & ( o16 != o38 & ( o17 != o38 & ( o18 != o38 & ( o19 != o38 & ( o20 != o38 & ( o21 != o38 & ( o22 != o38 & ( o23 != o38 & ( o24 != o38 & ( o25 != o38 & ( o26 != o38 & ( o27 != o38 & ( o28 != o38 & ( o29 != o38 & ( o30 != o38 & ( o31 != o38 & ( o32 != o38 & ( o33 != o38 & ( o34 != o38 & ( o35 != o38 & ( o36 != o38 & ( o37 != o38 & ( eo1 != o39 & ( eo2 != o39 & ( eo3 != o39 & ( o1 != o39 & ( o2 != o39 & ( o3 != o39 & ( o4 != o39 & ( o5 != o39 & ( o6 != o39 & ( o7 != o39 & ( o8 != o39 & ( o9 != o39 & ( o10 != o39 & ( o11 != o39 & ( o12 != o39 & ( o13 != o39 & ( o14 != o39 & ( o15 != o39 & ( o16 != o39 & ( o17 != o39 & ( o18 != o39 & ( o19 != o39 & ( o20 != o39 & ( o21 != o39 & ( o22 != o39 & ( o23 != o39 & ( o24 != o39 & ( o25 != o39 & ( o26 != o39 & ( o27 != o39 & ( o28 != o39 & ( o29 != o39 & ( o30 != o39 & ( o31 != o39 & ( o32 != o39 & ( o33 != o39 & ( o34 != o39 & ( o35 != o39 & ( o36 != o39 & ( o37 != o39 & ( o38 != o39 & ( eo1 != o40 & ( eo2 != o40 & ( eo3 != o40 & ( o1 != o40 & ( o2 != o40 & ( o3 != o40 & ( o4 != o40 & ( o5 != o40 & ( o6 != o40 & ( o7 != o40 & ( o8 != o40 & ( o9 != o40 & ( o10 != o40 & ( o11 != o40 & ( o12 != o40 & ( o13 != o40 & ( o14 != o40 & ( o15 != o40 & ( o16 != o40 & ( o17 != o40 & ( o18 != o40 & ( o19 != o40 & ( o20 != o40 & ( o21 != o40 & ( o22 != o40 & ( o23 != o40 & ( o24 != o40 & ( o25 != o40 & ( o26 != o40 & ( o27 != o40 & ( o28 != o40 & ( o29 != o40 & ( o30 != o40 & ( o31 != o40 & ( o32 != o40 & ( o33 != o40 & ( o34 != o40 & ( o35 != o40 & ( o36 != o40 & ( o37 != o40 & ( o38 != o40 & o39 != o40 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . fof ( compliance_interface_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_interface_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalInterface ( V_1 ) ) ) ) . fof ( compliance_model_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_model_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalArchitectureModel ( V_1 ) ) ) ) . fof ( compliance_parent_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_parent_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_Function ( V_1 ) ) ) ) . @@ -28,12 +28,16 @@ fof ( compliance_terminator_FunctionalData , axiom , ! [ V_0 , V_1 ] : ( r_termi fof ( compliance_interface_FunctionalData , axiom , ! [ V_0 , V_1 ] : ( r_interface_FunctionalData ( V_0 , V_1 ) => ( t_FunctionalData ( V_0 ) & t_FunctionalInterface ( V_1 ) ) ) ) . fof ( compliance_type_Function , axiom , ! [ V_0 , V_1 ] : ( r_type_Function ( V_0 , V_1 ) => ( t_Function ( V_0 ) & t_FunctionType ( V_1 ) ) ) ) . fof ( containment_topLevel_t_FunctionalArchitectureModel , axiom , ! [ A ] : ( t_FunctionalArchitectureModel ( A ) <=> A = o1 ) ) . -fof ( containment_r_interface_FunctionalElement , axiom , ! [ A ] : ( t_FunctionalInterface ( A ) => ? [ B ] : ( t_FunctionalElement ( B ) & r_interface_FunctionalElement ( B , A ) ) ) ) . -fof ( containment_r_rootElements_FunctionalArchitectureModel , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : ( t_FunctionalArchitectureModel ( B ) & r_rootElements_FunctionalArchitectureModel ( B , A ) ) ) ) . -fof ( containment_r_subElements_Function , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : ( t_Function ( B ) & r_subElements_Function ( B , A ) ) ) ) . -fof ( containment_r_data_FunctionalInterface , axiom , ! [ A ] : ( t_FunctionalData ( A ) => ? [ B ] : ( t_FunctionalInterface ( B ) & r_data_FunctionalInterface ( B , A ) ) ) ) . -fof ( containment_r_outgoingLinks_FunctionalOutput , axiom , ! [ A ] : ( t_InformationLink ( A ) => ? [ B ] : ( t_FunctionalOutput ( B ) & r_outgoingLinks_FunctionalOutput ( B , A ) ) ) ) . -fof ( containment_r_terminator_FunctionalData , axiom , ! [ A ] : ( t_FAMTerminator ( A ) => ? [ B ] : ( t_FunctionalData ( B ) & r_terminator_FunctionalData ( B , A ) ) ) ) . + + +fof ( containment_r_interface_FunctionalElement , axiom , ! [ A ] : ( t_FunctionalInterface ( A ) => ? [ B ] : r_interface_FunctionalElement ( B , A ) ) ) . +fof ( containment_r_rootElements_FunctionalArchitectureModel , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : r_rootElements_FunctionalArchitectureModel ( B , A ) ) ) . +fof ( containment_r_subElements_Function , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : r_subElements_Function ( B , A ) ) ) . +fof ( containment_r_data_FunctionalInterface , axiom , ! [ A ] : ( t_FunctionalData ( A ) => ? [ B ] : r_data_FunctionalInterface ( B , A ) ) ) . +fof ( containment_r_outgoingLinks_FunctionalOutput , axiom , ! [ A ] : ( t_InformationLink ( A ) => ? [ B ] : r_outgoingLinks_FunctionalOutput ( B , A ) ) ) . +fof ( containment_r_terminator_FunctionalData , axiom , ! [ A ] : ( t_FAMTerminator ( A ) => ? [ B ] : r_terminator_FunctionalData ( B , A ) ) ) . + + fof ( upperMultiplicity_interface_FunctionalElement , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalElement ( V_src ) & ( t_FunctionalInterface ( V_trg_1 ) & t_FunctionalInterface ( V_trg_2 ) ) ) => ( ( r_interface_FunctionalElement ( V_src , V_trg_1 ) & r_interface_FunctionalElement ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . fof ( lowerMultiplicity_model_FunctionalElement , axiom , ! [ V_src ] : ( t_FunctionalElement ( V_src ) => ? [ V_trg_1 ] : ( t_FunctionalArchitectureModel ( V_trg_1 ) & r_model_FunctionalElement ( V_src , V_trg_1 ) ) ) ) . fof ( upperMultiplicity_model_FunctionalElement , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalElement ( V_src ) & ( t_FunctionalArchitectureModel ( V_trg_1 ) & t_FunctionalArchitectureModel ( V_trg_2 ) ) ) => ( ( r_model_FunctionalElement ( V_src , V_trg_1 ) & r_model_FunctionalElement ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/VampireTest/vampireProblem.tptp b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/VampireTest/vampireProblem.tptp deleted file mode 100644 index 4c368859..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/VampireTest/vampireProblem.tptp +++ /dev/null @@ -1,7 +0,0 @@ -% This is an initial Test Comment -fof ( typeDef_oldRPS , axiom , ! [ A ] : ( t_oldRPS ( A ) <=> ( e_Rock_oldRPS ( A ) | ( e_Paper_oldRPS ( A ) | e_Scissor_oldRPS ( A ) ) ) ) ) . -fof ( hierarchyHandler , axiom , ! [ A ] : ( object ( A ) <=> t_oldRPS ( A ) ) ) . -fof ( typeScope , axiom , ! [ A ] : ( object ( A ) <=> ( A = o1 | ( A = o2 | ( A = o3 | A = o4 ) ) ) ) ) . -fof ( typeUniqueness , axiom , o1 != o2 & ( o1 != o3 & ( o2 != o3 & ( o1 != o4 & ( o2 != o4 & o3 != o4 ) ) ) ) ) . -fof ( compliance_beats2 , axiom , ! [ Var_0 , Var_1 ] : ( rel_beats2 ( Var_0 , Var_1 ) => ( t_oldRPS ( Var_0 ) & t_oldRPS ( Var_1 ) ) ) ) . -fof ( assertion1 , axiom , ! [ Var_x ] : ( t_oldRPS ( Var_x ) => ? [ Var_y ] : ( t_oldRPS ( Var_y ) & ( rel_beats2 ( Var_x , Var_y ) & ( Var_x != Var_y & ~ rel_beats2 ( Var_y , Var_x ) ) ) ) ) ) . diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend index 86c9092a..1559ee3f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend @@ -4,11 +4,11 @@ import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguageFactory import functionalarchitecture.Function +import functionalarchitecture.FunctionalInterface +import functionalarchitecture.FunctionalOutput import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor -import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult @@ -30,8 +30,7 @@ import org.eclipse.emf.ecore.EReference import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl import org.eclipse.viatra.query.runtime.api.IQueryGroup -import org.eclipse.emf.ecore.EClassifier -import functionalarchitecture.FunctionalOutput +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel class GeneralTest { def static String createAndSolveProblem(EcoreMetamodelDescriptor metamodel, List partialModel, @@ -67,7 +66,7 @@ class GeneralTest { list2MapMin.get(Function.simpleName) ), 1) typeMapMin.put(ecore2Logic.TypeofEClass(modelGenerationProblem.trace, - list2MapMin.get(functionalarchitecture.FunctionalInterface.simpleName) + list2MapMin.get(FunctionalInterface.simpleName) ), 2) typeMapMin.put(ecore2Logic.TypeofEClass(modelGenerationProblem.trace, list2MapMin.get(FunctionalOutput.simpleName) @@ -80,7 +79,7 @@ class GeneralTest { ), 5) typeMapMax.put(ecore2Logic.TypeofEClass( modelGenerationProblem.trace, - list2MapMax.get(functionalarchitecture.FunctionalInterface.simpleName) + list2MapMax.get(FunctionalInterface.simpleName) ), 2) typeMapMax.put(ecore2Logic.TypeofEClass( modelGenerationProblem.trace, @@ -92,7 +91,7 @@ class GeneralTest { // add configuration things, in config file first it.documentationLevel = DocumentationLevel::FULL it.typeScopes.minNewElements = 6 - it.typeScopes.maxNewElements = 8 + it.typeScopes.maxNewElements = 40 it.typeScopes.minNewElementsByType = typeMapMin it.typeScopes.maxNewElementsByType = typeMapMax ] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icseTests/FAMTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icseTests/FAMTest.xtend deleted file mode 100644 index a8b4dcfb..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icseTests/FAMTest.xtend +++ /dev/null @@ -1,103 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.vampire.test - -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration -import functionalarchitecture.FunctionalarchitecturePackage -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration -import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult -import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace -import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace -import java.util.List -import org.eclipse.emf.ecore.EAttribute -import org.eclipse.emf.ecore.EClass -import org.eclipse.emf.ecore.EEnum -import org.eclipse.emf.ecore.EEnumLiteral -import org.eclipse.emf.ecore.EObject -import org.eclipse.emf.ecore.EReference -import org.eclipse.emf.ecore.resource.Resource -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl - -class DslTest { - def static void main(String[] args) { - val inputs = new FileSystemWorkspace('''initialModels/''', "") - val workspace = new FileSystemWorkspace('''outputDslModels/''', "") - workspace.initAndClear - - println("Input and output workspaces are created") - - val metamodel = loadMetamodel() - val partialModel = loadPartialModel(inputs) -// val queries = loadQueries(metamodel) - - println("DSL loaded") - - val Ecore2Logic ecore2Logic = new Ecore2Logic - val Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic) - val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) - val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic - - val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel,new Ecore2LogicConfiguration()) -// val modelExtensionProblem = instanceModel2Logic.transform(modelGenerationProblem,partialModel) -// val validModelExtensionProblem = viatra2Logic.transformQueries(queries,modelGenerationProblem,new Viatra2LogicConfiguration) - - val logicProblem = modelGenerationProblem.output -// val logicProblem = modelExtensionProblem.output -// val logicProblem = validModelExtensionProblem.output - - - println("Problem created") - - var LogicResult solution - var LogicReasoner reasoner - //* - reasoner = new VampireSolver - val vampireConfig = new VampireSolverConfiguration => [ - //add configuration things, in config file first - it.writeToFile = false - ] - - solution = reasoner.solve(logicProblem, vampireConfig, workspace) - - println("Problem solved") - - - } - - def private static loadMetamodel() { - //FAM - val pckg = FunctionalarchitecturePackage.eINSTANCE - val List classes = pckg.EClassifiers.filter(EClass).toList - val List enums = pckg.EClassifiers.filter(EEnum).toList - val List literals = enums.map[getELiterals].flatten.toList - val List references = classes.map[getEReferences].flatten.toList - val List attributes = classes.map[getEAttributes].flatten.toList - return new EcoreMetamodelDescriptor(classes,#{},false,enums,literals,references,attributes) - } - - def private static loadPartialModel(ReasonerWorkspace inputs) { - Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("*", new XMIResourceFactoryImpl()); - inputs.readModel(EObject,"FunctionalArchitectureModel.xmi").eResource.allContents.toList -// inputs.readModel(EObject,"FAM.xmi").eResource.allContents.toList - } - -// def private static loadQueries(EcoreMetamodelDescriptor metamodel) { -// val i = hu.bme.mit.inf.dslreasoner.domains.transima.fam.patterns.Pattern.instance -// val patterns = i.specifications.toList -// val wfPatterns = patterns.filter[it.allAnnotations.exists[it.name== "Constraint"]].toSet -// val derivedFeatures = new LinkedHashMap -// derivedFeatures.put(i.type,metamodel.attributes.filter[it.name == "type"].head) -// derivedFeatures.put(i.model,metamodel.references.filter[it.name == "model"].head) -// val res = new ViatraQuerySetDescriptor( -// patterns, -// wfPatterns, -// derivedFeatures -// ) -// return res -// } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 57fe8c2d..99a457d4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 41284af1..e8451eb9 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index 36f2c6e1..73c6ab49 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index ce6042ea..b6cabaa6 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 270ac043..ae6fb160 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java index 13a0e74a..80cec4b9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java @@ -108,7 +108,7 @@ public class GeneralTest { final Procedure1 _function_2 = (VampireSolverConfiguration it) -> { it.documentationLevel = DocumentationLevel.FULL; it.typeScopes.minNewElements = 6; - it.typeScopes.maxNewElements = 8; + it.typeScopes.maxNewElements = 40; it.typeScopes.minNewElementsByType = typeMapMin; it.typeScopes.maxNewElementsByType = typeMapMax; }; diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icseTest/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icseTest/.gitignore deleted file mode 100644 index f3e21798..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icseTest/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/.FAMTest.java._trace diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.DslTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.DslTest.xtendbin deleted file mode 100644 index 59f57d8b..00000000 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.DslTest.xtendbin and /dev/null differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 693ee01d..6cae3219 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 7e61c0ef..22dda149 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 8a554a42..857ee2e7 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/FAMTest.java deleted file mode 100644 index 7b4849e1..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/FAMTest.java +++ /dev/null @@ -1,111 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.vampire.test; - -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; -import com.google.common.collect.Iterables; -import functionalarchitecture.FunctionalarchitecturePackage; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; -import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; -import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; -import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; -import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace; -import java.util.Collections; -import java.util.List; -import java.util.Map; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EEnumLiteral; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.xtend2.lib.StringConcatenation; -import org.eclipse.xtext.xbase.lib.CollectionLiterals; -import org.eclipse.xtext.xbase.lib.Exceptions; -import org.eclipse.xtext.xbase.lib.Functions.Function1; -import org.eclipse.xtext.xbase.lib.InputOutput; -import org.eclipse.xtext.xbase.lib.IterableExtensions; -import org.eclipse.xtext.xbase.lib.IteratorExtensions; -import org.eclipse.xtext.xbase.lib.ListExtensions; -import org.eclipse.xtext.xbase.lib.ObjectExtensions; -import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; - -@SuppressWarnings("all") -public class DslTest { - public static void main(final String[] args) { - try { - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("outputDslModels/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = DslTest.loadMetamodel(); - final List partialModel = DslTest.loadPartialModel(inputs); - InputOutput.println("DSL loaded"); - final Ecore2Logic ecore2Logic = new Ecore2Logic(); - final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); - final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); - final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); - Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); - final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); - final LogicProblem logicProblem = modelGenerationProblem.getOutput(); - InputOutput.println("Problem created"); - LogicResult solution = null; - LogicReasoner reasoner = null; - VampireSolver _vampireSolver = new VampireSolver(); - reasoner = _vampireSolver; - VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); - final Procedure1 _function = (VampireSolverConfiguration it) -> { - it.writeToFile = false; - }; - final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); - solution = reasoner.solve(logicProblem, vampireConfig, workspace); - InputOutput.println("Problem solved"); - } catch (Throwable _e) { - throw Exceptions.sneakyThrow(_e); - } - } - - private static EcoreMetamodelDescriptor loadMetamodel() { - final FunctionalarchitecturePackage pckg = FunctionalarchitecturePackage.eINSTANCE; - final List classes = IterableExtensions.toList(Iterables.filter(pckg.getEClassifiers(), EClass.class)); - final List enums = IterableExtensions.toList(Iterables.filter(pckg.getEClassifiers(), EEnum.class)); - final Function1> _function = (EEnum it) -> { - return it.getELiterals(); - }; - final List literals = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(enums, _function))); - final Function1> _function_1 = (EClass it) -> { - return it.getEReferences(); - }; - final List references = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(classes, _function_1))); - final Function1> _function_2 = (EClass it) -> { - return it.getEAttributes(); - }; - final List attributes = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(classes, _function_2))); - return new EcoreMetamodelDescriptor(classes, Collections.unmodifiableSet(CollectionLiterals.newHashSet()), false, enums, literals, references, attributes); - } - - private static List loadPartialModel(final ReasonerWorkspace inputs) { - List _xblockexpression = null; - { - Map _extensionToFactoryMap = Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - _extensionToFactoryMap.put("*", _xMIResourceFactoryImpl); - _xblockexpression = IteratorExtensions.toList(inputs.readModel(EObject.class, "FunctionalArchitectureModel.xmi").eResource().getAllContents()); - } - return _xblockexpression; - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/hu/bme/mit/inf/dslreasoner/run/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/hu/bme/mit/inf/dslreasoner/run/.gitignore deleted file mode 100644 index 2c8a0d43..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/hu/bme/mit/inf/dslreasoner/run/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/.SimpleRun.java._trace -/.MedicalSystem.java._trace diff --git a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/.classpath b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/.classpath index 1c96fe2f..2b46fc9b 100644 --- a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/.classpath +++ b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/.classpath @@ -4,5 +4,6 @@ + diff --git a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/META-INF/MANIFEST.MF b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/META-INF/MANIFEST.MF index 4e3222f9..d32b92ce 100644 --- a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/META-INF/MANIFEST.MF +++ b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/META-INF/MANIFEST.MF @@ -1,15 +1,14 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: FAMTest -Bundle-SymbolicName: hu.bme.mit.inf.dslreasoner.application.FAMTest;singleton:=true -Bundle-Version: 1.0.0.qualifier -Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.application.FAMTest -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 -Require-Bundle: com.google.guava, - org.eclipse.xtext.xbase.lib, - org.eclipse.xtend.lib, - org.eclipse.xtend.lib.macro, - hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0", - org.junit;bundle-version="4.12.0", - org.eclipse.collections;bundle-version="7.1.1" - +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: FAMTest +Bundle-SymbolicName: hu.bme.mit.inf.dslreasoner.application.FAMTest;singleton:=true +Bundle-Version: 1.0.0.qualifier +Require-Bundle: com.google.guava, + org.eclipse.xtext.xbase.lib, + org.eclipse.xtend.lib, + org.eclipse.xtend.lib.macro, + hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0", + org.junit;bundle-version="4.12.0", + org.eclipse.collections;bundle-version="7.1.1" +Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.application.FAMTest +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 diff --git a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/build.properties b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/build.properties index 41eb6ade..aed85a48 100644 --- a/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/build.properties +++ b/Tests/hu.bme.mit.inf.dslreasoner.application.FAMTest/build.properties @@ -1,4 +1,5 @@ -source.. = src/ -output.. = bin/ bin.includes = META-INF/,\ . +source.. = src/,\ + src-gen/ +output.. = bin/ -- cgit v1.2.3-54-g00ecf From 77f583cd433f3ed0fed3a1f240c0677e41cb4d31 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Thu, 11 Apr 2019 16:59:48 -0400 Subject: VAMPIRE: #39 Reorganise tests, working yakindu test, need debugging --- .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1701 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2526 -> 2526 bytes .../plugin.xml | 29 - .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 5892 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18157 -> 18156 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4215 -> 4215 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 10551 -> 10551 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 8209 -> 8209 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 9839 -> 9839 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13092 -> 13093 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 10705 -> 10705 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 4908 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../metamodels/filesystem.ecore | 2 +- .../metamodels/yakindu.aird | 675 +++++++++++++++ .../plugin.xml | 104 --- .../standalone/test/yakindu/queries/Child.java | 721 ---------------- .../test/yakindu/queries/ChoiceHasNoIncoming.java | 551 ------------- .../test/yakindu/queries/ChoiceHasNoOutgoing.java | 559 ------------- .../test/yakindu/queries/EntryInRegion.java | 702 ---------------- .../queries/HasMultipleIncomingTrainsition.java | 549 ------------- .../queries/HasMultipleOutgoingTrainsition.java | 549 ------------- .../test/yakindu/queries/HasMultipleRegions.java | 555 ------------- .../test/yakindu/queries/IncomingToEntry.java | 703 ---------------- .../queries/MultipleTransitionFromEntry.java | 827 ------------------- .../test/yakindu/queries/NoEntryInRegion.java | 550 ------------- .../queries/NoOutgoingTransitionFromEntry.java | 551 ------------- .../test/yakindu/queries/NoStateInRegion.java | 558 ------------- .../yakindu/queries/NotSynchronizingStates.java | 554 ------------- .../test/yakindu/queries/OutgoingFromExit.java | 715 ---------------- .../test/yakindu/queries/OutgoingFromFinal.java | 715 ---------------- .../test/yakindu/queries/StateInRegion.java | 694 ---------------- .../test/yakindu/queries/SynchHasNoIncoming.java | 551 ------------- .../test/yakindu/queries/SynchHasNoOutgoing.java | 559 ------------- .../test/yakindu/queries/SynchThree.java | 639 --------------- .../queries/SynchronizedIncomingInSameRegion.java | 888 -------------------- ...nchronizedRegionDoesNotHaveMultipleRegions.java | 744 ----------------- .../queries/SynchronizedRegionsAreNotSiblings.java | 902 --------------------- .../test/yakindu/queries/Transition.java | 808 ------------------ .../standalone/test/yakindu/queries/TwoSynch.java | 714 ---------------- .../META-INF/MANIFEST.MF | 3 +- .../output/FAMTest/Fam.logicproblem | 2 +- .../output/FAMTest/vampireProblem.tptp | 50 +- .../plugin.xml | 10 + .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 97 ++- .../dslreasoner/vampire/icse/FileSystemTest.xtend | 99 ++- .../dslreasoner/vampire/icse/GeneralTest.xtend | 117 +-- .../dslreasoner/vampire/icse/YakinduTest.xtend | 98 ++- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 6358 -> 6358 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 4068 -> 6825 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 4115 -> 6088 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 8623 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 4054 -> 6042 bytes .../ecse/dslreasoner/vampire/icse/FAMTest.java | 107 ++- .../dslreasoner/vampire/icse/FileSystemTest.java | 102 ++- .../ecse/dslreasoner/vampire/icse/GeneralTest.java | 107 +-- .../ecse/dslreasoner/vampire/icse/YakinduTest.java | 99 ++- .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes 78 files changed, 1243 insertions(+), 16316 deletions(-) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index 847f3da5..d6392a0b 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index 7d5c3fb3..c97efa0f 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml index 8069f168..9ace526f 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml @@ -3,35 +3,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index d2b35248..024dcab9 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index f42023dc..7e128ad1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 6a306754..0bf8ccc6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index 48a792a0..58a18bbb 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 0e052102..205afcc4 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 4865470e..b388bd43 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 3c9c2bbf..3092be97 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index d38b36ff..8b23f34d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 0886858b..84682c47 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index fb078be1..e3f67a0c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index 7febb8b9..bf354098 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index a790245e..da62f4c1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index 19d74808..482b884e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index ab5c8cfa..81c1f803 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index 7394b24e..43e1e477 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index d328dcf2..4e6f6ca0 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 968a2df8..707a6089 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 346daf52..3171324f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 48756fcc..301df7fa 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 44b06208..5e53ea26 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 4cab8309..b378ed09 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index ccddb430..605ac88c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index a069a62f..0c289e29 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index 46cd58fb..cb72fd90 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index 8725e6b1..cfe1e8cd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 1b5e4d0b..c2079147 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index ca749be9..3c70bc14 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 1c910cc9..9ef20b23 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore index 8952cfb5..bbd4af35 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore @@ -10,7 +10,7 @@ -
+
diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird new file mode 100644 index 00000000..ef3746fa --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird @@ -0,0 +1,675 @@ + + + + yakindu.ecore + yakindu.genmodel + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + italic + + + + + + + + + italic + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + italic + + + + + + + + + italic + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + labelSize + + + labelSize + + + + + + + + + + labelSize + + + labelSize + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index a2a573fc..f9d517b9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -27,110 +27,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java deleted file mode 100644 index 9867c1ee..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Child.java +++ /dev/null @@ -1,721 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         ///////////////////////////////
- *         // Extra
- *         //
- *         //{@literal @}Constraint(severity="error", message="error", key = {s})
- *         //pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) {
- *         //	find transition(_, v, s);
- *         //	neg find child(_,v);
- *         //} or {
- *         //	find transition(_, s, v);
- *         //	neg find child(_,v);
- *         //}
- *         
- *         pattern child(parent: CompositeElement, child: Vertex) {
- *         	CompositeElement.regions.vertices(parent, child);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class Child extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private CompositeElement fParent; - - private Vertex fChild; - - private static List parameterNames = makeImmutableList("parent", "child"); - - private Match(final CompositeElement pParent, final Vertex pChild) { - this.fParent = pParent; - this.fChild = pChild; - } - - @Override - public Object get(final String parameterName) { - if ("parent".equals(parameterName)) return this.fParent; - if ("child".equals(parameterName)) return this.fChild; - return null; - } - - public CompositeElement getParent() { - return this.fParent; - } - - public Vertex getChild() { - return this.fChild; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("parent".equals(parameterName) ) { - this.fParent = (CompositeElement) newValue; - return true; - } - if ("child".equals(parameterName) ) { - this.fChild = (Vertex) newValue; - return true; - } - return false; - } - - public void setParent(final CompositeElement pParent) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fParent = pParent; - } - - public void setChild(final Vertex pChild) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fChild = pChild; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child"; - } - - @Override - public List parameterNames() { - return Child.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fParent, fChild}; - } - - @Override - public Child.Match toImmutable() { - return isMutable() ? newMatch(fParent, fChild) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"parent\"=" + prettyPrintValue(fParent) + ", "); - result.append("\"child\"=" + prettyPrintValue(fChild)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fParent, fChild); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof Child.Match)) { - Child.Match other = (Child.Match) obj; - return Objects.equals(fParent, other.fParent) && Objects.equals(fChild, other.fChild); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public Child specification() { - return Child.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static Child.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static Child.Match newMutableMatch(final CompositeElement pParent, final Vertex pChild) { - return new Mutable(pParent, pChild); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return the (partial) match object. - * - */ - public static Child.Match newMatch(final CompositeElement pParent, final Vertex pChild) { - return new Immutable(pParent, pChild); - } - - private static final class Mutable extends Child.Match { - Mutable(final CompositeElement pParent, final Vertex pChild) { - super(pParent, pChild); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends Child.Match { - Immutable(final CompositeElement pParent, final Vertex pChild) { - super(pParent, pChild); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * ///////////////////////////////
-   * // Extra
-   * //
-   * //{@literal @}Constraint(severity="error", message="error", key = {s})
-   * //pattern SynchronizedRegionDoesNotHaveParent(s : Synchronization, v : Vertex) {
-   * //	find transition(_, v, s);
-   * //	neg find child(_,v);
-   * //} or {
-   * //	find transition(_, s, v);
-   * //	neg find child(_,v);
-   * //}
-   * 
-   * pattern child(parent: CompositeElement, child: Vertex) {
-   * 	CompositeElement.regions.vertices(parent, child);
-   * }
-   * 
- * - * @see Match - * @see Child - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static Child.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static Child.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_PARENT = 0; - - private final static int POSITION_CHILD = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Child.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final CompositeElement pParent, final Vertex pChild) { - return rawStreamAllMatches(new Object[]{pParent, pChild}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final CompositeElement pParent, final Vertex pChild) { - return rawStreamAllMatches(new Object[]{pParent, pChild}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final CompositeElement pParent, final Vertex pChild) { - return rawGetOneArbitraryMatch(new Object[]{pParent, pChild}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final CompositeElement pParent, final Vertex pChild) { - return rawHasMatch(new Object[]{pParent, pChild}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final CompositeElement pParent, final Vertex pChild) { - return rawCountMatches(new Object[]{pParent, pChild}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final CompositeElement pParent, final Vertex pChild, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pParent, pChild}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pParent the fixed value of pattern parameter parent, or null if not bound. - * @param pChild the fixed value of pattern parameter child, or null if not bound. - * @return the (partial) match object. - * - */ - public Child.Match newMatch(final CompositeElement pParent, final Vertex pChild) { - return Child.Match.newMatch(pParent, pChild); - } - - /** - * Retrieve the set of values that occur in matches for parent. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfparent(final Object[] parameters) { - return rawStreamAllValues(POSITION_PARENT, parameters).map(CompositeElement.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for parent. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfparent() { - return rawStreamAllValuesOfparent(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for parent. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfparent() { - return rawStreamAllValuesOfparent(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for parent. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfparent(final Child.Match partialMatch) { - return rawStreamAllValuesOfparent(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for parent. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfparent(final Vertex pChild) { - return rawStreamAllValuesOfparent(new Object[]{null, pChild}); - } - - /** - * Retrieve the set of values that occur in matches for parent. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfparent(final Child.Match partialMatch) { - return rawStreamAllValuesOfparent(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for parent. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfparent(final Vertex pChild) { - return rawStreamAllValuesOfparent(new Object[]{null, pChild}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for child. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfchild(final Object[] parameters) { - return rawStreamAllValues(POSITION_CHILD, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for child. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfchild() { - return rawStreamAllValuesOfchild(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for child. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfchild() { - return rawStreamAllValuesOfchild(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for child. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfchild(final Child.Match partialMatch) { - return rawStreamAllValuesOfchild(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for child. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfchild(final CompositeElement pParent) { - return rawStreamAllValuesOfchild(new Object[]{pParent, null}); - } - - /** - * Retrieve the set of values that occur in matches for child. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfchild(final Child.Match partialMatch) { - return rawStreamAllValuesOfchild(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for child. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfchild(final CompositeElement pParent) { - return rawStreamAllValuesOfchild(new Object[]{pParent, null}).collect(Collectors.toSet()); - } - - @Override - protected Child.Match tupleToMatch(final Tuple t) { - try { - return Child.Match.newMatch((CompositeElement) t.get(POSITION_PARENT), (Vertex) t.get(POSITION_CHILD)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected Child.Match arrayToMatch(final Object[] match) { - try { - return Child.Match.newMatch((CompositeElement) match[POSITION_PARENT], (Vertex) match[POSITION_CHILD]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected Child.Match arrayToMatchMutable(final Object[] match) { - try { - return Child.Match.newMutableMatch((CompositeElement) match[POSITION_PARENT], (Vertex) match[POSITION_CHILD]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return Child.instance(); - } - } - - private Child() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static Child instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected Child.Matcher instantiate(final ViatraQueryEngine engine) { - return Child.Matcher.on(engine); - } - - @Override - public Child.Matcher instantiate() { - return Child.Matcher.create(); - } - - @Override - public Child.Match newEmptyMatch() { - return Child.Match.newEmptyMatch(); - } - - @Override - public Child.Match newMatch(final Object... parameters) { - return Child.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child (visibility: PUBLIC, simpleName: Child, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child (visibility: PUBLIC, simpleName: Child, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static Child INSTANCE = new Child(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static Child.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_parent = new PParameter("parent", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "CompositeElement")), PParameterDirection.INOUT); - - private final PParameter parameter_child = new PParameter("child", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_parent, parameter_child); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.child"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("parent","child"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_parent = body.getOrCreateVariableByName("parent"); - PVariable var_child = body.getOrCreateVariableByName("child"); - new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_child), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_parent, parameter_parent), - new ExportedParameter(body, var_child, parameter_child) - )); - // CompositeElement.regions.vertices(parent, child) - new TypeConstraint(body, Tuples.flatTupleOf(var_parent), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_parent, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_child); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java deleted file mode 100644 index 8e62ee9d..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoIncoming.java +++ /dev/null @@ -1,551 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {c})
- *         pattern choiceHasNoIncoming(c: Choice) {
- *         	neg find transition(_, _, c);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class ChoiceHasNoIncoming extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Choice fC; - - private static List parameterNames = makeImmutableList("c"); - - private Match(final Choice pC) { - this.fC = pC; - } - - @Override - public Object get(final String parameterName) { - if ("c".equals(parameterName)) return this.fC; - return null; - } - - public Choice getC() { - return this.fC; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("c".equals(parameterName) ) { - this.fC = (Choice) newValue; - return true; - } - return false; - } - - public void setC(final Choice pC) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fC = pC; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming"; - } - - @Override - public List parameterNames() { - return ChoiceHasNoIncoming.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fC}; - } - - @Override - public ChoiceHasNoIncoming.Match toImmutable() { - return isMutable() ? newMatch(fC) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"c\"=" + prettyPrintValue(fC)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fC); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof ChoiceHasNoIncoming.Match)) { - ChoiceHasNoIncoming.Match other = (ChoiceHasNoIncoming.Match) obj; - return Objects.equals(fC, other.fC); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public ChoiceHasNoIncoming specification() { - return ChoiceHasNoIncoming.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static ChoiceHasNoIncoming.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static ChoiceHasNoIncoming.Match newMutableMatch(final Choice pC) { - return new Mutable(pC); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the (partial) match object. - * - */ - public static ChoiceHasNoIncoming.Match newMatch(final Choice pC) { - return new Immutable(pC); - } - - private static final class Mutable extends ChoiceHasNoIncoming.Match { - Mutable(final Choice pC) { - super(pC); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends ChoiceHasNoIncoming.Match { - Immutable(final Choice pC) { - super(pC); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {c})
-   * pattern choiceHasNoIncoming(c: Choice) {
-   * 	neg find transition(_, _, c);
-   * }
-   * 
- * - * @see Match - * @see ChoiceHasNoIncoming - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static ChoiceHasNoIncoming.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static ChoiceHasNoIncoming.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_C = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(ChoiceHasNoIncoming.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Choice pC) { - return rawStreamAllMatches(new Object[]{pC}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Choice pC) { - return rawStreamAllMatches(new Object[]{pC}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Choice pC) { - return rawGetOneArbitraryMatch(new Object[]{pC}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Choice pC) { - return rawHasMatch(new Object[]{pC}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Choice pC) { - return rawCountMatches(new Object[]{pC}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Choice pC, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pC}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the (partial) match object. - * - */ - public ChoiceHasNoIncoming.Match newMatch(final Choice pC) { - return ChoiceHasNoIncoming.Match.newMatch(pC); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfc(final Object[] parameters) { - return rawStreamAllValues(POSITION_C, parameters).map(Choice.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfc() { - return rawStreamAllValuesOfc(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfc() { - return rawStreamAllValuesOfc(emptyArray()); - } - - @Override - protected ChoiceHasNoIncoming.Match tupleToMatch(final Tuple t) { - try { - return ChoiceHasNoIncoming.Match.newMatch((Choice) t.get(POSITION_C)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected ChoiceHasNoIncoming.Match arrayToMatch(final Object[] match) { - try { - return ChoiceHasNoIncoming.Match.newMatch((Choice) match[POSITION_C]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected ChoiceHasNoIncoming.Match arrayToMatchMutable(final Object[] match) { - try { - return ChoiceHasNoIncoming.Match.newMutableMatch((Choice) match[POSITION_C]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return ChoiceHasNoIncoming.instance(); - } - } - - private ChoiceHasNoIncoming() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static ChoiceHasNoIncoming instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected ChoiceHasNoIncoming.Matcher instantiate(final ViatraQueryEngine engine) { - return ChoiceHasNoIncoming.Matcher.on(engine); - } - - @Override - public ChoiceHasNoIncoming.Matcher instantiate() { - return ChoiceHasNoIncoming.Matcher.create(); - } - - @Override - public ChoiceHasNoIncoming.Match newEmptyMatch() { - return ChoiceHasNoIncoming.Match.newEmptyMatch(); - } - - @Override - public ChoiceHasNoIncoming.Match newMatch(final Object... parameters) { - return ChoiceHasNoIncoming.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming (visibility: PUBLIC, simpleName: ChoiceHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming (visibility: PUBLIC, simpleName: ChoiceHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static ChoiceHasNoIncoming INSTANCE = new ChoiceHasNoIncoming(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static ChoiceHasNoIncoming.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_c = new PParameter("c", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Choice")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_c); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoIncoming"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("c"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_c = body.getOrCreateVariableByName("c"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_c), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Choice"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_c, parameter_c) - )); - // neg find transition(_, _, c) - new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var___1_, var_c), Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("c") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java deleted file mode 100644 index 1c20a03b..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/ChoiceHasNoOutgoing.java +++ /dev/null @@ -1,559 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // Choice
- *         /////////
- *         
- *         {@literal @}Constraint(severity="error", message="error", key = {c})
- *         pattern choiceHasNoOutgoing(c : Choice) {
- *         	neg find transition(_, c, _);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class ChoiceHasNoOutgoing extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Choice fC; - - private static List parameterNames = makeImmutableList("c"); - - private Match(final Choice pC) { - this.fC = pC; - } - - @Override - public Object get(final String parameterName) { - if ("c".equals(parameterName)) return this.fC; - return null; - } - - public Choice getC() { - return this.fC; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("c".equals(parameterName) ) { - this.fC = (Choice) newValue; - return true; - } - return false; - } - - public void setC(final Choice pC) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fC = pC; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing"; - } - - @Override - public List parameterNames() { - return ChoiceHasNoOutgoing.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fC}; - } - - @Override - public ChoiceHasNoOutgoing.Match toImmutable() { - return isMutable() ? newMatch(fC) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"c\"=" + prettyPrintValue(fC)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fC); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof ChoiceHasNoOutgoing.Match)) { - ChoiceHasNoOutgoing.Match other = (ChoiceHasNoOutgoing.Match) obj; - return Objects.equals(fC, other.fC); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public ChoiceHasNoOutgoing specification() { - return ChoiceHasNoOutgoing.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static ChoiceHasNoOutgoing.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static ChoiceHasNoOutgoing.Match newMutableMatch(final Choice pC) { - return new Mutable(pC); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the (partial) match object. - * - */ - public static ChoiceHasNoOutgoing.Match newMatch(final Choice pC) { - return new Immutable(pC); - } - - private static final class Mutable extends ChoiceHasNoOutgoing.Match { - Mutable(final Choice pC) { - super(pC); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends ChoiceHasNoOutgoing.Match { - Immutable(final Choice pC) { - super(pC); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // Choice
-   * /////////
-   * 
-   * {@literal @}Constraint(severity="error", message="error", key = {c})
-   * pattern choiceHasNoOutgoing(c : Choice) {
-   * 	neg find transition(_, c, _);
-   * }
-   * 
- * - * @see Match - * @see ChoiceHasNoOutgoing - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static ChoiceHasNoOutgoing.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static ChoiceHasNoOutgoing.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_C = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(ChoiceHasNoOutgoing.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Choice pC) { - return rawStreamAllMatches(new Object[]{pC}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Choice pC) { - return rawStreamAllMatches(new Object[]{pC}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Choice pC) { - return rawGetOneArbitraryMatch(new Object[]{pC}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Choice pC) { - return rawHasMatch(new Object[]{pC}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Choice pC) { - return rawCountMatches(new Object[]{pC}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Choice pC, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pC}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pC the fixed value of pattern parameter c, or null if not bound. - * @return the (partial) match object. - * - */ - public ChoiceHasNoOutgoing.Match newMatch(final Choice pC) { - return ChoiceHasNoOutgoing.Match.newMatch(pC); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfc(final Object[] parameters) { - return rawStreamAllValues(POSITION_C, parameters).map(Choice.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfc() { - return rawStreamAllValuesOfc(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for c. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfc() { - return rawStreamAllValuesOfc(emptyArray()); - } - - @Override - protected ChoiceHasNoOutgoing.Match tupleToMatch(final Tuple t) { - try { - return ChoiceHasNoOutgoing.Match.newMatch((Choice) t.get(POSITION_C)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected ChoiceHasNoOutgoing.Match arrayToMatch(final Object[] match) { - try { - return ChoiceHasNoOutgoing.Match.newMatch((Choice) match[POSITION_C]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected ChoiceHasNoOutgoing.Match arrayToMatchMutable(final Object[] match) { - try { - return ChoiceHasNoOutgoing.Match.newMutableMatch((Choice) match[POSITION_C]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return ChoiceHasNoOutgoing.instance(); - } - } - - private ChoiceHasNoOutgoing() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static ChoiceHasNoOutgoing instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected ChoiceHasNoOutgoing.Matcher instantiate(final ViatraQueryEngine engine) { - return ChoiceHasNoOutgoing.Matcher.on(engine); - } - - @Override - public ChoiceHasNoOutgoing.Matcher instantiate() { - return ChoiceHasNoOutgoing.Matcher.create(); - } - - @Override - public ChoiceHasNoOutgoing.Match newEmptyMatch() { - return ChoiceHasNoOutgoing.Match.newEmptyMatch(); - } - - @Override - public ChoiceHasNoOutgoing.Match newMatch(final Object... parameters) { - return ChoiceHasNoOutgoing.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing (visibility: PUBLIC, simpleName: ChoiceHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing (visibility: PUBLIC, simpleName: ChoiceHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.ChoiceHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static ChoiceHasNoOutgoing INSTANCE = new ChoiceHasNoOutgoing(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static ChoiceHasNoOutgoing.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_c = new PParameter("c", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Choice")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_c); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.choiceHasNoOutgoing"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("c"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_c = body.getOrCreateVariableByName("c"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_c), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Choice"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_c, parameter_c) - )); - // neg find transition(_, c, _) - new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_c, var___1_), Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("c") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java deleted file mode 100644 index 147b27f9..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/EntryInRegion.java +++ /dev/null @@ -1,702 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // Entry
- *         /////////
- *         
- *         pattern entryInRegion(r1 : Region, e1 : Entry) {
- *         	Region.vertices(r1, e1);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class EntryInRegion extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Region fR1; - - private Entry fE1; - - private static List parameterNames = makeImmutableList("r1", "e1"); - - private Match(final Region pR1, final Entry pE1) { - this.fR1 = pR1; - this.fE1 = pE1; - } - - @Override - public Object get(final String parameterName) { - if ("r1".equals(parameterName)) return this.fR1; - if ("e1".equals(parameterName)) return this.fE1; - return null; - } - - public Region getR1() { - return this.fR1; - } - - public Entry getE1() { - return this.fE1; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("r1".equals(parameterName) ) { - this.fR1 = (Region) newValue; - return true; - } - if ("e1".equals(parameterName) ) { - this.fE1 = (Entry) newValue; - return true; - } - return false; - } - - public void setR1(final Region pR1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fR1 = pR1; - } - - public void setE1(final Entry pE1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fE1 = pE1; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion"; - } - - @Override - public List parameterNames() { - return EntryInRegion.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fR1, fE1}; - } - - @Override - public EntryInRegion.Match toImmutable() { - return isMutable() ? newMatch(fR1, fE1) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"r1\"=" + prettyPrintValue(fR1) + ", "); - result.append("\"e1\"=" + prettyPrintValue(fE1)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fR1, fE1); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof EntryInRegion.Match)) { - EntryInRegion.Match other = (EntryInRegion.Match) obj; - return Objects.equals(fR1, other.fR1) && Objects.equals(fE1, other.fE1); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public EntryInRegion specification() { - return EntryInRegion.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static EntryInRegion.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static EntryInRegion.Match newMutableMatch(final Region pR1, final Entry pE1) { - return new Mutable(pR1, pE1); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return the (partial) match object. - * - */ - public static EntryInRegion.Match newMatch(final Region pR1, final Entry pE1) { - return new Immutable(pR1, pE1); - } - - private static final class Mutable extends EntryInRegion.Match { - Mutable(final Region pR1, final Entry pE1) { - super(pR1, pE1); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends EntryInRegion.Match { - Immutable(final Region pR1, final Entry pE1) { - super(pR1, pE1); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // Entry
-   * /////////
-   * 
-   * pattern entryInRegion(r1 : Region, e1 : Entry) {
-   * 	Region.vertices(r1, e1);
-   * }
-   * 
- * - * @see Match - * @see EntryInRegion - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static EntryInRegion.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static EntryInRegion.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_R1 = 0; - - private final static int POSITION_E1 = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(EntryInRegion.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Region pR1, final Entry pE1) { - return rawStreamAllMatches(new Object[]{pR1, pE1}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Region pR1, final Entry pE1) { - return rawStreamAllMatches(new Object[]{pR1, pE1}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Region pR1, final Entry pE1) { - return rawGetOneArbitraryMatch(new Object[]{pR1, pE1}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Region pR1, final Entry pE1) { - return rawHasMatch(new Object[]{pR1, pE1}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Region pR1, final Entry pE1) { - return rawCountMatches(new Object[]{pR1, pE1}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Region pR1, final Entry pE1, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pR1, pE1}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param pE1 the fixed value of pattern parameter e1, or null if not bound. - * @return the (partial) match object. - * - */ - public EntryInRegion.Match newMatch(final Region pR1, final Entry pE1) { - return EntryInRegion.Match.newMatch(pR1, pE1); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfr1(final Object[] parameters) { - return rawStreamAllValues(POSITION_R1, parameters).map(Region.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfr1() { - return rawStreamAllValuesOfr1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfr1() { - return rawStreamAllValuesOfr1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for r1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfr1(final EntryInRegion.Match partialMatch) { - return rawStreamAllValuesOfr1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for r1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfr1(final Entry pE1) { - return rawStreamAllValuesOfr1(new Object[]{null, pE1}); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfr1(final EntryInRegion.Match partialMatch) { - return rawStreamAllValuesOfr1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfr1(final Entry pE1) { - return rawStreamAllValuesOfr1(new Object[]{null, pE1}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfe1(final Object[] parameters) { - return rawStreamAllValues(POSITION_E1, parameters).map(Entry.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for e1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe1() { - return rawStreamAllValuesOfe1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe1() { - return rawStreamAllValuesOfe1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for e1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe1(final EntryInRegion.Match partialMatch) { - return rawStreamAllValuesOfe1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for e1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe1(final Region pR1) { - return rawStreamAllValuesOfe1(new Object[]{pR1, null}); - } - - /** - * Retrieve the set of values that occur in matches for e1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe1(final EntryInRegion.Match partialMatch) { - return rawStreamAllValuesOfe1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe1(final Region pR1) { - return rawStreamAllValuesOfe1(new Object[]{pR1, null}).collect(Collectors.toSet()); - } - - @Override - protected EntryInRegion.Match tupleToMatch(final Tuple t) { - try { - return EntryInRegion.Match.newMatch((Region) t.get(POSITION_R1), (Entry) t.get(POSITION_E1)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected EntryInRegion.Match arrayToMatch(final Object[] match) { - try { - return EntryInRegion.Match.newMatch((Region) match[POSITION_R1], (Entry) match[POSITION_E1]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected EntryInRegion.Match arrayToMatchMutable(final Object[] match) { - try { - return EntryInRegion.Match.newMutableMatch((Region) match[POSITION_R1], (Entry) match[POSITION_E1]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return EntryInRegion.instance(); - } - } - - private EntryInRegion() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static EntryInRegion instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected EntryInRegion.Matcher instantiate(final ViatraQueryEngine engine) { - return EntryInRegion.Matcher.on(engine); - } - - @Override - public EntryInRegion.Matcher instantiate() { - return EntryInRegion.Matcher.create(); - } - - @Override - public EntryInRegion.Match newEmptyMatch() { - return EntryInRegion.Match.newEmptyMatch(); - } - - @Override - public EntryInRegion.Match newMatch(final Object... parameters) { - return EntryInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion (visibility: PUBLIC, simpleName: EntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion (visibility: PUBLIC, simpleName: EntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static EntryInRegion INSTANCE = new EntryInRegion(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static EntryInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_r1 = new PParameter("r1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); - - private final PParameter parameter_e1 = new PParameter("e1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_r1, parameter_e1); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.entryInRegion"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("r1","e1"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_r1 = body.getOrCreateVariableByName("r1"); - PVariable var_e1 = body.getOrCreateVariableByName("e1"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_e1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_r1, parameter_r1), - new ExportedParameter(body, var_e1, parameter_e1) - )); - // Region.vertices(r1, e1) - new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_e1); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java deleted file mode 100644 index 236ce5ff..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleIncomingTrainsition.java +++ /dev/null @@ -1,549 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern hasMultipleIncomingTrainsition(v : Synchronization) {
- *         	find transition(_, src1, v);
- *         	find transition(_, src2, v);
- *         	src1 != src2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class HasMultipleIncomingTrainsition extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fV; - - private static List parameterNames = makeImmutableList("v"); - - private Match(final Synchronization pV) { - this.fV = pV; - } - - @Override - public Object get(final String parameterName) { - if ("v".equals(parameterName)) return this.fV; - return null; - } - - public Synchronization getV() { - return this.fV; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("v".equals(parameterName) ) { - this.fV = (Synchronization) newValue; - return true; - } - return false; - } - - public void setV(final Synchronization pV) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV = pV; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition"; - } - - @Override - public List parameterNames() { - return HasMultipleIncomingTrainsition.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fV}; - } - - @Override - public HasMultipleIncomingTrainsition.Match toImmutable() { - return isMutable() ? newMatch(fV) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"v\"=" + prettyPrintValue(fV)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fV); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof HasMultipleIncomingTrainsition.Match)) { - HasMultipleIncomingTrainsition.Match other = (HasMultipleIncomingTrainsition.Match) obj; - return Objects.equals(fV, other.fV); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public HasMultipleIncomingTrainsition specification() { - return HasMultipleIncomingTrainsition.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static HasMultipleIncomingTrainsition.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static HasMultipleIncomingTrainsition.Match newMutableMatch(final Synchronization pV) { - return new Mutable(pV); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public static HasMultipleIncomingTrainsition.Match newMatch(final Synchronization pV) { - return new Immutable(pV); - } - - private static final class Mutable extends HasMultipleIncomingTrainsition.Match { - Mutable(final Synchronization pV) { - super(pV); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends HasMultipleIncomingTrainsition.Match { - Immutable(final Synchronization pV) { - super(pV); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern hasMultipleIncomingTrainsition(v : Synchronization) {
-   * 	find transition(_, src1, v);
-   * 	find transition(_, src2, v);
-   * 	src1 != src2;
-   * }
-   * 
- * - * @see Match - * @see HasMultipleIncomingTrainsition - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static HasMultipleIncomingTrainsition.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static HasMultipleIncomingTrainsition.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_V = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleIncomingTrainsition.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pV) { - return rawStreamAllMatches(new Object[]{pV}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pV) { - return rawStreamAllMatches(new Object[]{pV}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pV) { - return rawGetOneArbitraryMatch(new Object[]{pV}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pV) { - return rawHasMatch(new Object[]{pV}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pV) { - return rawCountMatches(new Object[]{pV}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pV, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pV}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public HasMultipleIncomingTrainsition.Match newMatch(final Synchronization pV) { - return HasMultipleIncomingTrainsition.Match.newMatch(pV); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv(final Object[] parameters) { - return rawStreamAllValues(POSITION_V, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()); - } - - @Override - protected HasMultipleIncomingTrainsition.Match tupleToMatch(final Tuple t) { - try { - return HasMultipleIncomingTrainsition.Match.newMatch((Synchronization) t.get(POSITION_V)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleIncomingTrainsition.Match arrayToMatch(final Object[] match) { - try { - return HasMultipleIncomingTrainsition.Match.newMatch((Synchronization) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleIncomingTrainsition.Match arrayToMatchMutable(final Object[] match) { - try { - return HasMultipleIncomingTrainsition.Match.newMutableMatch((Synchronization) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return HasMultipleIncomingTrainsition.instance(); - } - } - - private HasMultipleIncomingTrainsition() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static HasMultipleIncomingTrainsition instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected HasMultipleIncomingTrainsition.Matcher instantiate(final ViatraQueryEngine engine) { - return HasMultipleIncomingTrainsition.Matcher.on(engine); - } - - @Override - public HasMultipleIncomingTrainsition.Matcher instantiate() { - return HasMultipleIncomingTrainsition.Matcher.create(); - } - - @Override - public HasMultipleIncomingTrainsition.Match newEmptyMatch() { - return HasMultipleIncomingTrainsition.Match.newEmptyMatch(); - } - - @Override - public HasMultipleIncomingTrainsition.Match newMatch(final Object... parameters) { - return HasMultipleIncomingTrainsition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition (visibility: PUBLIC, simpleName: HasMultipleIncomingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition (visibility: PUBLIC, simpleName: HasMultipleIncomingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static HasMultipleIncomingTrainsition INSTANCE = new HasMultipleIncomingTrainsition(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static HasMultipleIncomingTrainsition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_v); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleIncomingTrainsition"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("v"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_v = body.getOrCreateVariableByName("v"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var_src1 = body.getOrCreateVariableByName("src1"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - PVariable var_src2 = body.getOrCreateVariableByName("src2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_v, parameter_v) - )); - // find transition(_, src1, v) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_src1, var_v), Transition.instance().getInternalQueryRepresentation()); - // find transition(_, src2, v) - new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_src2, var_v), Transition.instance().getInternalQueryRepresentation()); - // src1 != src2 - new Inequality(body, var_src1, var_src2); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java deleted file mode 100644 index 115b93e1..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleOutgoingTrainsition.java +++ /dev/null @@ -1,549 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern hasMultipleOutgoingTrainsition(v : Synchronization) {
- *         	find transition(_, v, trg1);
- *         	find transition(_, v, trg2);
- *         	trg1 != trg2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class HasMultipleOutgoingTrainsition extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fV; - - private static List parameterNames = makeImmutableList("v"); - - private Match(final Synchronization pV) { - this.fV = pV; - } - - @Override - public Object get(final String parameterName) { - if ("v".equals(parameterName)) return this.fV; - return null; - } - - public Synchronization getV() { - return this.fV; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("v".equals(parameterName) ) { - this.fV = (Synchronization) newValue; - return true; - } - return false; - } - - public void setV(final Synchronization pV) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV = pV; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition"; - } - - @Override - public List parameterNames() { - return HasMultipleOutgoingTrainsition.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fV}; - } - - @Override - public HasMultipleOutgoingTrainsition.Match toImmutable() { - return isMutable() ? newMatch(fV) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"v\"=" + prettyPrintValue(fV)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fV); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof HasMultipleOutgoingTrainsition.Match)) { - HasMultipleOutgoingTrainsition.Match other = (HasMultipleOutgoingTrainsition.Match) obj; - return Objects.equals(fV, other.fV); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public HasMultipleOutgoingTrainsition specification() { - return HasMultipleOutgoingTrainsition.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static HasMultipleOutgoingTrainsition.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static HasMultipleOutgoingTrainsition.Match newMutableMatch(final Synchronization pV) { - return new Mutable(pV); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public static HasMultipleOutgoingTrainsition.Match newMatch(final Synchronization pV) { - return new Immutable(pV); - } - - private static final class Mutable extends HasMultipleOutgoingTrainsition.Match { - Mutable(final Synchronization pV) { - super(pV); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends HasMultipleOutgoingTrainsition.Match { - Immutable(final Synchronization pV) { - super(pV); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern hasMultipleOutgoingTrainsition(v : Synchronization) {
-   * 	find transition(_, v, trg1);
-   * 	find transition(_, v, trg2);
-   * 	trg1 != trg2;
-   * }
-   * 
- * - * @see Match - * @see HasMultipleOutgoingTrainsition - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static HasMultipleOutgoingTrainsition.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static HasMultipleOutgoingTrainsition.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_V = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleOutgoingTrainsition.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pV) { - return rawStreamAllMatches(new Object[]{pV}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pV) { - return rawStreamAllMatches(new Object[]{pV}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pV) { - return rawGetOneArbitraryMatch(new Object[]{pV}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pV) { - return rawHasMatch(new Object[]{pV}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pV) { - return rawCountMatches(new Object[]{pV}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pV, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pV}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public HasMultipleOutgoingTrainsition.Match newMatch(final Synchronization pV) { - return HasMultipleOutgoingTrainsition.Match.newMatch(pV); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv(final Object[] parameters) { - return rawStreamAllValues(POSITION_V, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()); - } - - @Override - protected HasMultipleOutgoingTrainsition.Match tupleToMatch(final Tuple t) { - try { - return HasMultipleOutgoingTrainsition.Match.newMatch((Synchronization) t.get(POSITION_V)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleOutgoingTrainsition.Match arrayToMatch(final Object[] match) { - try { - return HasMultipleOutgoingTrainsition.Match.newMatch((Synchronization) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleOutgoingTrainsition.Match arrayToMatchMutable(final Object[] match) { - try { - return HasMultipleOutgoingTrainsition.Match.newMutableMatch((Synchronization) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return HasMultipleOutgoingTrainsition.instance(); - } - } - - private HasMultipleOutgoingTrainsition() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static HasMultipleOutgoingTrainsition instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected HasMultipleOutgoingTrainsition.Matcher instantiate(final ViatraQueryEngine engine) { - return HasMultipleOutgoingTrainsition.Matcher.on(engine); - } - - @Override - public HasMultipleOutgoingTrainsition.Matcher instantiate() { - return HasMultipleOutgoingTrainsition.Matcher.create(); - } - - @Override - public HasMultipleOutgoingTrainsition.Match newEmptyMatch() { - return HasMultipleOutgoingTrainsition.Match.newEmptyMatch(); - } - - @Override - public HasMultipleOutgoingTrainsition.Match newMatch(final Object... parameters) { - return HasMultipleOutgoingTrainsition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition (visibility: PUBLIC, simpleName: HasMultipleOutgoingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition (visibility: PUBLIC, simpleName: HasMultipleOutgoingTrainsition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static HasMultipleOutgoingTrainsition INSTANCE = new HasMultipleOutgoingTrainsition(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static HasMultipleOutgoingTrainsition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_v); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleOutgoingTrainsition"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("v"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_v = body.getOrCreateVariableByName("v"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var_trg1 = body.getOrCreateVariableByName("trg1"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - PVariable var_trg2 = body.getOrCreateVariableByName("trg2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_v, parameter_v) - )); - // find transition(_, v, trg1) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v, var_trg1), Transition.instance().getInternalQueryRepresentation()); - // find transition(_, v, trg2) - new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_v, var_trg2), Transition.instance().getInternalQueryRepresentation()); - // trg1 != trg2 - new Inequality(body, var_trg1, var_trg2); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java deleted file mode 100644 index 5542ccbb..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/HasMultipleRegions.java +++ /dev/null @@ -1,555 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern hasMultipleRegions(composite: CompositeElement) {
- *         	CompositeElement.regions(composite,region1);
- *         	CompositeElement.regions(composite,region2);
- *         	region1 != region2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class HasMultipleRegions extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private CompositeElement fComposite; - - private static List parameterNames = makeImmutableList("composite"); - - private Match(final CompositeElement pComposite) { - this.fComposite = pComposite; - } - - @Override - public Object get(final String parameterName) { - if ("composite".equals(parameterName)) return this.fComposite; - return null; - } - - public CompositeElement getComposite() { - return this.fComposite; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("composite".equals(parameterName) ) { - this.fComposite = (CompositeElement) newValue; - return true; - } - return false; - } - - public void setComposite(final CompositeElement pComposite) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fComposite = pComposite; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions"; - } - - @Override - public List parameterNames() { - return HasMultipleRegions.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fComposite}; - } - - @Override - public HasMultipleRegions.Match toImmutable() { - return isMutable() ? newMatch(fComposite) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"composite\"=" + prettyPrintValue(fComposite)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fComposite); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof HasMultipleRegions.Match)) { - HasMultipleRegions.Match other = (HasMultipleRegions.Match) obj; - return Objects.equals(fComposite, other.fComposite); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public HasMultipleRegions specification() { - return HasMultipleRegions.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static HasMultipleRegions.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static HasMultipleRegions.Match newMutableMatch(final CompositeElement pComposite) { - return new Mutable(pComposite); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return the (partial) match object. - * - */ - public static HasMultipleRegions.Match newMatch(final CompositeElement pComposite) { - return new Immutable(pComposite); - } - - private static final class Mutable extends HasMultipleRegions.Match { - Mutable(final CompositeElement pComposite) { - super(pComposite); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends HasMultipleRegions.Match { - Immutable(final CompositeElement pComposite) { - super(pComposite); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern hasMultipleRegions(composite: CompositeElement) {
-   * 	CompositeElement.regions(composite,region1);
-   * 	CompositeElement.regions(composite,region2);
-   * 	region1 != region2;
-   * }
-   * 
- * - * @see Match - * @see HasMultipleRegions - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static HasMultipleRegions.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static HasMultipleRegions.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_COMPOSITE = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(HasMultipleRegions.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final CompositeElement pComposite) { - return rawStreamAllMatches(new Object[]{pComposite}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final CompositeElement pComposite) { - return rawStreamAllMatches(new Object[]{pComposite}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final CompositeElement pComposite) { - return rawGetOneArbitraryMatch(new Object[]{pComposite}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final CompositeElement pComposite) { - return rawHasMatch(new Object[]{pComposite}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final CompositeElement pComposite) { - return rawCountMatches(new Object[]{pComposite}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final CompositeElement pComposite, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pComposite}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pComposite the fixed value of pattern parameter composite, or null if not bound. - * @return the (partial) match object. - * - */ - public HasMultipleRegions.Match newMatch(final CompositeElement pComposite) { - return HasMultipleRegions.Match.newMatch(pComposite); - } - - /** - * Retrieve the set of values that occur in matches for composite. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfcomposite(final Object[] parameters) { - return rawStreamAllValues(POSITION_COMPOSITE, parameters).map(CompositeElement.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for composite. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfcomposite() { - return rawStreamAllValuesOfcomposite(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for composite. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfcomposite() { - return rawStreamAllValuesOfcomposite(emptyArray()); - } - - @Override - protected HasMultipleRegions.Match tupleToMatch(final Tuple t) { - try { - return HasMultipleRegions.Match.newMatch((CompositeElement) t.get(POSITION_COMPOSITE)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleRegions.Match arrayToMatch(final Object[] match) { - try { - return HasMultipleRegions.Match.newMatch((CompositeElement) match[POSITION_COMPOSITE]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected HasMultipleRegions.Match arrayToMatchMutable(final Object[] match) { - try { - return HasMultipleRegions.Match.newMutableMatch((CompositeElement) match[POSITION_COMPOSITE]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return HasMultipleRegions.instance(); - } - } - - private HasMultipleRegions() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static HasMultipleRegions instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected HasMultipleRegions.Matcher instantiate(final ViatraQueryEngine engine) { - return HasMultipleRegions.Matcher.on(engine); - } - - @Override - public HasMultipleRegions.Matcher instantiate() { - return HasMultipleRegions.Matcher.create(); - } - - @Override - public HasMultipleRegions.Match newEmptyMatch() { - return HasMultipleRegions.Match.newEmptyMatch(); - } - - @Override - public HasMultipleRegions.Match newMatch(final Object... parameters) { - return HasMultipleRegions.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions (visibility: PUBLIC, simpleName: HasMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions (visibility: PUBLIC, simpleName: HasMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static HasMultipleRegions INSTANCE = new HasMultipleRegions(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static HasMultipleRegions.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_composite = new PParameter("composite", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "CompositeElement")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_composite); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.hasMultipleRegions"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("composite"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_composite = body.getOrCreateVariableByName("composite"); - PVariable var_region1 = body.getOrCreateVariableByName("region1"); - PVariable var_region2 = body.getOrCreateVariableByName("region2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_composite, parameter_composite) - )); - // CompositeElement.regions(composite,region1) - new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_composite, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - new Equality(body, var__virtual_0_, var_region1); - // CompositeElement.regions(composite,region2) - new TypeConstraint(body, Tuples.flatTupleOf(var_composite), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_composite, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - new Equality(body, var__virtual_1_, var_region2); - // region1 != region2 - new Inequality(body, var_region1, var_region2); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java deleted file mode 100644 index ed8ca3e5..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/IncomingToEntry.java +++ /dev/null @@ -1,703 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {e})
- *         pattern incomingToEntry(t : Transition, e : Entry) {
- *         	find transition(t, _, e);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class IncomingToEntry extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Transition fT; - - private Entry fE; - - private static List parameterNames = makeImmutableList("t", "e"); - - private Match(final Transition pT, final Entry pE) { - this.fT = pT; - this.fE = pE; - } - - @Override - public Object get(final String parameterName) { - if ("t".equals(parameterName)) return this.fT; - if ("e".equals(parameterName)) return this.fE; - return null; - } - - public Transition getT() { - return this.fT; - } - - public Entry getE() { - return this.fE; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("t".equals(parameterName) ) { - this.fT = (Transition) newValue; - return true; - } - if ("e".equals(parameterName) ) { - this.fE = (Entry) newValue; - return true; - } - return false; - } - - public void setT(final Transition pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setE(final Entry pE) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fE = pE; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry"; - } - - @Override - public List parameterNames() { - return IncomingToEntry.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fE}; - } - - @Override - public IncomingToEntry.Match toImmutable() { - return isMutable() ? newMatch(fT, fE) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"t\"=" + prettyPrintValue(fT) + ", "); - result.append("\"e\"=" + prettyPrintValue(fE)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fE); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof IncomingToEntry.Match)) { - IncomingToEntry.Match other = (IncomingToEntry.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fE, other.fE); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public IncomingToEntry specification() { - return IncomingToEntry.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static IncomingToEntry.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static IncomingToEntry.Match newMutableMatch(final Transition pT, final Entry pE) { - return new Mutable(pT, pE); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public static IncomingToEntry.Match newMatch(final Transition pT, final Entry pE) { - return new Immutable(pT, pE); - } - - private static final class Mutable extends IncomingToEntry.Match { - Mutable(final Transition pT, final Entry pE) { - super(pT, pE); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends IncomingToEntry.Match { - Immutable(final Transition pT, final Entry pE) { - super(pT, pE); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {e})
-   * pattern incomingToEntry(t : Transition, e : Entry) {
-   * 	find transition(t, _, e);
-   * }
-   * 
- * - * @see Match - * @see IncomingToEntry - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static IncomingToEntry.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static IncomingToEntry.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_E = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(IncomingToEntry.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Transition pT, final Entry pE) { - return rawStreamAllMatches(new Object[]{pT, pE}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Transition pT, final Entry pE) { - return rawStreamAllMatches(new Object[]{pT, pE}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Transition pT, final Entry pE) { - return rawGetOneArbitraryMatch(new Object[]{pT, pE}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Transition pT, final Entry pE) { - return rawHasMatch(new Object[]{pT, pE}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Transition pT, final Entry pE) { - return rawCountMatches(new Object[]{pT, pE}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Transition pT, final Entry pE, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pE}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public IncomingToEntry.Match newMatch(final Transition pT, final Entry pE) { - return IncomingToEntry.Match.newMatch(pT, pE); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final IncomingToEntry.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final Entry pE) { - return rawStreamAllValuesOft(new Object[]{null, pE}); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final IncomingToEntry.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final Entry pE) { - return rawStreamAllValuesOft(new Object[]{null, pE}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfe(final Object[] parameters) { - return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final IncomingToEntry.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final Transition pT) { - return rawStreamAllValuesOfe(new Object[]{pT, null}); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final IncomingToEntry.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final Transition pT) { - return rawStreamAllValuesOfe(new Object[]{pT, null}).collect(Collectors.toSet()); - } - - @Override - protected IncomingToEntry.Match tupleToMatch(final Tuple t) { - try { - return IncomingToEntry.Match.newMatch((Transition) t.get(POSITION_T), (Entry) t.get(POSITION_E)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected IncomingToEntry.Match arrayToMatch(final Object[] match) { - try { - return IncomingToEntry.Match.newMatch((Transition) match[POSITION_T], (Entry) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected IncomingToEntry.Match arrayToMatchMutable(final Object[] match) { - try { - return IncomingToEntry.Match.newMutableMatch((Transition) match[POSITION_T], (Entry) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return IncomingToEntry.instance(); - } - } - - private IncomingToEntry() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IncomingToEntry instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected IncomingToEntry.Matcher instantiate(final ViatraQueryEngine engine) { - return IncomingToEntry.Matcher.on(engine); - } - - @Override - public IncomingToEntry.Matcher instantiate() { - return IncomingToEntry.Matcher.create(); - } - - @Override - public IncomingToEntry.Match newEmptyMatch() { - return IncomingToEntry.Match.newEmptyMatch(); - } - - @Override - public IncomingToEntry.Match newMatch(final Object... parameters) { - return IncomingToEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry (visibility: PUBLIC, simpleName: IncomingToEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry (visibility: PUBLIC, simpleName: IncomingToEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.IncomingToEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static IncomingToEntry INSTANCE = new IncomingToEntry(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static IncomingToEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_t, parameter_e); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.incomingToEntry"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("t","e"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_t = body.getOrCreateVariableByName("t"); - PVariable var_e = body.getOrCreateVariableByName("e"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_t, parameter_t), - new ExportedParameter(body, var_e, parameter_e) - )); - // find transition(t, _, e) - new PositivePatternCall(body, Tuples.flatTupleOf(var_t, var___0_, var_e), ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("e") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java deleted file mode 100644 index e4c1bac5..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/MultipleTransitionFromEntry.java +++ /dev/null @@ -1,827 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {e})
- *         pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) {
- *         	Entry.outgoingTransitions(e,t1);
- *         	Entry.outgoingTransitions(e,t2);
- *         	t1!=t2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class MultipleTransitionFromEntry extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Entry fE; - - private Transition fT1; - - private Transition fT2; - - private static List parameterNames = makeImmutableList("e", "t1", "t2"); - - private Match(final Entry pE, final Transition pT1, final Transition pT2) { - this.fE = pE; - this.fT1 = pT1; - this.fT2 = pT2; - } - - @Override - public Object get(final String parameterName) { - if ("e".equals(parameterName)) return this.fE; - if ("t1".equals(parameterName)) return this.fT1; - if ("t2".equals(parameterName)) return this.fT2; - return null; - } - - public Entry getE() { - return this.fE; - } - - public Transition getT1() { - return this.fT1; - } - - public Transition getT2() { - return this.fT2; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("e".equals(parameterName) ) { - this.fE = (Entry) newValue; - return true; - } - if ("t1".equals(parameterName) ) { - this.fT1 = (Transition) newValue; - return true; - } - if ("t2".equals(parameterName) ) { - this.fT2 = (Transition) newValue; - return true; - } - return false; - } - - public void setE(final Entry pE) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fE = pE; - } - - public void setT1(final Transition pT1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT1 = pT1; - } - - public void setT2(final Transition pT2) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT2 = pT2; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry"; - } - - @Override - public List parameterNames() { - return MultipleTransitionFromEntry.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fE, fT1, fT2}; - } - - @Override - public MultipleTransitionFromEntry.Match toImmutable() { - return isMutable() ? newMatch(fE, fT1, fT2) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"e\"=" + prettyPrintValue(fE) + ", "); - result.append("\"t1\"=" + prettyPrintValue(fT1) + ", "); - result.append("\"t2\"=" + prettyPrintValue(fT2)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fE, fT1, fT2); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof MultipleTransitionFromEntry.Match)) { - MultipleTransitionFromEntry.Match other = (MultipleTransitionFromEntry.Match) obj; - return Objects.equals(fE, other.fE) && Objects.equals(fT1, other.fT1) && Objects.equals(fT2, other.fT2); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public MultipleTransitionFromEntry specification() { - return MultipleTransitionFromEntry.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static MultipleTransitionFromEntry.Match newEmptyMatch() { - return new Mutable(null, null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static MultipleTransitionFromEntry.Match newMutableMatch(final Entry pE, final Transition pT1, final Transition pT2) { - return new Mutable(pE, pT1, pT2); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return the (partial) match object. - * - */ - public static MultipleTransitionFromEntry.Match newMatch(final Entry pE, final Transition pT1, final Transition pT2) { - return new Immutable(pE, pT1, pT2); - } - - private static final class Mutable extends MultipleTransitionFromEntry.Match { - Mutable(final Entry pE, final Transition pT1, final Transition pT2) { - super(pE, pT1, pT2); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends MultipleTransitionFromEntry.Match { - Immutable(final Entry pE, final Transition pT1, final Transition pT2) { - super(pE, pT1, pT2); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {e})
-   * pattern multipleTransitionFromEntry(e : Entry, t1 : Transition, t2: Transition) {
-   * 	Entry.outgoingTransitions(e,t1);
-   * 	Entry.outgoingTransitions(e,t2);
-   * 	t1!=t2;
-   * }
-   * 
- * - * @see Match - * @see MultipleTransitionFromEntry - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static MultipleTransitionFromEntry.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static MultipleTransitionFromEntry.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_E = 0; - - private final static int POSITION_T1 = 1; - - private final static int POSITION_T2 = 2; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(MultipleTransitionFromEntry.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Entry pE, final Transition pT1, final Transition pT2) { - return rawStreamAllMatches(new Object[]{pE, pT1, pT2}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Entry pE, final Transition pT1, final Transition pT2) { - return rawStreamAllMatches(new Object[]{pE, pT1, pT2}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Entry pE, final Transition pT1, final Transition pT2) { - return rawGetOneArbitraryMatch(new Object[]{pE, pT1, pT2}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Entry pE, final Transition pT1, final Transition pT2) { - return rawHasMatch(new Object[]{pE, pT1, pT2}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Entry pE, final Transition pT1, final Transition pT2) { - return rawCountMatches(new Object[]{pE, pT1, pT2}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Entry pE, final Transition pT1, final Transition pT2, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pE, pT1, pT2}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param pT1 the fixed value of pattern parameter t1, or null if not bound. - * @param pT2 the fixed value of pattern parameter t2, or null if not bound. - * @return the (partial) match object. - * - */ - public MultipleTransitionFromEntry.Match newMatch(final Entry pE, final Transition pT1, final Transition pT2) { - return MultipleTransitionFromEntry.Match.newMatch(pE, pT1, pT2); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfe(final Object[] parameters) { - return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final Transition pT1, final Transition pT2) { - return rawStreamAllValuesOfe(new Object[]{null, pT1, pT2}); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final Transition pT1, final Transition pT2) { - return rawStreamAllValuesOfe(new Object[]{null, pT1, pT2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft1(final Object[] parameters) { - return rawStreamAllValues(POSITION_T1, parameters).map(Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft1() { - return rawStreamAllValuesOft1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft1() { - return rawStreamAllValuesOft1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft1(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOft1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft1(final Entry pE, final Transition pT2) { - return rawStreamAllValuesOft1(new Object[]{pE, null, pT2}); - } - - /** - * Retrieve the set of values that occur in matches for t1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft1(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOft1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft1(final Entry pE, final Transition pT2) { - return rawStreamAllValuesOft1(new Object[]{pE, null, pT2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t2. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft2(final Object[] parameters) { - return rawStreamAllValues(POSITION_T2, parameters).map(Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft2() { - return rawStreamAllValuesOft2(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft2() { - return rawStreamAllValuesOft2(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft2(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOft2(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft2(final Entry pE, final Transition pT1) { - return rawStreamAllValuesOft2(new Object[]{pE, pT1, null}); - } - - /** - * Retrieve the set of values that occur in matches for t2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft2(final MultipleTransitionFromEntry.Match partialMatch) { - return rawStreamAllValuesOft2(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft2(final Entry pE, final Transition pT1) { - return rawStreamAllValuesOft2(new Object[]{pE, pT1, null}).collect(Collectors.toSet()); - } - - @Override - protected MultipleTransitionFromEntry.Match tupleToMatch(final Tuple t) { - try { - return MultipleTransitionFromEntry.Match.newMatch((Entry) t.get(POSITION_E), (Transition) t.get(POSITION_T1), (Transition) t.get(POSITION_T2)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected MultipleTransitionFromEntry.Match arrayToMatch(final Object[] match) { - try { - return MultipleTransitionFromEntry.Match.newMatch((Entry) match[POSITION_E], (Transition) match[POSITION_T1], (Transition) match[POSITION_T2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected MultipleTransitionFromEntry.Match arrayToMatchMutable(final Object[] match) { - try { - return MultipleTransitionFromEntry.Match.newMutableMatch((Entry) match[POSITION_E], (Transition) match[POSITION_T1], (Transition) match[POSITION_T2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return MultipleTransitionFromEntry.instance(); - } - } - - private MultipleTransitionFromEntry() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static MultipleTransitionFromEntry instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected MultipleTransitionFromEntry.Matcher instantiate(final ViatraQueryEngine engine) { - return MultipleTransitionFromEntry.Matcher.on(engine); - } - - @Override - public MultipleTransitionFromEntry.Matcher instantiate() { - return MultipleTransitionFromEntry.Matcher.create(); - } - - @Override - public MultipleTransitionFromEntry.Match newEmptyMatch() { - return MultipleTransitionFromEntry.Match.newEmptyMatch(); - } - - @Override - public MultipleTransitionFromEntry.Match newMatch(final Object... parameters) { - return MultipleTransitionFromEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[2]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry (visibility: PUBLIC, simpleName: MultipleTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry (visibility: PUBLIC, simpleName: MultipleTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.MultipleTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static MultipleTransitionFromEntry INSTANCE = new MultipleTransitionFromEntry(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static MultipleTransitionFromEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); - - private final PParameter parameter_t1 = new PParameter("t1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final PParameter parameter_t2 = new PParameter("t2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_e, parameter_t1, parameter_t2); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.multipleTransitionFromEntry"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("e","t1","t2"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_e = body.getOrCreateVariableByName("e"); - PVariable var_t1 = body.getOrCreateVariableByName("t1"); - PVariable var_t2 = body.getOrCreateVariableByName("t2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_e, parameter_e), - new ExportedParameter(body, var_t1, parameter_t1), - new ExportedParameter(body, var_t2, parameter_t2) - )); - // Entry.outgoingTransitions(e,t1) - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new Equality(body, var__virtual_0_, var_t1); - // Entry.outgoingTransitions(e,t2) - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new Equality(body, var__virtual_1_, var_t2); - // t1!=t2 - new Inequality(body, var_t1, var_t2); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("e") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java deleted file mode 100644 index c1f7df4a..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoEntryInRegion.java +++ /dev/null @@ -1,550 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.EntryInRegion; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {r1})
- *         pattern noEntryInRegion(r1 : Region) {
- *         	neg find entryInRegion(r1, _);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class NoEntryInRegion extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Region fR1; - - private static List parameterNames = makeImmutableList("r1"); - - private Match(final Region pR1) { - this.fR1 = pR1; - } - - @Override - public Object get(final String parameterName) { - if ("r1".equals(parameterName)) return this.fR1; - return null; - } - - public Region getR1() { - return this.fR1; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("r1".equals(parameterName) ) { - this.fR1 = (Region) newValue; - return true; - } - return false; - } - - public void setR1(final Region pR1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fR1 = pR1; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion"; - } - - @Override - public List parameterNames() { - return NoEntryInRegion.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fR1}; - } - - @Override - public NoEntryInRegion.Match toImmutable() { - return isMutable() ? newMatch(fR1) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"r1\"=" + prettyPrintValue(fR1)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fR1); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof NoEntryInRegion.Match)) { - NoEntryInRegion.Match other = (NoEntryInRegion.Match) obj; - return Objects.equals(fR1, other.fR1); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public NoEntryInRegion specification() { - return NoEntryInRegion.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static NoEntryInRegion.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static NoEntryInRegion.Match newMutableMatch(final Region pR1) { - return new Mutable(pR1); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return the (partial) match object. - * - */ - public static NoEntryInRegion.Match newMatch(final Region pR1) { - return new Immutable(pR1); - } - - private static final class Mutable extends NoEntryInRegion.Match { - Mutable(final Region pR1) { - super(pR1); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends NoEntryInRegion.Match { - Immutable(final Region pR1) { - super(pR1); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {r1})
-   * pattern noEntryInRegion(r1 : Region) {
-   * 	neg find entryInRegion(r1, _);
-   * }
-   * 
- * - * @see Match - * @see NoEntryInRegion - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static NoEntryInRegion.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static NoEntryInRegion.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_R1 = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoEntryInRegion.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Region pR1) { - return rawStreamAllMatches(new Object[]{pR1}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Region pR1) { - return rawStreamAllMatches(new Object[]{pR1}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Region pR1) { - return rawGetOneArbitraryMatch(new Object[]{pR1}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Region pR1) { - return rawHasMatch(new Object[]{pR1}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Region pR1) { - return rawCountMatches(new Object[]{pR1}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Region pR1, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pR1}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pR1 the fixed value of pattern parameter r1, or null if not bound. - * @return the (partial) match object. - * - */ - public NoEntryInRegion.Match newMatch(final Region pR1) { - return NoEntryInRegion.Match.newMatch(pR1); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfr1(final Object[] parameters) { - return rawStreamAllValues(POSITION_R1, parameters).map(Region.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfr1() { - return rawStreamAllValuesOfr1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for r1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfr1() { - return rawStreamAllValuesOfr1(emptyArray()); - } - - @Override - protected NoEntryInRegion.Match tupleToMatch(final Tuple t) { - try { - return NoEntryInRegion.Match.newMatch((Region) t.get(POSITION_R1)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected NoEntryInRegion.Match arrayToMatch(final Object[] match) { - try { - return NoEntryInRegion.Match.newMatch((Region) match[POSITION_R1]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected NoEntryInRegion.Match arrayToMatchMutable(final Object[] match) { - try { - return NoEntryInRegion.Match.newMutableMatch((Region) match[POSITION_R1]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return NoEntryInRegion.instance(); - } - } - - private NoEntryInRegion() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static NoEntryInRegion instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected NoEntryInRegion.Matcher instantiate(final ViatraQueryEngine engine) { - return NoEntryInRegion.Matcher.on(engine); - } - - @Override - public NoEntryInRegion.Matcher instantiate() { - return NoEntryInRegion.Matcher.create(); - } - - @Override - public NoEntryInRegion.Match newEmptyMatch() { - return NoEntryInRegion.Match.newEmptyMatch(); - } - - @Override - public NoEntryInRegion.Match newMatch(final Object... parameters) { - return NoEntryInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion (visibility: PUBLIC, simpleName: NoEntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion (visibility: PUBLIC, simpleName: NoEntryInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoEntryInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static NoEntryInRegion INSTANCE = new NoEntryInRegion(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static NoEntryInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_r1 = new PParameter("r1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_r1); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noEntryInRegion"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("r1"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_r1 = body.getOrCreateVariableByName("r1"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_r1, parameter_r1) - )); - // neg find entryInRegion(r1, _) - new NegativePatternCall(body, Tuples.flatTupleOf(var_r1, var___0_), EntryInRegion.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("r1") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java deleted file mode 100644 index d9a3de50..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoOutgoingTransitionFromEntry.java +++ /dev/null @@ -1,551 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {e})
- *         pattern noOutgoingTransitionFromEntry(e : Entry) {
- *         	neg find transition(_, e, _);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class NoOutgoingTransitionFromEntry extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Entry fE; - - private static List parameterNames = makeImmutableList("e"); - - private Match(final Entry pE) { - this.fE = pE; - } - - @Override - public Object get(final String parameterName) { - if ("e".equals(parameterName)) return this.fE; - return null; - } - - public Entry getE() { - return this.fE; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("e".equals(parameterName) ) { - this.fE = (Entry) newValue; - return true; - } - return false; - } - - public void setE(final Entry pE) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fE = pE; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry"; - } - - @Override - public List parameterNames() { - return NoOutgoingTransitionFromEntry.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fE}; - } - - @Override - public NoOutgoingTransitionFromEntry.Match toImmutable() { - return isMutable() ? newMatch(fE) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"e\"=" + prettyPrintValue(fE)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fE); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof NoOutgoingTransitionFromEntry.Match)) { - NoOutgoingTransitionFromEntry.Match other = (NoOutgoingTransitionFromEntry.Match) obj; - return Objects.equals(fE, other.fE); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public NoOutgoingTransitionFromEntry specification() { - return NoOutgoingTransitionFromEntry.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static NoOutgoingTransitionFromEntry.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static NoOutgoingTransitionFromEntry.Match newMutableMatch(final Entry pE) { - return new Mutable(pE); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public static NoOutgoingTransitionFromEntry.Match newMatch(final Entry pE) { - return new Immutable(pE); - } - - private static final class Mutable extends NoOutgoingTransitionFromEntry.Match { - Mutable(final Entry pE) { - super(pE); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends NoOutgoingTransitionFromEntry.Match { - Immutable(final Entry pE) { - super(pE); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {e})
-   * pattern noOutgoingTransitionFromEntry(e : Entry) {
-   * 	neg find transition(_, e, _);
-   * }
-   * 
- * - * @see Match - * @see NoOutgoingTransitionFromEntry - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static NoOutgoingTransitionFromEntry.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static NoOutgoingTransitionFromEntry.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_E = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoOutgoingTransitionFromEntry.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Entry pE) { - return rawStreamAllMatches(new Object[]{pE}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Entry pE) { - return rawStreamAllMatches(new Object[]{pE}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Entry pE) { - return rawGetOneArbitraryMatch(new Object[]{pE}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Entry pE) { - return rawHasMatch(new Object[]{pE}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Entry pE) { - return rawCountMatches(new Object[]{pE}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Entry pE, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pE}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public NoOutgoingTransitionFromEntry.Match newMatch(final Entry pE) { - return NoOutgoingTransitionFromEntry.Match.newMatch(pE); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfe(final Object[] parameters) { - return rawStreamAllValues(POSITION_E, parameters).map(Entry.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()); - } - - @Override - protected NoOutgoingTransitionFromEntry.Match tupleToMatch(final Tuple t) { - try { - return NoOutgoingTransitionFromEntry.Match.newMatch((Entry) t.get(POSITION_E)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected NoOutgoingTransitionFromEntry.Match arrayToMatch(final Object[] match) { - try { - return NoOutgoingTransitionFromEntry.Match.newMatch((Entry) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected NoOutgoingTransitionFromEntry.Match arrayToMatchMutable(final Object[] match) { - try { - return NoOutgoingTransitionFromEntry.Match.newMutableMatch((Entry) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return NoOutgoingTransitionFromEntry.instance(); - } - } - - private NoOutgoingTransitionFromEntry() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static NoOutgoingTransitionFromEntry instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected NoOutgoingTransitionFromEntry.Matcher instantiate(final ViatraQueryEngine engine) { - return NoOutgoingTransitionFromEntry.Matcher.on(engine); - } - - @Override - public NoOutgoingTransitionFromEntry.Matcher instantiate() { - return NoOutgoingTransitionFromEntry.Matcher.create(); - } - - @Override - public NoOutgoingTransitionFromEntry.Match newEmptyMatch() { - return NoOutgoingTransitionFromEntry.Match.newEmptyMatch(); - } - - @Override - public NoOutgoingTransitionFromEntry.Match newMatch(final Object... parameters) { - return NoOutgoingTransitionFromEntry.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry (visibility: PUBLIC, simpleName: NoOutgoingTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry (visibility: PUBLIC, simpleName: NoOutgoingTransitionFromEntry, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoOutgoingTransitionFromEntry, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static NoOutgoingTransitionFromEntry INSTANCE = new NoOutgoingTransitionFromEntry(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static NoOutgoingTransitionFromEntry.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Entry")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_e); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noOutgoingTransitionFromEntry"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("e"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_e = body.getOrCreateVariableByName("e"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Entry"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_e, parameter_e) - )); - // neg find transition(_, e, _) - new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_e, var___1_), Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("e") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java deleted file mode 100644 index 841339ae..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NoStateInRegion.java +++ /dev/null @@ -1,558 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // State vs Region
- *         /////////
- *         
- *         {@literal @}Constraint(severity="error", message="error", key = {region})
- *         pattern noStateInRegion(region: Region) {
- *         	neg find StateInRegion(region,_);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class NoStateInRegion extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Region fRegion; - - private static List parameterNames = makeImmutableList("region"); - - private Match(final Region pRegion) { - this.fRegion = pRegion; - } - - @Override - public Object get(final String parameterName) { - if ("region".equals(parameterName)) return this.fRegion; - return null; - } - - public Region getRegion() { - return this.fRegion; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("region".equals(parameterName) ) { - this.fRegion = (Region) newValue; - return true; - } - return false; - } - - public void setRegion(final Region pRegion) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fRegion = pRegion; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion"; - } - - @Override - public List parameterNames() { - return NoStateInRegion.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fRegion}; - } - - @Override - public NoStateInRegion.Match toImmutable() { - return isMutable() ? newMatch(fRegion) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"region\"=" + prettyPrintValue(fRegion)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fRegion); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof NoStateInRegion.Match)) { - NoStateInRegion.Match other = (NoStateInRegion.Match) obj; - return Objects.equals(fRegion, other.fRegion); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public NoStateInRegion specification() { - return NoStateInRegion.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static NoStateInRegion.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static NoStateInRegion.Match newMutableMatch(final Region pRegion) { - return new Mutable(pRegion); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return the (partial) match object. - * - */ - public static NoStateInRegion.Match newMatch(final Region pRegion) { - return new Immutable(pRegion); - } - - private static final class Mutable extends NoStateInRegion.Match { - Mutable(final Region pRegion) { - super(pRegion); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends NoStateInRegion.Match { - Immutable(final Region pRegion) { - super(pRegion); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // State vs Region
-   * /////////
-   * 
-   * {@literal @}Constraint(severity="error", message="error", key = {region})
-   * pattern noStateInRegion(region: Region) {
-   * 	neg find StateInRegion(region,_);
-   * }
-   * 
- * - * @see Match - * @see NoStateInRegion - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static NoStateInRegion.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static NoStateInRegion.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_REGION = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NoStateInRegion.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Region pRegion) { - return rawStreamAllMatches(new Object[]{pRegion}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Region pRegion) { - return rawStreamAllMatches(new Object[]{pRegion}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Region pRegion) { - return rawGetOneArbitraryMatch(new Object[]{pRegion}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Region pRegion) { - return rawHasMatch(new Object[]{pRegion}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Region pRegion) { - return rawCountMatches(new Object[]{pRegion}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Region pRegion, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pRegion}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @return the (partial) match object. - * - */ - public NoStateInRegion.Match newMatch(final Region pRegion) { - return NoStateInRegion.Match.newMatch(pRegion); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfregion(final Object[] parameters) { - return rawStreamAllValues(POSITION_REGION, parameters).map(Region.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfregion() { - return rawStreamAllValuesOfregion(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfregion() { - return rawStreamAllValuesOfregion(emptyArray()); - } - - @Override - protected NoStateInRegion.Match tupleToMatch(final Tuple t) { - try { - return NoStateInRegion.Match.newMatch((Region) t.get(POSITION_REGION)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected NoStateInRegion.Match arrayToMatch(final Object[] match) { - try { - return NoStateInRegion.Match.newMatch((Region) match[POSITION_REGION]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected NoStateInRegion.Match arrayToMatchMutable(final Object[] match) { - try { - return NoStateInRegion.Match.newMutableMatch((Region) match[POSITION_REGION]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return NoStateInRegion.instance(); - } - } - - private NoStateInRegion() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static NoStateInRegion instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected NoStateInRegion.Matcher instantiate(final ViatraQueryEngine engine) { - return NoStateInRegion.Matcher.on(engine); - } - - @Override - public NoStateInRegion.Matcher instantiate() { - return NoStateInRegion.Matcher.create(); - } - - @Override - public NoStateInRegion.Match newEmptyMatch() { - return NoStateInRegion.Match.newEmptyMatch(); - } - - @Override - public NoStateInRegion.Match newMatch(final Object... parameters) { - return NoStateInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion (visibility: PUBLIC, simpleName: NoStateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion (visibility: PUBLIC, simpleName: NoStateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NoStateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static NoStateInRegion INSTANCE = new NoStateInRegion(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static NoStateInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_region = new PParameter("region", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_region); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.noStateInRegion"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("region"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_region = body.getOrCreateVariableByName("region"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_region, parameter_region) - )); - // neg find StateInRegion(region,_) - new NegativePatternCall(body, Tuples.flatTupleOf(var_region, var___0_), StateInRegion.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("region") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java deleted file mode 100644 index b9a60ca9..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/NotSynchronizingStates.java +++ /dev/null @@ -1,554 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleIncomingTrainsition; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleOutgoingTrainsition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern notSynchronizingStates(s : Synchronization) {
- *         	neg find hasMultipleOutgoingTrainsition(s);
- *         	neg find hasMultipleIncomingTrainsition(s);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class NotSynchronizingStates extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private static List parameterNames = makeImmutableList("s"); - - private Match(final Synchronization pS) { - this.fS = pS; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates"; - } - - @Override - public List parameterNames() { - return NotSynchronizingStates.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS}; - } - - @Override - public NotSynchronizingStates.Match toImmutable() { - return isMutable() ? newMatch(fS) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof NotSynchronizingStates.Match)) { - NotSynchronizingStates.Match other = (NotSynchronizingStates.Match) obj; - return Objects.equals(fS, other.fS); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public NotSynchronizingStates specification() { - return NotSynchronizingStates.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static NotSynchronizingStates.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static NotSynchronizingStates.Match newMutableMatch(final Synchronization pS) { - return new Mutable(pS); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public static NotSynchronizingStates.Match newMatch(final Synchronization pS) { - return new Immutable(pS); - } - - private static final class Mutable extends NotSynchronizingStates.Match { - Mutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends NotSynchronizingStates.Match { - Immutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern notSynchronizingStates(s : Synchronization) {
-   * 	neg find hasMultipleOutgoingTrainsition(s);
-   * 	neg find hasMultipleIncomingTrainsition(s);
-   * }
-   * 
- * - * @see Match - * @see NotSynchronizingStates - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static NotSynchronizingStates.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static NotSynchronizingStates.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(NotSynchronizingStates.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS) { - return rawGetOneArbitraryMatch(new Object[]{pS}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS) { - return rawHasMatch(new Object[]{pS}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS) { - return rawCountMatches(new Object[]{pS}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public NotSynchronizingStates.Match newMatch(final Synchronization pS) { - return NotSynchronizingStates.Match.newMatch(pS); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - @Override - protected NotSynchronizingStates.Match tupleToMatch(final Tuple t) { - try { - return NotSynchronizingStates.Match.newMatch((Synchronization) t.get(POSITION_S)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected NotSynchronizingStates.Match arrayToMatch(final Object[] match) { - try { - return NotSynchronizingStates.Match.newMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected NotSynchronizingStates.Match arrayToMatchMutable(final Object[] match) { - try { - return NotSynchronizingStates.Match.newMutableMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return NotSynchronizingStates.instance(); - } - } - - private NotSynchronizingStates() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static NotSynchronizingStates instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected NotSynchronizingStates.Matcher instantiate(final ViatraQueryEngine engine) { - return NotSynchronizingStates.Matcher.on(engine); - } - - @Override - public NotSynchronizingStates.Matcher instantiate() { - return NotSynchronizingStates.Matcher.create(); - } - - @Override - public NotSynchronizingStates.Match newEmptyMatch() { - return NotSynchronizingStates.Match.newEmptyMatch(); - } - - @Override - public NotSynchronizingStates.Match newMatch(final Object... parameters) { - return NotSynchronizingStates.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates (visibility: PUBLIC, simpleName: NotSynchronizingStates, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates (visibility: PUBLIC, simpleName: NotSynchronizingStates, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.NotSynchronizingStates, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static NotSynchronizingStates INSTANCE = new NotSynchronizingStates(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static NotSynchronizingStates.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.notSynchronizingStates"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s) - )); - // neg find hasMultipleOutgoingTrainsition(s) - new NegativePatternCall(body, Tuples.flatTupleOf(var_s), HasMultipleOutgoingTrainsition.instance().getInternalQueryRepresentation()); - // neg find hasMultipleIncomingTrainsition(s) - new NegativePatternCall(body, Tuples.flatTupleOf(var_s), HasMultipleIncomingTrainsition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java deleted file mode 100644 index 10f0e056..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromExit.java +++ /dev/null @@ -1,715 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // Exit
- *         /////////
- *         
- *         {@literal @}Constraint(severity="error", message="error", key = {e})
- *         pattern outgoingFromExit(t : Transition, e : Exit) {
- *         	Exit.outgoingTransitions(e,t);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class OutgoingFromExit extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Transition fT; - - private Exit fE; - - private static List parameterNames = makeImmutableList("t", "e"); - - private Match(final Transition pT, final Exit pE) { - this.fT = pT; - this.fE = pE; - } - - @Override - public Object get(final String parameterName) { - if ("t".equals(parameterName)) return this.fT; - if ("e".equals(parameterName)) return this.fE; - return null; - } - - public Transition getT() { - return this.fT; - } - - public Exit getE() { - return this.fE; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("t".equals(parameterName) ) { - this.fT = (Transition) newValue; - return true; - } - if ("e".equals(parameterName) ) { - this.fE = (Exit) newValue; - return true; - } - return false; - } - - public void setT(final Transition pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setE(final Exit pE) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fE = pE; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit"; - } - - @Override - public List parameterNames() { - return OutgoingFromExit.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fE}; - } - - @Override - public OutgoingFromExit.Match toImmutable() { - return isMutable() ? newMatch(fT, fE) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"t\"=" + prettyPrintValue(fT) + ", "); - result.append("\"e\"=" + prettyPrintValue(fE)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fE); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof OutgoingFromExit.Match)) { - OutgoingFromExit.Match other = (OutgoingFromExit.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fE, other.fE); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public OutgoingFromExit specification() { - return OutgoingFromExit.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static OutgoingFromExit.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static OutgoingFromExit.Match newMutableMatch(final Transition pT, final Exit pE) { - return new Mutable(pT, pE); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public static OutgoingFromExit.Match newMatch(final Transition pT, final Exit pE) { - return new Immutable(pT, pE); - } - - private static final class Mutable extends OutgoingFromExit.Match { - Mutable(final Transition pT, final Exit pE) { - super(pT, pE); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends OutgoingFromExit.Match { - Immutable(final Transition pT, final Exit pE) { - super(pT, pE); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // Exit
-   * /////////
-   * 
-   * {@literal @}Constraint(severity="error", message="error", key = {e})
-   * pattern outgoingFromExit(t : Transition, e : Exit) {
-   * 	Exit.outgoingTransitions(e,t);
-   * }
-   * 
- * - * @see Match - * @see OutgoingFromExit - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static OutgoingFromExit.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static OutgoingFromExit.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_E = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(OutgoingFromExit.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Transition pT, final Exit pE) { - return rawStreamAllMatches(new Object[]{pT, pE}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Transition pT, final Exit pE) { - return rawStreamAllMatches(new Object[]{pT, pE}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Transition pT, final Exit pE) { - return rawGetOneArbitraryMatch(new Object[]{pT, pE}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Transition pT, final Exit pE) { - return rawHasMatch(new Object[]{pT, pE}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Transition pT, final Exit pE) { - return rawCountMatches(new Object[]{pT, pE}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Transition pT, final Exit pE, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pE}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pE the fixed value of pattern parameter e, or null if not bound. - * @return the (partial) match object. - * - */ - public OutgoingFromExit.Match newMatch(final Transition pT, final Exit pE) { - return OutgoingFromExit.Match.newMatch(pT, pE); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final OutgoingFromExit.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final Exit pE) { - return rawStreamAllValuesOft(new Object[]{null, pE}); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final OutgoingFromExit.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final Exit pE) { - return rawStreamAllValuesOft(new Object[]{null, pE}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfe(final Object[] parameters) { - return rawStreamAllValues(POSITION_E, parameters).map(Exit.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe() { - return rawStreamAllValuesOfe(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final OutgoingFromExit.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for e. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfe(final Transition pT) { - return rawStreamAllValuesOfe(new Object[]{pT, null}); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final OutgoingFromExit.Match partialMatch) { - return rawStreamAllValuesOfe(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for e. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfe(final Transition pT) { - return rawStreamAllValuesOfe(new Object[]{pT, null}).collect(Collectors.toSet()); - } - - @Override - protected OutgoingFromExit.Match tupleToMatch(final Tuple t) { - try { - return OutgoingFromExit.Match.newMatch((Transition) t.get(POSITION_T), (Exit) t.get(POSITION_E)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected OutgoingFromExit.Match arrayToMatch(final Object[] match) { - try { - return OutgoingFromExit.Match.newMatch((Transition) match[POSITION_T], (Exit) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected OutgoingFromExit.Match arrayToMatchMutable(final Object[] match) { - try { - return OutgoingFromExit.Match.newMutableMatch((Transition) match[POSITION_T], (Exit) match[POSITION_E]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return OutgoingFromExit.instance(); - } - } - - private OutgoingFromExit() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static OutgoingFromExit instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected OutgoingFromExit.Matcher instantiate(final ViatraQueryEngine engine) { - return OutgoingFromExit.Matcher.on(engine); - } - - @Override - public OutgoingFromExit.Matcher instantiate() { - return OutgoingFromExit.Matcher.create(); - } - - @Override - public OutgoingFromExit.Match newEmptyMatch() { - return OutgoingFromExit.Match.newEmptyMatch(); - } - - @Override - public OutgoingFromExit.Match newMatch(final Object... parameters) { - return OutgoingFromExit.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit (visibility: PUBLIC, simpleName: OutgoingFromExit, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit (visibility: PUBLIC, simpleName: OutgoingFromExit, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromExit, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static OutgoingFromExit INSTANCE = new OutgoingFromExit(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static OutgoingFromExit.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final PParameter parameter_e = new PParameter("e", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Exit")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_t, parameter_e); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromExit"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("t","e"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_t = body.getOrCreateVariableByName("t"); - PVariable var_e = body.getOrCreateVariableByName("e"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Exit"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_t, parameter_t), - new ExportedParameter(body, var_e, parameter_e) - )); - // Exit.outgoingTransitions(e,t) - new TypeConstraint(body, Tuples.flatTupleOf(var_e), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Exit"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_e, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new Equality(body, var__virtual_0_, var_t); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("e") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java deleted file mode 100644 index fbac352b..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/OutgoingFromFinal.java +++ /dev/null @@ -1,715 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // Final
- *         /////////
- *         
- *         {@literal @}Constraint(severity="error", message="error", key = {f})
- *         pattern outgoingFromFinal(t : Transition, f : FinalState) {
- *         	FinalState.outgoingTransitions(f,t);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class OutgoingFromFinal extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Transition fT; - - private FinalState fF; - - private static List parameterNames = makeImmutableList("t", "f"); - - private Match(final Transition pT, final FinalState pF) { - this.fT = pT; - this.fF = pF; - } - - @Override - public Object get(final String parameterName) { - if ("t".equals(parameterName)) return this.fT; - if ("f".equals(parameterName)) return this.fF; - return null; - } - - public Transition getT() { - return this.fT; - } - - public FinalState getF() { - return this.fF; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("t".equals(parameterName) ) { - this.fT = (Transition) newValue; - return true; - } - if ("f".equals(parameterName) ) { - this.fF = (FinalState) newValue; - return true; - } - return false; - } - - public void setT(final Transition pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setF(final FinalState pF) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fF = pF; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal"; - } - - @Override - public List parameterNames() { - return OutgoingFromFinal.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fF}; - } - - @Override - public OutgoingFromFinal.Match toImmutable() { - return isMutable() ? newMatch(fT, fF) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"t\"=" + prettyPrintValue(fT) + ", "); - result.append("\"f\"=" + prettyPrintValue(fF)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fF); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof OutgoingFromFinal.Match)) { - OutgoingFromFinal.Match other = (OutgoingFromFinal.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fF, other.fF); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public OutgoingFromFinal specification() { - return OutgoingFromFinal.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static OutgoingFromFinal.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static OutgoingFromFinal.Match newMutableMatch(final Transition pT, final FinalState pF) { - return new Mutable(pT, pF); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return the (partial) match object. - * - */ - public static OutgoingFromFinal.Match newMatch(final Transition pT, final FinalState pF) { - return new Immutable(pT, pF); - } - - private static final class Mutable extends OutgoingFromFinal.Match { - Mutable(final Transition pT, final FinalState pF) { - super(pT, pF); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends OutgoingFromFinal.Match { - Immutable(final Transition pT, final FinalState pF) { - super(pT, pF); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // Final
-   * /////////
-   * 
-   * {@literal @}Constraint(severity="error", message="error", key = {f})
-   * pattern outgoingFromFinal(t : Transition, f : FinalState) {
-   * 	FinalState.outgoingTransitions(f,t);
-   * }
-   * 
- * - * @see Match - * @see OutgoingFromFinal - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static OutgoingFromFinal.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static OutgoingFromFinal.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_F = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(OutgoingFromFinal.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Transition pT, final FinalState pF) { - return rawStreamAllMatches(new Object[]{pT, pF}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Transition pT, final FinalState pF) { - return rawStreamAllMatches(new Object[]{pT, pF}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Transition pT, final FinalState pF) { - return rawGetOneArbitraryMatch(new Object[]{pT, pF}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Transition pT, final FinalState pF) { - return rawHasMatch(new Object[]{pT, pF}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Transition pT, final FinalState pF) { - return rawCountMatches(new Object[]{pT, pF}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Transition pT, final FinalState pF, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pF}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pF the fixed value of pattern parameter f, or null if not bound. - * @return the (partial) match object. - * - */ - public OutgoingFromFinal.Match newMatch(final Transition pT, final FinalState pF) { - return OutgoingFromFinal.Match.newMatch(pT, pF); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final OutgoingFromFinal.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final FinalState pF) { - return rawStreamAllValuesOft(new Object[]{null, pF}); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final OutgoingFromFinal.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final FinalState pF) { - return rawStreamAllValuesOft(new Object[]{null, pF}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for f. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOff(final Object[] parameters) { - return rawStreamAllValues(POSITION_F, parameters).map(FinalState.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for f. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOff() { - return rawStreamAllValuesOff(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for f. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOff() { - return rawStreamAllValuesOff(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for f. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOff(final OutgoingFromFinal.Match partialMatch) { - return rawStreamAllValuesOff(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for f. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOff(final Transition pT) { - return rawStreamAllValuesOff(new Object[]{pT, null}); - } - - /** - * Retrieve the set of values that occur in matches for f. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOff(final OutgoingFromFinal.Match partialMatch) { - return rawStreamAllValuesOff(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for f. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOff(final Transition pT) { - return rawStreamAllValuesOff(new Object[]{pT, null}).collect(Collectors.toSet()); - } - - @Override - protected OutgoingFromFinal.Match tupleToMatch(final Tuple t) { - try { - return OutgoingFromFinal.Match.newMatch((Transition) t.get(POSITION_T), (FinalState) t.get(POSITION_F)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected OutgoingFromFinal.Match arrayToMatch(final Object[] match) { - try { - return OutgoingFromFinal.Match.newMatch((Transition) match[POSITION_T], (FinalState) match[POSITION_F]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected OutgoingFromFinal.Match arrayToMatchMutable(final Object[] match) { - try { - return OutgoingFromFinal.Match.newMutableMatch((Transition) match[POSITION_T], (FinalState) match[POSITION_F]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return OutgoingFromFinal.instance(); - } - } - - private OutgoingFromFinal() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static OutgoingFromFinal instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected OutgoingFromFinal.Matcher instantiate(final ViatraQueryEngine engine) { - return OutgoingFromFinal.Matcher.on(engine); - } - - @Override - public OutgoingFromFinal.Matcher instantiate() { - return OutgoingFromFinal.Matcher.create(); - } - - @Override - public OutgoingFromFinal.Match newEmptyMatch() { - return OutgoingFromFinal.Match.newEmptyMatch(); - } - - @Override - public OutgoingFromFinal.Match newMatch(final Object... parameters) { - return OutgoingFromFinal.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal (visibility: PUBLIC, simpleName: OutgoingFromFinal, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal (visibility: PUBLIC, simpleName: OutgoingFromFinal, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.OutgoingFromFinal, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static OutgoingFromFinal INSTANCE = new OutgoingFromFinal(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static OutgoingFromFinal.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final PParameter parameter_f = new PParameter("f", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "FinalState")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_t, parameter_f); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.outgoingFromFinal"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("t","f"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_t = body.getOrCreateVariableByName("t"); - PVariable var_f = body.getOrCreateVariableByName("f"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_f), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "FinalState"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_t, parameter_t), - new ExportedParameter(body, var_f, parameter_f) - )); - // FinalState.outgoingTransitions(f,t) - new TypeConstraint(body, Tuples.flatTupleOf(var_f), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "FinalState"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_f, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Vertex", "outgoingTransitions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new Equality(body, var__virtual_0_, var_t); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("f") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java deleted file mode 100644 index 0d1fd0e6..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/StateInRegion.java +++ /dev/null @@ -1,694 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern StateInRegion(region: Region, state: State) {
- *         	Region.vertices(region,state);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class StateInRegion extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Region fRegion; - - private State fState; - - private static List parameterNames = makeImmutableList("region", "state"); - - private Match(final Region pRegion, final State pState) { - this.fRegion = pRegion; - this.fState = pState; - } - - @Override - public Object get(final String parameterName) { - if ("region".equals(parameterName)) return this.fRegion; - if ("state".equals(parameterName)) return this.fState; - return null; - } - - public Region getRegion() { - return this.fRegion; - } - - public State getState() { - return this.fState; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("region".equals(parameterName) ) { - this.fRegion = (Region) newValue; - return true; - } - if ("state".equals(parameterName) ) { - this.fState = (State) newValue; - return true; - } - return false; - } - - public void setRegion(final Region pRegion) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fRegion = pRegion; - } - - public void setState(final State pState) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fState = pState; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion"; - } - - @Override - public List parameterNames() { - return StateInRegion.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fRegion, fState}; - } - - @Override - public StateInRegion.Match toImmutable() { - return isMutable() ? newMatch(fRegion, fState) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"region\"=" + prettyPrintValue(fRegion) + ", "); - result.append("\"state\"=" + prettyPrintValue(fState)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fRegion, fState); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof StateInRegion.Match)) { - StateInRegion.Match other = (StateInRegion.Match) obj; - return Objects.equals(fRegion, other.fRegion) && Objects.equals(fState, other.fState); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public StateInRegion specification() { - return StateInRegion.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static StateInRegion.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static StateInRegion.Match newMutableMatch(final Region pRegion, final State pState) { - return new Mutable(pRegion, pState); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return the (partial) match object. - * - */ - public static StateInRegion.Match newMatch(final Region pRegion, final State pState) { - return new Immutable(pRegion, pState); - } - - private static final class Mutable extends StateInRegion.Match { - Mutable(final Region pRegion, final State pState) { - super(pRegion, pState); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends StateInRegion.Match { - Immutable(final Region pRegion, final State pState) { - super(pRegion, pState); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern StateInRegion(region: Region, state: State) {
-   * 	Region.vertices(region,state);
-   * }
-   * 
- * - * @see Match - * @see StateInRegion - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static StateInRegion.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static StateInRegion.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_REGION = 0; - - private final static int POSITION_STATE = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(StateInRegion.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Region pRegion, final State pState) { - return rawStreamAllMatches(new Object[]{pRegion, pState}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Region pRegion, final State pState) { - return rawStreamAllMatches(new Object[]{pRegion, pState}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Region pRegion, final State pState) { - return rawGetOneArbitraryMatch(new Object[]{pRegion, pState}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Region pRegion, final State pState) { - return rawHasMatch(new Object[]{pRegion, pState}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Region pRegion, final State pState) { - return rawCountMatches(new Object[]{pRegion, pState}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Region pRegion, final State pState, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pRegion, pState}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pRegion the fixed value of pattern parameter region, or null if not bound. - * @param pState the fixed value of pattern parameter state, or null if not bound. - * @return the (partial) match object. - * - */ - public StateInRegion.Match newMatch(final Region pRegion, final State pState) { - return StateInRegion.Match.newMatch(pRegion, pState); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfregion(final Object[] parameters) { - return rawStreamAllValues(POSITION_REGION, parameters).map(Region.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfregion() { - return rawStreamAllValuesOfregion(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfregion() { - return rawStreamAllValuesOfregion(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for region. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfregion(final StateInRegion.Match partialMatch) { - return rawStreamAllValuesOfregion(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for region. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfregion(final State pState) { - return rawStreamAllValuesOfregion(new Object[]{null, pState}); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfregion(final StateInRegion.Match partialMatch) { - return rawStreamAllValuesOfregion(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for region. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfregion(final State pState) { - return rawStreamAllValuesOfregion(new Object[]{null, pState}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for state. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfstate(final Object[] parameters) { - return rawStreamAllValues(POSITION_STATE, parameters).map(State.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for state. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfstate() { - return rawStreamAllValuesOfstate(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for state. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfstate() { - return rawStreamAllValuesOfstate(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for state. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfstate(final StateInRegion.Match partialMatch) { - return rawStreamAllValuesOfstate(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for state. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfstate(final Region pRegion) { - return rawStreamAllValuesOfstate(new Object[]{pRegion, null}); - } - - /** - * Retrieve the set of values that occur in matches for state. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfstate(final StateInRegion.Match partialMatch) { - return rawStreamAllValuesOfstate(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for state. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfstate(final Region pRegion) { - return rawStreamAllValuesOfstate(new Object[]{pRegion, null}).collect(Collectors.toSet()); - } - - @Override - protected StateInRegion.Match tupleToMatch(final Tuple t) { - try { - return StateInRegion.Match.newMatch((Region) t.get(POSITION_REGION), (State) t.get(POSITION_STATE)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected StateInRegion.Match arrayToMatch(final Object[] match) { - try { - return StateInRegion.Match.newMatch((Region) match[POSITION_REGION], (State) match[POSITION_STATE]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected StateInRegion.Match arrayToMatchMutable(final Object[] match) { - try { - return StateInRegion.Match.newMutableMatch((Region) match[POSITION_REGION], (State) match[POSITION_STATE]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return StateInRegion.instance(); - } - } - - private StateInRegion() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static StateInRegion instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected StateInRegion.Matcher instantiate(final ViatraQueryEngine engine) { - return StateInRegion.Matcher.on(engine); - } - - @Override - public StateInRegion.Matcher instantiate() { - return StateInRegion.Matcher.create(); - } - - @Override - public StateInRegion.Match newEmptyMatch() { - return StateInRegion.Match.newEmptyMatch(); - } - - @Override - public StateInRegion.Match newMatch(final Object... parameters) { - return StateInRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion (visibility: PUBLIC, simpleName: StateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion (visibility: PUBLIC, simpleName: StateInRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static StateInRegion INSTANCE = new StateInRegion(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static StateInRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_region = new PParameter("region", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Region")), PParameterDirection.INOUT); - - private final PParameter parameter_state = new PParameter("state", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "State")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_region, parameter_state); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.StateInRegion"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("region","state"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_region = body.getOrCreateVariableByName("region"); - PVariable var_state = body.getOrCreateVariableByName("state"); - new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_state), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "State"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_region, parameter_region), - new ExportedParameter(body, var_state, parameter_state) - )); - // Region.vertices(region,state) - new TypeConstraint(body, Tuples.flatTupleOf(var_region), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_region, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_state); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java deleted file mode 100644 index d59ab2d9..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoIncoming.java +++ /dev/null @@ -1,551 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern synchHasNoIncoming(s : Synchronization) {
- *         	neg find transition(_, _, s);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchHasNoIncoming extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private static List parameterNames = makeImmutableList("s"); - - private Match(final Synchronization pS) { - this.fS = pS; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming"; - } - - @Override - public List parameterNames() { - return SynchHasNoIncoming.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS}; - } - - @Override - public SynchHasNoIncoming.Match toImmutable() { - return isMutable() ? newMatch(fS) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchHasNoIncoming.Match)) { - SynchHasNoIncoming.Match other = (SynchHasNoIncoming.Match) obj; - return Objects.equals(fS, other.fS); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchHasNoIncoming specification() { - return SynchHasNoIncoming.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchHasNoIncoming.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchHasNoIncoming.Match newMutableMatch(final Synchronization pS) { - return new Mutable(pS); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchHasNoIncoming.Match newMatch(final Synchronization pS) { - return new Immutable(pS); - } - - private static final class Mutable extends SynchHasNoIncoming.Match { - Mutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchHasNoIncoming.Match { - Immutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern synchHasNoIncoming(s : Synchronization) {
-   * 	neg find transition(_, _, s);
-   * }
-   * 
- * - * @see Match - * @see SynchHasNoIncoming - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchHasNoIncoming.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchHasNoIncoming.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchHasNoIncoming.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS) { - return rawGetOneArbitraryMatch(new Object[]{pS}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS) { - return rawHasMatch(new Object[]{pS}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS) { - return rawCountMatches(new Object[]{pS}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchHasNoIncoming.Match newMatch(final Synchronization pS) { - return SynchHasNoIncoming.Match.newMatch(pS); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - @Override - protected SynchHasNoIncoming.Match tupleToMatch(final Tuple t) { - try { - return SynchHasNoIncoming.Match.newMatch((Synchronization) t.get(POSITION_S)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchHasNoIncoming.Match arrayToMatch(final Object[] match) { - try { - return SynchHasNoIncoming.Match.newMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchHasNoIncoming.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchHasNoIncoming.Match.newMutableMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchHasNoIncoming.instance(); - } - } - - private SynchHasNoIncoming() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchHasNoIncoming instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchHasNoIncoming.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchHasNoIncoming.Matcher.on(engine); - } - - @Override - public SynchHasNoIncoming.Matcher instantiate() { - return SynchHasNoIncoming.Matcher.create(); - } - - @Override - public SynchHasNoIncoming.Match newEmptyMatch() { - return SynchHasNoIncoming.Match.newEmptyMatch(); - } - - @Override - public SynchHasNoIncoming.Match newMatch(final Object... parameters) { - return SynchHasNoIncoming.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming (visibility: PUBLIC, simpleName: SynchHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming (visibility: PUBLIC, simpleName: SynchHasNoIncoming, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoIncoming, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchHasNoIncoming INSTANCE = new SynchHasNoIncoming(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchHasNoIncoming.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoIncoming"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s) - )); - // neg find transition(_, _, s) - new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var___1_, var_s), Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java deleted file mode 100644 index e3ff69bd..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchHasNoOutgoing.java +++ /dev/null @@ -1,559 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         /////////
- *         // Synchronization
- *         /////////
- *         
- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern synchHasNoOutgoing(s : Synchronization) {
- *         	neg find transition(_, s, _);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchHasNoOutgoing extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private static List parameterNames = makeImmutableList("s"); - - private Match(final Synchronization pS) { - this.fS = pS; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing"; - } - - @Override - public List parameterNames() { - return SynchHasNoOutgoing.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS}; - } - - @Override - public SynchHasNoOutgoing.Match toImmutable() { - return isMutable() ? newMatch(fS) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchHasNoOutgoing.Match)) { - SynchHasNoOutgoing.Match other = (SynchHasNoOutgoing.Match) obj; - return Objects.equals(fS, other.fS); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchHasNoOutgoing specification() { - return SynchHasNoOutgoing.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchHasNoOutgoing.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchHasNoOutgoing.Match newMutableMatch(final Synchronization pS) { - return new Mutable(pS); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchHasNoOutgoing.Match newMatch(final Synchronization pS) { - return new Immutable(pS); - } - - private static final class Mutable extends SynchHasNoOutgoing.Match { - Mutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchHasNoOutgoing.Match { - Immutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * /////////
-   * // Synchronization
-   * /////////
-   * 
-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern synchHasNoOutgoing(s : Synchronization) {
-   * 	neg find transition(_, s, _);
-   * }
-   * 
- * - * @see Match - * @see SynchHasNoOutgoing - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchHasNoOutgoing.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchHasNoOutgoing.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchHasNoOutgoing.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS) { - return rawGetOneArbitraryMatch(new Object[]{pS}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS) { - return rawHasMatch(new Object[]{pS}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS) { - return rawCountMatches(new Object[]{pS}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchHasNoOutgoing.Match newMatch(final Synchronization pS) { - return SynchHasNoOutgoing.Match.newMatch(pS); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - @Override - protected SynchHasNoOutgoing.Match tupleToMatch(final Tuple t) { - try { - return SynchHasNoOutgoing.Match.newMatch((Synchronization) t.get(POSITION_S)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchHasNoOutgoing.Match arrayToMatch(final Object[] match) { - try { - return SynchHasNoOutgoing.Match.newMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchHasNoOutgoing.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchHasNoOutgoing.Match.newMutableMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchHasNoOutgoing.instance(); - } - } - - private SynchHasNoOutgoing() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchHasNoOutgoing instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchHasNoOutgoing.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchHasNoOutgoing.Matcher.on(engine); - } - - @Override - public SynchHasNoOutgoing.Matcher instantiate() { - return SynchHasNoOutgoing.Matcher.create(); - } - - @Override - public SynchHasNoOutgoing.Match newEmptyMatch() { - return SynchHasNoOutgoing.Match.newEmptyMatch(); - } - - @Override - public SynchHasNoOutgoing.Match newMatch(final Object... parameters) { - return SynchHasNoOutgoing.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing (visibility: PUBLIC, simpleName: SynchHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing (visibility: PUBLIC, simpleName: SynchHasNoOutgoing, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchHasNoOutgoing, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchHasNoOutgoing INSTANCE = new SynchHasNoOutgoing(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchHasNoOutgoing.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchHasNoOutgoing"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s) - )); - // neg find transition(_, s, _) - new NegativePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var___1_), Transition.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java deleted file mode 100644 index 228db3a0..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchThree.java +++ /dev/null @@ -1,639 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         Simplifying model generation
- *          
- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern synchThree(s: Synchronization) {
- *         	Transition.target(t1,s);
- *         	Transition.target(t2,s);
- *         	Transition.target(t3,s);
- *         	t1!=t2;
- *         	t2!=t3;
- *         	t1!=t3;
- *         } or {
- *         	Transition.source(t1,s);
- *         	Transition.source(t2,s);
- *         	Transition.source(t3,s);
- *         	t1!=t2;
- *         	t2!=t3;
- *         	t1!=t3;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchThree extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private static List parameterNames = makeImmutableList("s"); - - private Match(final Synchronization pS) { - this.fS = pS; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree"; - } - - @Override - public List parameterNames() { - return SynchThree.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS}; - } - - @Override - public SynchThree.Match toImmutable() { - return isMutable() ? newMatch(fS) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchThree.Match)) { - SynchThree.Match other = (SynchThree.Match) obj; - return Objects.equals(fS, other.fS); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchThree specification() { - return SynchThree.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchThree.Match newEmptyMatch() { - return new Mutable(null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchThree.Match newMutableMatch(final Synchronization pS) { - return new Mutable(pS); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchThree.Match newMatch(final Synchronization pS) { - return new Immutable(pS); - } - - private static final class Mutable extends SynchThree.Match { - Mutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchThree.Match { - Immutable(final Synchronization pS) { - super(pS); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * Simplifying model generation
-   *  
-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern synchThree(s: Synchronization) {
-   * 	Transition.target(t1,s);
-   * 	Transition.target(t2,s);
-   * 	Transition.target(t3,s);
-   * 	t1!=t2;
-   * 	t2!=t3;
-   * 	t1!=t3;
-   * } or {
-   * 	Transition.source(t1,s);
-   * 	Transition.source(t2,s);
-   * 	Transition.source(t3,s);
-   * 	t1!=t2;
-   * 	t2!=t3;
-   * 	t1!=t3;
-   * }
-   * 
- * - * @see Match - * @see SynchThree - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchThree.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchThree.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchThree.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS) { - return rawStreamAllMatches(new Object[]{pS}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS) { - return rawGetOneArbitraryMatch(new Object[]{pS}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS) { - return rawHasMatch(new Object[]{pS}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS) { - return rawCountMatches(new Object[]{pS}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchThree.Match newMatch(final Synchronization pS) { - return SynchThree.Match.newMatch(pS); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - @Override - protected SynchThree.Match tupleToMatch(final Tuple t) { - try { - return SynchThree.Match.newMatch((Synchronization) t.get(POSITION_S)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchThree.Match arrayToMatch(final Object[] match) { - try { - return SynchThree.Match.newMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchThree.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchThree.Match.newMutableMatch((Synchronization) match[POSITION_S]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchThree.instance(); - } - } - - private SynchThree() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchThree instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchThree.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchThree.Matcher.on(engine); - } - - @Override - public SynchThree.Matcher instantiate() { - return SynchThree.Matcher.create(); - } - - @Override - public SynchThree.Match newEmptyMatch() { - return SynchThree.Match.newEmptyMatch(); - } - - @Override - public SynchThree.Match newMatch(final Object... parameters) { - return SynchThree.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree (visibility: PUBLIC, simpleName: SynchThree, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree (visibility: PUBLIC, simpleName: SynchThree, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchThree, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchThree INSTANCE = new SynchThree(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchThree.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.synchThree"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_t1 = body.getOrCreateVariableByName("t1"); - PVariable var_t2 = body.getOrCreateVariableByName("t2"); - PVariable var_t3 = body.getOrCreateVariableByName("t3"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s) - )); - // Transition.target(t1,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_s); - // Transition.target(t2,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t2, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_s); - // Transition.target(t3,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t3), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t3, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_2_, var_s); - // t1!=t2 - new Inequality(body, var_t1, var_t2); - // t2!=t3 - new Inequality(body, var_t2, var_t3); - // t1!=t3 - new Inequality(body, var_t1, var_t3); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_t1 = body.getOrCreateVariableByName("t1"); - PVariable var_t2 = body.getOrCreateVariableByName("t2"); - PVariable var_t3 = body.getOrCreateVariableByName("t3"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s) - )); - // Transition.source(t1,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_s); - // Transition.source(t2,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t2, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_s); - // Transition.source(t3,s) - new TypeConstraint(body, Tuples.flatTupleOf(var_t3), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t3, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_2_, var_s); - // t1!=t2 - new Inequality(body, var_t1, var_t2); - // t2!=t3 - new Inequality(body, var_t2, var_t3); - // t1!=t3 - new Inequality(body, var_t1, var_t3); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java deleted file mode 100644 index dabbe8c5..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedIncomingInSameRegion.java +++ /dev/null @@ -1,888 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) {
- *         	find transition(t1, v1, s);
- *         	find transition(t2, v2, s);
- *         	t1!=t2;
- *         	Region.vertices(r, v1);
- *         	Region.vertices(r, v2);
- *         } or {
- *         	find transition(t1, s, v1);
- *         	find transition(t2, s, v2);
- *         	t1!=t2;
- *         	Region.vertices(r, v1);
- *         	Region.vertices(r, v2);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchronizedIncomingInSameRegion extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private Vertex fV1; - - private Vertex fV2; - - private static List parameterNames = makeImmutableList("s", "v1", "v2"); - - private Match(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - this.fS = pS; - this.fV1 = pV1; - this.fV2 = pV2; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - if ("v1".equals(parameterName)) return this.fV1; - if ("v2".equals(parameterName)) return this.fV2; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - public Vertex getV1() { - return this.fV1; - } - - public Vertex getV2() { - return this.fV2; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - if ("v1".equals(parameterName) ) { - this.fV1 = (Vertex) newValue; - return true; - } - if ("v2".equals(parameterName) ) { - this.fV2 = (Vertex) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - public void setV1(final Vertex pV1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV1 = pV1; - } - - public void setV2(final Vertex pV2) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV2 = pV2; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion"; - } - - @Override - public List parameterNames() { - return SynchronizedIncomingInSameRegion.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS, fV1, fV2}; - } - - @Override - public SynchronizedIncomingInSameRegion.Match toImmutable() { - return isMutable() ? newMatch(fS, fV1, fV2) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS) + ", "); - result.append("\"v1\"=" + prettyPrintValue(fV1) + ", "); - result.append("\"v2\"=" + prettyPrintValue(fV2)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS, fV1, fV2); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchronizedIncomingInSameRegion.Match)) { - SynchronizedIncomingInSameRegion.Match other = (SynchronizedIncomingInSameRegion.Match) obj; - return Objects.equals(fS, other.fS) && Objects.equals(fV1, other.fV1) && Objects.equals(fV2, other.fV2); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchronizedIncomingInSameRegion specification() { - return SynchronizedIncomingInSameRegion.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchronizedIncomingInSameRegion.Match newEmptyMatch() { - return new Mutable(null, null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchronizedIncomingInSameRegion.Match newMutableMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return new Mutable(pS, pV1, pV2); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchronizedIncomingInSameRegion.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return new Immutable(pS, pV1, pV2); - } - - private static final class Mutable extends SynchronizedIncomingInSameRegion.Match { - Mutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - super(pS, pV1, pV2); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchronizedIncomingInSameRegion.Match { - Immutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - super(pS, pV1, pV2); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) {
-   * 	find transition(t1, v1, s);
-   * 	find transition(t2, v2, s);
-   * 	t1!=t2;
-   * 	Region.vertices(r, v1);
-   * 	Region.vertices(r, v2);
-   * } or {
-   * 	find transition(t1, s, v1);
-   * 	find transition(t2, s, v2);
-   * 	t1!=t2;
-   * 	Region.vertices(r, v1);
-   * 	Region.vertices(r, v2);
-   * }
-   * 
- * - * @see Match - * @see SynchronizedIncomingInSameRegion - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchronizedIncomingInSameRegion.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchronizedIncomingInSameRegion.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static int POSITION_V1 = 1; - - private final static int POSITION_V2 = 2; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedIncomingInSameRegion.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawStreamAllMatches(new Object[]{pS, pV1, pV2}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawStreamAllMatches(new Object[]{pS, pV1, pV2}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawGetOneArbitraryMatch(new Object[]{pS, pV1, pV2}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawHasMatch(new Object[]{pS, pV1, pV2}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawCountMatches(new Object[]{pS, pV1, pV2}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS, pV1, pV2}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchronizedIncomingInSameRegion.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return SynchronizedIncomingInSameRegion.Match.newMatch(pS, pV1, pV2); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final Vertex pV1, final Vertex pV2) { - return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final Vertex pV1, final Vertex pV2) { - return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv1(final Object[] parameters) { - return rawStreamAllValues(POSITION_V1, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1() { - return rawStreamAllValuesOfv1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1() { - return rawStreamAllValuesOfv1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfv1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1(final Synchronization pS, final Vertex pV2) { - return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfv1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1(final Synchronization pS, final Vertex pV2) { - return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv2(final Object[] parameters) { - return rawStreamAllValues(POSITION_V2, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2() { - return rawStreamAllValuesOfv2(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2() { - return rawStreamAllValuesOfv2(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfv2(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2(final Synchronization pS, final Vertex pV1) { - return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2(final SynchronizedIncomingInSameRegion.Match partialMatch) { - return rawStreamAllValuesOfv2(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2(final Synchronization pS, final Vertex pV1) { - return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}).collect(Collectors.toSet()); - } - - @Override - protected SynchronizedIncomingInSameRegion.Match tupleToMatch(final Tuple t) { - try { - return SynchronizedIncomingInSameRegion.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V1), (Vertex) t.get(POSITION_V2)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedIncomingInSameRegion.Match arrayToMatch(final Object[] match) { - try { - return SynchronizedIncomingInSameRegion.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedIncomingInSameRegion.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchronizedIncomingInSameRegion.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchronizedIncomingInSameRegion.instance(); - } - } - - private SynchronizedIncomingInSameRegion() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchronizedIncomingInSameRegion instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchronizedIncomingInSameRegion.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchronizedIncomingInSameRegion.Matcher.on(engine); - } - - @Override - public SynchronizedIncomingInSameRegion.Matcher instantiate() { - return SynchronizedIncomingInSameRegion.Matcher.create(); - } - - @Override - public SynchronizedIncomingInSameRegion.Match newEmptyMatch() { - return SynchronizedIncomingInSameRegion.Match.newEmptyMatch(); - } - - @Override - public SynchronizedIncomingInSameRegion.Match newMatch(final Object... parameters) { - return SynchronizedIncomingInSameRegion.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion (visibility: PUBLIC, simpleName: SynchronizedIncomingInSameRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion (visibility: PUBLIC, simpleName: SynchronizedIncomingInSameRegion, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchronizedIncomingInSameRegion INSTANCE = new SynchronizedIncomingInSameRegion(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchronizedIncomingInSameRegion.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final PParameter parameter_v1 = new PParameter("v1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final PParameter parameter_v2 = new PParameter("v2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s, parameter_v1, parameter_v2); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedIncomingInSameRegion"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s","v1","v2"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v1 = body.getOrCreateVariableByName("v1"); - PVariable var_v2 = body.getOrCreateVariableByName("v2"); - PVariable var_t1 = body.getOrCreateVariableByName("t1"); - PVariable var_t2 = body.getOrCreateVariableByName("t2"); - PVariable var_r = body.getOrCreateVariableByName("r"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v1, parameter_v1), - new ExportedParameter(body, var_v2, parameter_v2) - )); - // find transition(t1, v1, s) - new PositivePatternCall(body, Tuples.flatTupleOf(var_t1, var_v1, var_s), Transition.instance().getInternalQueryRepresentation()); - // find transition(t2, v2, s) - new PositivePatternCall(body, Tuples.flatTupleOf(var_t2, var_v2, var_s), Transition.instance().getInternalQueryRepresentation()); - // t1!=t2 - new Inequality(body, var_t1, var_t2); - // Region.vertices(r, v1) - new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_v1); - // Region.vertices(r, v2) - new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_v2); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v1 = body.getOrCreateVariableByName("v1"); - PVariable var_v2 = body.getOrCreateVariableByName("v2"); - PVariable var_t1 = body.getOrCreateVariableByName("t1"); - PVariable var_t2 = body.getOrCreateVariableByName("t2"); - PVariable var_r = body.getOrCreateVariableByName("r"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v1, parameter_v1), - new ExportedParameter(body, var_v2, parameter_v2) - )); - // find transition(t1, s, v1) - new PositivePatternCall(body, Tuples.flatTupleOf(var_t1, var_s, var_v1), Transition.instance().getInternalQueryRepresentation()); - // find transition(t2, s, v2) - new PositivePatternCall(body, Tuples.flatTupleOf(var_t2, var_s, var_v2), Transition.instance().getInternalQueryRepresentation()); - // t1!=t2 - new Inequality(body, var_t1, var_t2); - // Region.vertices(r, v1) - new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_v1); - // Region.vertices(r, v2) - new TypeConstraint(body, Tuples.flatTupleOf(var_r), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_v2); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java deleted file mode 100644 index 28eecf9c..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionDoesNotHaveMultipleRegions.java +++ /dev/null @@ -1,744 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Child; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.HasMultipleRegions; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) {
- *         	find transition(_, v, s);
- *         	find child(c,v);
- *         	neg find hasMultipleRegions(c);
- *         } or {
- *         	find transition(_, s, v);
- *         	find child(c,v);
- *         	neg find hasMultipleRegions(c);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchronizedRegionDoesNotHaveMultipleRegions extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private Vertex fV; - - private static List parameterNames = makeImmutableList("s", "v"); - - private Match(final Synchronization pS, final Vertex pV) { - this.fS = pS; - this.fV = pV; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - if ("v".equals(parameterName)) return this.fV; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - public Vertex getV() { - return this.fV; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - if ("v".equals(parameterName) ) { - this.fV = (Vertex) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - public void setV(final Vertex pV) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV = pV; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions"; - } - - @Override - public List parameterNames() { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS, fV}; - } - - @Override - public SynchronizedRegionDoesNotHaveMultipleRegions.Match toImmutable() { - return isMutable() ? newMatch(fS, fV) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS) + ", "); - result.append("\"v\"=" + prettyPrintValue(fV)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS, fV); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchronizedRegionDoesNotHaveMultipleRegions.Match)) { - SynchronizedRegionDoesNotHaveMultipleRegions.Match other = (SynchronizedRegionDoesNotHaveMultipleRegions.Match) obj; - return Objects.equals(fS, other.fS) && Objects.equals(fV, other.fV); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchronizedRegionDoesNotHaveMultipleRegions specification() { - return SynchronizedRegionDoesNotHaveMultipleRegions.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newMutableMatch(final Synchronization pS, final Vertex pV) { - return new Mutable(pS, pV); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Synchronization pS, final Vertex pV) { - return new Immutable(pS, pV); - } - - private static final class Mutable extends SynchronizedRegionDoesNotHaveMultipleRegions.Match { - Mutable(final Synchronization pS, final Vertex pV) { - super(pS, pV); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchronizedRegionDoesNotHaveMultipleRegions.Match { - Immutable(final Synchronization pS, final Vertex pV) { - super(pS, pV); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern SynchronizedRegionDoesNotHaveMultipleRegions(s : Synchronization, v : Vertex) {
-   * 	find transition(_, v, s);
-   * 	find child(c,v);
-   * 	neg find hasMultipleRegions(c);
-   * } or {
-   * 	find transition(_, s, v);
-   * 	find child(c,v);
-   * 	neg find hasMultipleRegions(c);
-   * }
-   * 
- * - * @see Match - * @see SynchronizedRegionDoesNotHaveMultipleRegions - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static int POSITION_V = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS, final Vertex pV) { - return rawStreamAllMatches(new Object[]{pS, pV}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS, final Vertex pV) { - return rawStreamAllMatches(new Object[]{pS, pV}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV) { - return rawGetOneArbitraryMatch(new Object[]{pS, pV}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS, final Vertex pV) { - return rawHasMatch(new Object[]{pS, pV}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS, final Vertex pV) { - return rawCountMatches(new Object[]{pS, pV}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS, pV}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV the fixed value of pattern parameter v, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Synchronization pS, final Vertex pV) { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch(pS, pV); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final Vertex pV) { - return rawStreamAllValuesOfs(new Object[]{null, pV}); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final Vertex pV) { - return rawStreamAllValuesOfs(new Object[]{null, pV}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv(final Object[] parameters) { - return rawStreamAllValues(POSITION_V, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv() { - return rawStreamAllValuesOfv(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for v. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { - return rawStreamAllValuesOfv(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for v. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv(final Synchronization pS) { - return rawStreamAllValuesOfv(new Object[]{pS, null}); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv(final SynchronizedRegionDoesNotHaveMultipleRegions.Match partialMatch) { - return rawStreamAllValuesOfv(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv(final Synchronization pS) { - return rawStreamAllValuesOfv(new Object[]{pS, null}).collect(Collectors.toSet()); - } - - @Override - protected SynchronizedRegionDoesNotHaveMultipleRegions.Match tupleToMatch(final Tuple t) { - try { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedRegionDoesNotHaveMultipleRegions.Match arrayToMatch(final Object[] match) { - try { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedRegionDoesNotHaveMultipleRegions.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchronizedRegionDoesNotHaveMultipleRegions.instance(); - } - } - - private SynchronizedRegionDoesNotHaveMultipleRegions() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchronizedRegionDoesNotHaveMultipleRegions instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchronizedRegionDoesNotHaveMultipleRegions.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.on(engine); - } - - @Override - public SynchronizedRegionDoesNotHaveMultipleRegions.Matcher instantiate() { - return SynchronizedRegionDoesNotHaveMultipleRegions.Matcher.create(); - } - - @Override - public SynchronizedRegionDoesNotHaveMultipleRegions.Match newEmptyMatch() { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newEmptyMatch(); - } - - @Override - public SynchronizedRegionDoesNotHaveMultipleRegions.Match newMatch(final Object... parameters) { - return SynchronizedRegionDoesNotHaveMultipleRegions.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions (visibility: PUBLIC, simpleName: SynchronizedRegionDoesNotHaveMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions (visibility: PUBLIC, simpleName: SynchronizedRegionDoesNotHaveMultipleRegions, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchronizedRegionDoesNotHaveMultipleRegions INSTANCE = new SynchronizedRegionDoesNotHaveMultipleRegions(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchronizedRegionDoesNotHaveMultipleRegions.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final PParameter parameter_v = new PParameter("v", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s, parameter_v); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionDoesNotHaveMultipleRegions"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s","v"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v = body.getOrCreateVariableByName("v"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var_c = body.getOrCreateVariableByName("c"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v, parameter_v) - )); - // find transition(_, v, s) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v, var_s), Transition.instance().getInternalQueryRepresentation()); - // find child(c,v) - new PositivePatternCall(body, Tuples.flatTupleOf(var_c, var_v), Child.instance().getInternalQueryRepresentation()); - // neg find hasMultipleRegions(c) - new NegativePatternCall(body, Tuples.flatTupleOf(var_c), HasMultipleRegions.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v = body.getOrCreateVariableByName("v"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var_c = body.getOrCreateVariableByName("c"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v, parameter_v) - )); - // find transition(_, s, v) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var_v), Transition.instance().getInternalQueryRepresentation()); - // find child(c,v) - new PositivePatternCall(body, Tuples.flatTupleOf(var_c, var_v), Child.instance().getInternalQueryRepresentation()); - // neg find hasMultipleRegions(c) - new NegativePatternCall(body, Tuples.flatTupleOf(var_c), HasMultipleRegions.instance().getInternalQueryRepresentation()); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java deleted file mode 100644 index 160c4aa0..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/SynchronizedRegionsAreNotSiblings.java +++ /dev/null @@ -1,902 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(severity="error", message="error", key = {s})
- *         pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) {
- *         	find transition(_, v1, s);
- *         	find transition(_, v2, s);
- *         	CompositeElement.regions.vertices(r1, v1);
- *         	CompositeElement.regions.vertices(r2, v2);
- *         	r1 != r2;
- *         } or {
- *         	find transition(_, s, v1);
- *         	find transition(_, s, v2);
- *         	CompositeElement.regions.vertices(r1, v1);
- *         	CompositeElement.regions.vertices(r2, v2);
- *         	r1 != r2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class SynchronizedRegionsAreNotSiblings extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS; - - private Vertex fV1; - - private Vertex fV2; - - private static List parameterNames = makeImmutableList("s", "v1", "v2"); - - private Match(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - this.fS = pS; - this.fV1 = pV1; - this.fV2 = pV2; - } - - @Override - public Object get(final String parameterName) { - if ("s".equals(parameterName)) return this.fS; - if ("v1".equals(parameterName)) return this.fV1; - if ("v2".equals(parameterName)) return this.fV2; - return null; - } - - public Synchronization getS() { - return this.fS; - } - - public Vertex getV1() { - return this.fV1; - } - - public Vertex getV2() { - return this.fV2; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s".equals(parameterName) ) { - this.fS = (Synchronization) newValue; - return true; - } - if ("v1".equals(parameterName) ) { - this.fV1 = (Vertex) newValue; - return true; - } - if ("v2".equals(parameterName) ) { - this.fV2 = (Vertex) newValue; - return true; - } - return false; - } - - public void setS(final Synchronization pS) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS = pS; - } - - public void setV1(final Vertex pV1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV1 = pV1; - } - - public void setV2(final Vertex pV2) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fV2 = pV2; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings"; - } - - @Override - public List parameterNames() { - return SynchronizedRegionsAreNotSiblings.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS, fV1, fV2}; - } - - @Override - public SynchronizedRegionsAreNotSiblings.Match toImmutable() { - return isMutable() ? newMatch(fS, fV1, fV2) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s\"=" + prettyPrintValue(fS) + ", "); - result.append("\"v1\"=" + prettyPrintValue(fV1) + ", "); - result.append("\"v2\"=" + prettyPrintValue(fV2)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS, fV1, fV2); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof SynchronizedRegionsAreNotSiblings.Match)) { - SynchronizedRegionsAreNotSiblings.Match other = (SynchronizedRegionsAreNotSiblings.Match) obj; - return Objects.equals(fS, other.fS) && Objects.equals(fV1, other.fV1) && Objects.equals(fV2, other.fV2); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public SynchronizedRegionsAreNotSiblings specification() { - return SynchronizedRegionsAreNotSiblings.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static SynchronizedRegionsAreNotSiblings.Match newEmptyMatch() { - return new Mutable(null, null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static SynchronizedRegionsAreNotSiblings.Match newMutableMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return new Mutable(pS, pV1, pV2); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the (partial) match object. - * - */ - public static SynchronizedRegionsAreNotSiblings.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return new Immutable(pS, pV1, pV2); - } - - private static final class Mutable extends SynchronizedRegionsAreNotSiblings.Match { - Mutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - super(pS, pV1, pV2); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends SynchronizedRegionsAreNotSiblings.Match { - Immutable(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - super(pS, pV1, pV2); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(severity="error", message="error", key = {s})
-   * pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) {
-   * 	find transition(_, v1, s);
-   * 	find transition(_, v2, s);
-   * 	CompositeElement.regions.vertices(r1, v1);
-   * 	CompositeElement.regions.vertices(r2, v2);
-   * 	r1 != r2;
-   * } or {
-   * 	find transition(_, s, v1);
-   * 	find transition(_, s, v2);
-   * 	CompositeElement.regions.vertices(r1, v1);
-   * 	CompositeElement.regions.vertices(r2, v2);
-   * 	r1 != r2;
-   * }
-   * 
- * - * @see Match - * @see SynchronizedRegionsAreNotSiblings - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static SynchronizedRegionsAreNotSiblings.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static SynchronizedRegionsAreNotSiblings.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S = 0; - - private final static int POSITION_V1 = 1; - - private final static int POSITION_V2 = 2; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(SynchronizedRegionsAreNotSiblings.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawStreamAllMatches(new Object[]{pS, pV1, pV2}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawStreamAllMatches(new Object[]{pS, pV1, pV2}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawGetOneArbitraryMatch(new Object[]{pS, pV1, pV2}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawHasMatch(new Object[]{pS, pV1, pV2}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return rawCountMatches(new Object[]{pS, pV1, pV2}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS, pV1, pV2}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS the fixed value of pattern parameter s, or null if not bound. - * @param pV1 the fixed value of pattern parameter v1, or null if not bound. - * @param pV2 the fixed value of pattern parameter v2, or null if not bound. - * @return the (partial) match object. - * - */ - public SynchronizedRegionsAreNotSiblings.Match newMatch(final Synchronization pS, final Vertex pV1, final Vertex pV2) { - return SynchronizedRegionsAreNotSiblings.Match.newMatch(pS, pV1, pV2); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs(final Object[] parameters) { - return rawStreamAllValues(POSITION_S, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs() { - return rawStreamAllValuesOfs(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for s. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs(final Vertex pV1, final Vertex pV2) { - return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfs(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs(final Vertex pV1, final Vertex pV2) { - return rawStreamAllValuesOfs(new Object[]{null, pV1, pV2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv1(final Object[] parameters) { - return rawStreamAllValues(POSITION_V1, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1() { - return rawStreamAllValuesOfv1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1() { - return rawStreamAllValuesOfv1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfv1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv1(final Synchronization pS, final Vertex pV2) { - return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfv1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv1(final Synchronization pS, final Vertex pV2) { - return rawStreamAllValuesOfv1(new Object[]{pS, null, pV2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfv2(final Object[] parameters) { - return rawStreamAllValues(POSITION_V2, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2() { - return rawStreamAllValuesOfv2(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2() { - return rawStreamAllValuesOfv2(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfv2(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfv2(final Synchronization pS, final Vertex pV1) { - return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2(final SynchronizedRegionsAreNotSiblings.Match partialMatch) { - return rawStreamAllValuesOfv2(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for v2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfv2(final Synchronization pS, final Vertex pV1) { - return rawStreamAllValuesOfv2(new Object[]{pS, pV1, null}).collect(Collectors.toSet()); - } - - @Override - protected SynchronizedRegionsAreNotSiblings.Match tupleToMatch(final Tuple t) { - try { - return SynchronizedRegionsAreNotSiblings.Match.newMatch((Synchronization) t.get(POSITION_S), (Vertex) t.get(POSITION_V1), (Vertex) t.get(POSITION_V2)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedRegionsAreNotSiblings.Match arrayToMatch(final Object[] match) { - try { - return SynchronizedRegionsAreNotSiblings.Match.newMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected SynchronizedRegionsAreNotSiblings.Match arrayToMatchMutable(final Object[] match) { - try { - return SynchronizedRegionsAreNotSiblings.Match.newMutableMatch((Synchronization) match[POSITION_S], (Vertex) match[POSITION_V1], (Vertex) match[POSITION_V2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return SynchronizedRegionsAreNotSiblings.instance(); - } - } - - private SynchronizedRegionsAreNotSiblings() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static SynchronizedRegionsAreNotSiblings instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected SynchronizedRegionsAreNotSiblings.Matcher instantiate(final ViatraQueryEngine engine) { - return SynchronizedRegionsAreNotSiblings.Matcher.on(engine); - } - - @Override - public SynchronizedRegionsAreNotSiblings.Matcher instantiate() { - return SynchronizedRegionsAreNotSiblings.Matcher.create(); - } - - @Override - public SynchronizedRegionsAreNotSiblings.Match newEmptyMatch() { - return SynchronizedRegionsAreNotSiblings.Match.newEmptyMatch(); - } - - @Override - public SynchronizedRegionsAreNotSiblings.Match newMatch(final Object... parameters) { - return SynchronizedRegionsAreNotSiblings.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings (visibility: PUBLIC, simpleName: SynchronizedRegionsAreNotSiblings, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings (visibility: PUBLIC, simpleName: SynchronizedRegionsAreNotSiblings, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static SynchronizedRegionsAreNotSiblings INSTANCE = new SynchronizedRegionsAreNotSiblings(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static SynchronizedRegionsAreNotSiblings.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s = new PParameter("s", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final PParameter parameter_v1 = new PParameter("v1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final PParameter parameter_v2 = new PParameter("v2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s, parameter_v1, parameter_v2); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.SynchronizedRegionsAreNotSiblings"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s","v1","v2"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v1 = body.getOrCreateVariableByName("v1"); - PVariable var_v2 = body.getOrCreateVariableByName("v2"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - PVariable var_r1 = body.getOrCreateVariableByName("r1"); - PVariable var_r2 = body.getOrCreateVariableByName("r2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v1, parameter_v1), - new ExportedParameter(body, var_v2, parameter_v2) - )); - // find transition(_, v1, s) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_v1, var_s), Transition.instance().getInternalQueryRepresentation()); - // find transition(_, v2, s) - new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_v2, var_s), Transition.instance().getInternalQueryRepresentation()); - // CompositeElement.regions.vertices(r1, v1) - new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_v1); - // CompositeElement.regions.vertices(r2, v2) - new TypeConstraint(body, Tuples.flatTupleOf(var_r2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r2, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_3_ = body.getOrCreateVariableByName(".virtual{3}"); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_, var__virtual_3_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_3_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_3_, var_v2); - // r1 != r2 - new Inequality(body, var_r1, var_r2); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_s = body.getOrCreateVariableByName("s"); - PVariable var_v1 = body.getOrCreateVariableByName("v1"); - PVariable var_v2 = body.getOrCreateVariableByName("v2"); - PVariable var___0_ = body.getOrCreateVariableByName("_<0>"); - PVariable var___1_ = body.getOrCreateVariableByName("_<1>"); - PVariable var_r1 = body.getOrCreateVariableByName("r1"); - PVariable var_r2 = body.getOrCreateVariableByName("r2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_v2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s, parameter_s), - new ExportedParameter(body, var_v1, parameter_v1), - new ExportedParameter(body, var_v2, parameter_v2) - )); - // find transition(_, s, v1) - new PositivePatternCall(body, Tuples.flatTupleOf(var___0_, var_s, var_v1), Transition.instance().getInternalQueryRepresentation()); - // find transition(_, s, v2) - new PositivePatternCall(body, Tuples.flatTupleOf(var___1_, var_s, var_v2), Transition.instance().getInternalQueryRepresentation()); - // CompositeElement.regions.vertices(r1, v1) - new TypeConstraint(body, Tuples.flatTupleOf(var_r1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r1, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_v1); - // CompositeElement.regions.vertices(r2, v2) - new TypeConstraint(body, Tuples.flatTupleOf(var_r2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "CompositeElement"))); - PVariable var__virtual_2_ = body.getOrCreateVariableByName(".virtual{2}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_r2, var__virtual_2_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "CompositeElement", "regions"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Region"))); - PVariable var__virtual_3_ = body.getOrCreateVariableByName(".virtual{3}"); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_2_, var__virtual_3_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Region", "vertices"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_3_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_3_, var_v2); - // r1 != r2 - new Inequality(body, var_r1, var_r2); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java deleted file mode 100644 index 185f348e..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/Transition.java +++ /dev/null @@ -1,808 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         pattern transition(t : Transition, src : Vertex, trg : Vertex) {
- *         	Transition.source(t, src);
- *         	Transition.target(t, trg);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class Transition extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition fT; - - private Vertex fSrc; - - private Vertex fTrg; - - private static List parameterNames = makeImmutableList("t", "src", "trg"); - - private Match(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - this.fT = pT; - this.fSrc = pSrc; - this.fTrg = pTrg; - } - - @Override - public Object get(final String parameterName) { - if ("t".equals(parameterName)) return this.fT; - if ("src".equals(parameterName)) return this.fSrc; - if ("trg".equals(parameterName)) return this.fTrg; - return null; - } - - public ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition getT() { - return this.fT; - } - - public Vertex getSrc() { - return this.fSrc; - } - - public Vertex getTrg() { - return this.fTrg; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("t".equals(parameterName) ) { - this.fT = (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) newValue; - return true; - } - if ("src".equals(parameterName) ) { - this.fSrc = (Vertex) newValue; - return true; - } - if ("trg".equals(parameterName) ) { - this.fTrg = (Vertex) newValue; - return true; - } - return false; - } - - public void setT(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setSrc(final Vertex pSrc) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fSrc = pSrc; - } - - public void setTrg(final Vertex pTrg) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTrg = pTrg; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition"; - } - - @Override - public List parameterNames() { - return Transition.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fSrc, fTrg}; - } - - @Override - public Transition.Match toImmutable() { - return isMutable() ? newMatch(fT, fSrc, fTrg) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"t\"=" + prettyPrintValue(fT) + ", "); - result.append("\"src\"=" + prettyPrintValue(fSrc) + ", "); - result.append("\"trg\"=" + prettyPrintValue(fTrg)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fSrc, fTrg); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof Transition.Match)) { - Transition.Match other = (Transition.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fSrc, other.fSrc) && Objects.equals(fTrg, other.fTrg); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public Transition specification() { - return Transition.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static Transition.Match newEmptyMatch() { - return new Mutable(null, null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static Transition.Match newMutableMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return new Mutable(pT, pSrc, pTrg); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return the (partial) match object. - * - */ - public static Transition.Match newMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return new Immutable(pT, pSrc, pTrg); - } - - private static final class Mutable extends Transition.Match { - Mutable(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - super(pT, pSrc, pTrg); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends Transition.Match { - Immutable(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - super(pT, pSrc, pTrg); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * pattern transition(t : Transition, src : Vertex, trg : Vertex) {
-   * 	Transition.source(t, src);
-   * 	Transition.target(t, trg);
-   * }
-   * 
- * - * @see Match - * @see Transition - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static Transition.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static Transition.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_SRC = 1; - - private final static int POSITION_TRG = 2; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Transition.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return rawStreamAllMatches(new Object[]{pT, pSrc, pTrg}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return rawStreamAllMatches(new Object[]{pT, pSrc, pTrg}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return rawGetOneArbitraryMatch(new Object[]{pT, pSrc, pTrg}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return rawHasMatch(new Object[]{pT, pSrc, pTrg}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return rawCountMatches(new Object[]{pT, pSrc, pTrg}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pSrc, pTrg}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter t, or null if not bound. - * @param pSrc the fixed value of pattern parameter src, or null if not bound. - * @param pTrg the fixed value of pattern parameter trg, or null if not bound. - * @return the (partial) match object. - * - */ - public Transition.Match newMatch(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc, final Vertex pTrg) { - return Transition.Match.newMatch(pT, pSrc, pTrg); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOft(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft() { - return rawStreamAllValuesOft(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final Transition.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for t. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOft(final Vertex pSrc, final Vertex pTrg) { - return rawStreamAllValuesOft(new Object[]{null, pSrc, pTrg}); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final Transition.Match partialMatch) { - return rawStreamAllValuesOft(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for t. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOft(final Vertex pSrc, final Vertex pTrg) { - return rawStreamAllValuesOft(new Object[]{null, pSrc, pTrg}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for src. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfsrc(final Object[] parameters) { - return rawStreamAllValues(POSITION_SRC, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for src. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfsrc() { - return rawStreamAllValuesOfsrc(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for src. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfsrc() { - return rawStreamAllValuesOfsrc(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for src. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfsrc(final Transition.Match partialMatch) { - return rawStreamAllValuesOfsrc(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for src. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfsrc(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pTrg) { - return rawStreamAllValuesOfsrc(new Object[]{pT, null, pTrg}); - } - - /** - * Retrieve the set of values that occur in matches for src. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfsrc(final Transition.Match partialMatch) { - return rawStreamAllValuesOfsrc(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for src. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfsrc(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pTrg) { - return rawStreamAllValuesOfsrc(new Object[]{pT, null, pTrg}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for trg. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOftrg(final Object[] parameters) { - return rawStreamAllValues(POSITION_TRG, parameters).map(Vertex.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for trg. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOftrg() { - return rawStreamAllValuesOftrg(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for trg. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOftrg() { - return rawStreamAllValuesOftrg(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for trg. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOftrg(final Transition.Match partialMatch) { - return rawStreamAllValuesOftrg(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for trg. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOftrg(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc) { - return rawStreamAllValuesOftrg(new Object[]{pT, pSrc, null}); - } - - /** - * Retrieve the set of values that occur in matches for trg. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOftrg(final Transition.Match partialMatch) { - return rawStreamAllValuesOftrg(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for trg. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOftrg(final ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition pT, final Vertex pSrc) { - return rawStreamAllValuesOftrg(new Object[]{pT, pSrc, null}).collect(Collectors.toSet()); - } - - @Override - protected Transition.Match tupleToMatch(final Tuple t) { - try { - return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) t.get(POSITION_T), (Vertex) t.get(POSITION_SRC), (Vertex) t.get(POSITION_TRG)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected Transition.Match arrayToMatch(final Object[] match) { - try { - return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) match[POSITION_T], (Vertex) match[POSITION_SRC], (Vertex) match[POSITION_TRG]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected Transition.Match arrayToMatchMutable(final Object[] match) { - try { - return Transition.Match.newMutableMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) match[POSITION_T], (Vertex) match[POSITION_SRC], (Vertex) match[POSITION_TRG]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return Transition.instance(); - } - } - - private Transition() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static Transition instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected Transition.Matcher instantiate(final ViatraQueryEngine engine) { - return Transition.Matcher.on(engine); - } - - @Override - public Transition.Matcher instantiate() { - return Transition.Matcher.create(); - } - - @Override - public Transition.Match newEmptyMatch() { - return Transition.Match.newEmptyMatch(); - } - - @Override - public Transition.Match newMatch(final Object... parameters) { - return Transition.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[1], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex) parameters[2]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition (visibility: PUBLIC, simpleName: Transition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition (visibility: PUBLIC, simpleName: Transition, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.Transition, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static Transition INSTANCE = new Transition(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static Transition.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_t = new PParameter("t", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Transition")), PParameterDirection.INOUT); - - private final PParameter parameter_src = new PParameter("src", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final PParameter parameter_trg = new PParameter("trg", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Vertex")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_t, parameter_src, parameter_trg); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.transition"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("t","src","trg"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_t = body.getOrCreateVariableByName("t"); - PVariable var_src = body.getOrCreateVariableByName("src"); - PVariable var_trg = body.getOrCreateVariableByName("trg"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_src), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_trg), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_t, parameter_t), - new ExportedParameter(body, var_src, parameter_src), - new ExportedParameter(body, var_trg, parameter_trg) - )); - // Transition.source(t, src) - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "source"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_0_, var_src); - // Transition.target(t, trg) - new TypeConstraint(body, Tuples.flatTupleOf(var_t), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Transition"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_t, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("YakinduMetamodel", "Transition", "target"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Vertex"))); - new Equality(body, var__virtual_1_, var_trg); - bodies.add(body); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java deleted file mode 100644 index 4595f6bc..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/TwoSynch.java +++ /dev/null @@ -1,714 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Inequality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         Simplifying model generation
- *          
- *         {@literal @}Constraint(severity="error", message="error", key = {s1,s2})
- *         pattern twoSynch(s1 : Synchronization, s2 : Synchronization) {
- *         	Synchronization(s1);
- *         	Synchronization(s2);
- *         	s1 != s2;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class TwoSynch extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Synchronization fS1; - - private Synchronization fS2; - - private static List parameterNames = makeImmutableList("s1", "s2"); - - private Match(final Synchronization pS1, final Synchronization pS2) { - this.fS1 = pS1; - this.fS2 = pS2; - } - - @Override - public Object get(final String parameterName) { - if ("s1".equals(parameterName)) return this.fS1; - if ("s2".equals(parameterName)) return this.fS2; - return null; - } - - public Synchronization getS1() { - return this.fS1; - } - - public Synchronization getS2() { - return this.fS2; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("s1".equals(parameterName) ) { - this.fS1 = (Synchronization) newValue; - return true; - } - if ("s2".equals(parameterName) ) { - this.fS2 = (Synchronization) newValue; - return true; - } - return false; - } - - public void setS1(final Synchronization pS1) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS1 = pS1; - } - - public void setS2(final Synchronization pS2) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fS2 = pS2; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch"; - } - - @Override - public List parameterNames() { - return TwoSynch.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fS1, fS2}; - } - - @Override - public TwoSynch.Match toImmutable() { - return isMutable() ? newMatch(fS1, fS2) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"s1\"=" + prettyPrintValue(fS1) + ", "); - result.append("\"s2\"=" + prettyPrintValue(fS2)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fS1, fS2); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof TwoSynch.Match)) { - TwoSynch.Match other = (TwoSynch.Match) obj; - return Objects.equals(fS1, other.fS1) && Objects.equals(fS2, other.fS2); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public TwoSynch specification() { - return TwoSynch.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static TwoSynch.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static TwoSynch.Match newMutableMatch(final Synchronization pS1, final Synchronization pS2) { - return new Mutable(pS1, pS2); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return the (partial) match object. - * - */ - public static TwoSynch.Match newMatch(final Synchronization pS1, final Synchronization pS2) { - return new Immutable(pS1, pS2); - } - - private static final class Mutable extends TwoSynch.Match { - Mutable(final Synchronization pS1, final Synchronization pS2) { - super(pS1, pS2); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends TwoSynch.Match { - Immutable(final Synchronization pS1, final Synchronization pS2) { - super(pS1, pS2); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * Simplifying model generation
-   *  
-   * {@literal @}Constraint(severity="error", message="error", key = {s1,s2})
-   * pattern twoSynch(s1 : Synchronization, s2 : Synchronization) {
-   * 	Synchronization(s1);
-   * 	Synchronization(s2);
-   * 	s1 != s2;
-   * }
-   * 
- * - * @see Match - * @see TwoSynch - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static TwoSynch.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static TwoSynch.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_S1 = 0; - - private final static int POSITION_S2 = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(TwoSynch.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Synchronization pS1, final Synchronization pS2) { - return rawStreamAllMatches(new Object[]{pS1, pS2}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Synchronization pS1, final Synchronization pS2) { - return rawStreamAllMatches(new Object[]{pS1, pS2}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Synchronization pS1, final Synchronization pS2) { - return rawGetOneArbitraryMatch(new Object[]{pS1, pS2}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Synchronization pS1, final Synchronization pS2) { - return rawHasMatch(new Object[]{pS1, pS2}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Synchronization pS1, final Synchronization pS2) { - return rawCountMatches(new Object[]{pS1, pS2}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Synchronization pS1, final Synchronization pS2, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pS1, pS2}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pS1 the fixed value of pattern parameter s1, or null if not bound. - * @param pS2 the fixed value of pattern parameter s2, or null if not bound. - * @return the (partial) match object. - * - */ - public TwoSynch.Match newMatch(final Synchronization pS1, final Synchronization pS2) { - return TwoSynch.Match.newMatch(pS1, pS2); - } - - /** - * Retrieve the set of values that occur in matches for s1. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs1(final Object[] parameters) { - return rawStreamAllValues(POSITION_S1, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs1() { - return rawStreamAllValuesOfs1(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs1() { - return rawStreamAllValuesOfs1(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for s1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs1(final TwoSynch.Match partialMatch) { - return rawStreamAllValuesOfs1(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for s1. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs1(final Synchronization pS2) { - return rawStreamAllValuesOfs1(new Object[]{null, pS2}); - } - - /** - * Retrieve the set of values that occur in matches for s1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs1(final TwoSynch.Match partialMatch) { - return rawStreamAllValuesOfs1(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s1. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs1(final Synchronization pS2) { - return rawStreamAllValuesOfs1(new Object[]{null, pS2}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s2. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfs2(final Object[] parameters) { - return rawStreamAllValues(POSITION_S2, parameters).map(Synchronization.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for s2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs2() { - return rawStreamAllValuesOfs2(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs2() { - return rawStreamAllValuesOfs2(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for s2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs2(final TwoSynch.Match partialMatch) { - return rawStreamAllValuesOfs2(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for s2. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfs2(final Synchronization pS1) { - return rawStreamAllValuesOfs2(new Object[]{pS1, null}); - } - - /** - * Retrieve the set of values that occur in matches for s2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs2(final TwoSynch.Match partialMatch) { - return rawStreamAllValuesOfs2(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for s2. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfs2(final Synchronization pS1) { - return rawStreamAllValuesOfs2(new Object[]{pS1, null}).collect(Collectors.toSet()); - } - - @Override - protected TwoSynch.Match tupleToMatch(final Tuple t) { - try { - return TwoSynch.Match.newMatch((Synchronization) t.get(POSITION_S1), (Synchronization) t.get(POSITION_S2)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected TwoSynch.Match arrayToMatch(final Object[] match) { - try { - return TwoSynch.Match.newMatch((Synchronization) match[POSITION_S1], (Synchronization) match[POSITION_S2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected TwoSynch.Match arrayToMatchMutable(final Object[] match) { - try { - return TwoSynch.Match.newMutableMatch((Synchronization) match[POSITION_S1], (Synchronization) match[POSITION_S2]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return TwoSynch.instance(); - } - } - - private TwoSynch() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static TwoSynch instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected TwoSynch.Matcher instantiate(final ViatraQueryEngine engine) { - return TwoSynch.Matcher.on(engine); - } - - @Override - public TwoSynch.Matcher instantiate() { - return TwoSynch.Matcher.create(); - } - - @Override - public TwoSynch.Match newEmptyMatch() { - return TwoSynch.Match.newEmptyMatch(); - } - - @Override - public TwoSynch.Match newMatch(final Object... parameters) { - return TwoSynch.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch (visibility: PUBLIC, simpleName: TwoSynch, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch (visibility: PUBLIC, simpleName: TwoSynch, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.TwoSynch, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static TwoSynch INSTANCE = new TwoSynch(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static TwoSynch.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_s1 = new PParameter("s1", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final PParameter parameter_s2 = new PParameter("s2", "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("YakinduMetamodel", "Synchronization")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_s1, parameter_s2); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.twoSynch"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("s1","s2"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_s1 = body.getOrCreateVariableByName("s1"); - PVariable var_s2 = body.getOrCreateVariableByName("s2"); - new TypeConstraint(body, Tuples.flatTupleOf(var_s1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_s2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_s1, parameter_s1), - new ExportedParameter(body, var_s2, parameter_s2) - )); - // Synchronization(s1) - new TypeConstraint(body, Tuples.flatTupleOf(var_s1), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - // Synchronization(s2) - new TypeConstraint(body, Tuples.flatTupleOf(var_s2), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("YakinduMetamodel", "Synchronization"))); - // s1 != s2 - new Inequality(body, var_s1, var_s2); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("message", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("s1"), - new ParameterReference("s2") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF index 1995ee52..2ea274a4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF @@ -4,7 +4,8 @@ Bundle-Name: Test Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.test;singleton:=true Bundle-Version: 1.0.0.qualifier Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries -Require-Bundle: org.eclipse.emf.ecore, +Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, + org.eclipse.emf.ecore, org.eclipse.viatra.query.runtime.rete, org.eclipse.viatra.query.runtime.localsearch, com.google.guava, diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem index 85e09a0a..18e58ab0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem @@ -557,7 +557,7 @@ - + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp index b4bb6700..3d49d42c 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp @@ -4,41 +4,21 @@ fof ( enumScope_FunctionType_Root , axiom , ! [ A ] : ( A = eo1 <=> e_Root_Funct fof ( enumScope_FunctionType_Intermediate , axiom , ! [ A ] : ( A = eo2 <=> e_Intermediate_FunctionType ( A ) ) ) . fof ( enumScope_FunctionType_Leaf , axiom , ! [ A ] : ( A = eo3 <=> e_Leaf_FunctionType ( A ) ) ) . fof ( notObjectHandler , axiom , ! [ A ] : ( ~ object ( A ) <=> ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ~ t_FunctionType ( A ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( inheritanceHierarchyHandler , axiom , ! [ A ] : ( object ( A ) <=> ( ( t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FAMTerminator ( A ) & ( t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( t_FunctionalInput ( A ) & ~ t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) | ( ~ t_FAMTerminator ( A ) & ( t_FunctionalData ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_Function ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalInput ( A ) & t_FunctionalOutput ( A ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . +fof ( inheritanceHierarchyHandler , axiom , ! [ A ] : ( object ( A ) <=> ( ( t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( t_FunctionalOutput ( A ) & ( t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . fof ( typeScope_min_object , axiom , ! [ A ] : ( ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = eo1 | ( A = eo2 | A = eo3 ) ) ) ) ) ) => object ( A ) ) ) . -fof ( typeScope_max_object , axiom , ! [ A ] : ( object ( A ) => ( A = eo1 | ( A = eo2 | ( A = eo3 | ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = o5 | ( A = o6 | ( A = o7 | ( A = o8 | ( A = o9 | ( A = o10 | ( A = o11 | ( A = o12 | ( A = o13 | ( A = o14 | ( A = o15 | ( A = o16 | ( A = o17 | ( A = o18 | ( A = o19 | ( A = o20 | ( A = o21 | ( A = o22 | ( A = o23 | ( A = o24 | A = o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( typeScope_min_t_FunctionalInterface , axiom , ! [ A ] : ( ( A = o2 | A = o3 ) => ( t_FunctionalInterface ( A ) & object ( A ) ) ) ) . -fof ( typeScope_min_t_Function , axiom , ! [ A ] : ( A = o4 => ( t_Function ( A ) & object ( A ) ) ) ) . -fof ( typeScope_min_t_FunctionalOutput , axiom , ! [ A ] : ( ( A = o5 | ( A = o6 | A = o7 ) ) => ( t_FunctionalOutput ( A ) & object ( A ) ) ) ) . -fof ( typeScope_max_t_Function , axiom , ! [ A ] : ( ( t_Function ( A ) & object ( A ) ) => ( A = o4 | ( A = o8 | ( A = o9 | ( A = o10 | A = o11 ) ) ) ) ) ) . -fof ( typeScope_max_t_FunctionalOutput , axiom , ! [ A ] : ( ( t_FunctionalOutput ( A ) & object ( A ) ) => ( A = o5 | ( A = o6 | ( A = o7 | A = o8 ) ) ) ) ) . -fof ( t_uniqueness_eo1 , axiom , eo1 != eo2 & ( eo1 != eo3 & ( eo1 != o1 & ( eo1 != o2 & ( eo1 != o3 & ( eo1 != o4 & ( eo1 != o5 & ( eo1 != o6 & ( eo1 != o7 & ( eo1 != o8 & ( eo1 != o9 & ( eo1 != o10 & ( eo1 != o11 & ( eo1 != o12 & ( eo1 != o13 & ( eo1 != o14 & ( eo1 != o15 & ( eo1 != o16 & ( eo1 != o17 & ( eo1 != o18 & ( eo1 != o19 & ( eo1 != o20 & ( eo1 != o21 & ( eo1 != o22 & ( eo1 != o23 & ( eo1 != o24 & eo1 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_eo2 , axiom , eo2 != eo3 & ( eo2 != o1 & ( eo2 != o2 & ( eo2 != o3 & ( eo2 != o4 & ( eo2 != o5 & ( eo2 != o6 & ( eo2 != o7 & ( eo2 != o8 & ( eo2 != o9 & ( eo2 != o10 & ( eo2 != o11 & ( eo2 != o12 & ( eo2 != o13 & ( eo2 != o14 & ( eo2 != o15 & ( eo2 != o16 & ( eo2 != o17 & ( eo2 != o18 & ( eo2 != o19 & ( eo2 != o20 & ( eo2 != o21 & ( eo2 != o22 & ( eo2 != o23 & ( eo2 != o24 & eo2 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_eo3 , axiom , eo3 != o1 & ( eo3 != o2 & ( eo3 != o3 & ( eo3 != o4 & ( eo3 != o5 & ( eo3 != o6 & ( eo3 != o7 & ( eo3 != o8 & ( eo3 != o9 & ( eo3 != o10 & ( eo3 != o11 & ( eo3 != o12 & ( eo3 != o13 & ( eo3 != o14 & ( eo3 != o15 & ( eo3 != o16 & ( eo3 != o17 & ( eo3 != o18 & ( eo3 != o19 & ( eo3 != o20 & ( eo3 != o21 & ( eo3 != o22 & ( eo3 != o23 & ( eo3 != o24 & eo3 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o1 , axiom , o1 != o2 & ( o1 != o3 & ( o1 != o4 & ( o1 != o5 & ( o1 != o6 & ( o1 != o7 & ( o1 != o8 & ( o1 != o9 & ( o1 != o10 & ( o1 != o11 & ( o1 != o12 & ( o1 != o13 & ( o1 != o14 & ( o1 != o15 & ( o1 != o16 & ( o1 != o17 & ( o1 != o18 & ( o1 != o19 & ( o1 != o20 & ( o1 != o21 & ( o1 != o22 & ( o1 != o23 & ( o1 != o24 & o1 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o2 , axiom , o2 != o3 & ( o2 != o4 & ( o2 != o5 & ( o2 != o6 & ( o2 != o7 & ( o2 != o8 & ( o2 != o9 & ( o2 != o10 & ( o2 != o11 & ( o2 != o12 & ( o2 != o13 & ( o2 != o14 & ( o2 != o15 & ( o2 != o16 & ( o2 != o17 & ( o2 != o18 & ( o2 != o19 & ( o2 != o20 & ( o2 != o21 & ( o2 != o22 & ( o2 != o23 & ( o2 != o24 & o2 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o3 , axiom , o3 != o4 & ( o3 != o5 & ( o3 != o6 & ( o3 != o7 & ( o3 != o8 & ( o3 != o9 & ( o3 != o10 & ( o3 != o11 & ( o3 != o12 & ( o3 != o13 & ( o3 != o14 & ( o3 != o15 & ( o3 != o16 & ( o3 != o17 & ( o3 != o18 & ( o3 != o19 & ( o3 != o20 & ( o3 != o21 & ( o3 != o22 & ( o3 != o23 & ( o3 != o24 & o3 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o4 , axiom , o4 != o5 & ( o4 != o6 & ( o4 != o7 & ( o4 != o8 & ( o4 != o9 & ( o4 != o10 & ( o4 != o11 & ( o4 != o12 & ( o4 != o13 & ( o4 != o14 & ( o4 != o15 & ( o4 != o16 & ( o4 != o17 & ( o4 != o18 & ( o4 != o19 & ( o4 != o20 & ( o4 != o21 & ( o4 != o22 & ( o4 != o23 & ( o4 != o24 & o4 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o5 , axiom , o5 != o6 & ( o5 != o7 & ( o5 != o8 & ( o5 != o9 & ( o5 != o10 & ( o5 != o11 & ( o5 != o12 & ( o5 != o13 & ( o5 != o14 & ( o5 != o15 & ( o5 != o16 & ( o5 != o17 & ( o5 != o18 & ( o5 != o19 & ( o5 != o20 & ( o5 != o21 & ( o5 != o22 & ( o5 != o23 & ( o5 != o24 & o5 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o6 , axiom , o6 != o7 & ( o6 != o8 & ( o6 != o9 & ( o6 != o10 & ( o6 != o11 & ( o6 != o12 & ( o6 != o13 & ( o6 != o14 & ( o6 != o15 & ( o6 != o16 & ( o6 != o17 & ( o6 != o18 & ( o6 != o19 & ( o6 != o20 & ( o6 != o21 & ( o6 != o22 & ( o6 != o23 & ( o6 != o24 & o6 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o7 , axiom , o7 != o8 & ( o7 != o9 & ( o7 != o10 & ( o7 != o11 & ( o7 != o12 & ( o7 != o13 & ( o7 != o14 & ( o7 != o15 & ( o7 != o16 & ( o7 != o17 & ( o7 != o18 & ( o7 != o19 & ( o7 != o20 & ( o7 != o21 & ( o7 != o22 & ( o7 != o23 & ( o7 != o24 & o7 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o8 , axiom , o8 != o9 & ( o8 != o10 & ( o8 != o11 & ( o8 != o12 & ( o8 != o13 & ( o8 != o14 & ( o8 != o15 & ( o8 != o16 & ( o8 != o17 & ( o8 != o18 & ( o8 != o19 & ( o8 != o20 & ( o8 != o21 & ( o8 != o22 & ( o8 != o23 & ( o8 != o24 & o8 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o9 , axiom , o9 != o10 & ( o9 != o11 & ( o9 != o12 & ( o9 != o13 & ( o9 != o14 & ( o9 != o15 & ( o9 != o16 & ( o9 != o17 & ( o9 != o18 & ( o9 != o19 & ( o9 != o20 & ( o9 != o21 & ( o9 != o22 & ( o9 != o23 & ( o9 != o24 & o9 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o10 , axiom , o10 != o11 & ( o10 != o12 & ( o10 != o13 & ( o10 != o14 & ( o10 != o15 & ( o10 != o16 & ( o10 != o17 & ( o10 != o18 & ( o10 != o19 & ( o10 != o20 & ( o10 != o21 & ( o10 != o22 & ( o10 != o23 & ( o10 != o24 & o10 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o11 , axiom , o11 != o12 & ( o11 != o13 & ( o11 != o14 & ( o11 != o15 & ( o11 != o16 & ( o11 != o17 & ( o11 != o18 & ( o11 != o19 & ( o11 != o20 & ( o11 != o21 & ( o11 != o22 & ( o11 != o23 & ( o11 != o24 & o11 != o25 ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o12 , axiom , o12 != o13 & ( o12 != o14 & ( o12 != o15 & ( o12 != o16 & ( o12 != o17 & ( o12 != o18 & ( o12 != o19 & ( o12 != o20 & ( o12 != o21 & ( o12 != o22 & ( o12 != o23 & ( o12 != o24 & o12 != o25 ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o13 , axiom , o13 != o14 & ( o13 != o15 & ( o13 != o16 & ( o13 != o17 & ( o13 != o18 & ( o13 != o19 & ( o13 != o20 & ( o13 != o21 & ( o13 != o22 & ( o13 != o23 & ( o13 != o24 & o13 != o25 ) ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o14 , axiom , o14 != o15 & ( o14 != o16 & ( o14 != o17 & ( o14 != o18 & ( o14 != o19 & ( o14 != o20 & ( o14 != o21 & ( o14 != o22 & ( o14 != o23 & ( o14 != o24 & o14 != o25 ) ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o15 , axiom , o15 != o16 & ( o15 != o17 & ( o15 != o18 & ( o15 != o19 & ( o15 != o20 & ( o15 != o21 & ( o15 != o22 & ( o15 != o23 & ( o15 != o24 & o15 != o25 ) ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o16 , axiom , o16 != o17 & ( o16 != o18 & ( o16 != o19 & ( o16 != o20 & ( o16 != o21 & ( o16 != o22 & ( o16 != o23 & ( o16 != o24 & o16 != o25 ) ) ) ) ) ) ) ) . -fof ( t_uniqueness_o17 , axiom , o17 != o18 & ( o17 != o19 & ( o17 != o20 & ( o17 != o21 & ( o17 != o22 & ( o17 != o23 & ( o17 != o24 & o17 != o25 ) ) ) ) ) ) ) . -fof ( t_uniqueness_o18 , axiom , o18 != o19 & ( o18 != o20 & ( o18 != o21 & ( o18 != o22 & ( o18 != o23 & ( o18 != o24 & o18 != o25 ) ) ) ) ) ) . -fof ( t_uniqueness_o19 , axiom , o19 != o20 & ( o19 != o21 & ( o19 != o22 & ( o19 != o23 & ( o19 != o24 & o19 != o25 ) ) ) ) ) . -fof ( t_uniqueness_o20 , axiom , o20 != o21 & ( o20 != o22 & ( o20 != o23 & ( o20 != o24 & o20 != o25 ) ) ) ) . -fof ( t_uniqueness_o21 , axiom , o21 != o22 & ( o21 != o23 & ( o21 != o24 & o21 != o25 ) ) ) . -fof ( t_uniqueness_o22 , axiom , o22 != o23 & ( o22 != o24 & o22 != o25 ) ) . -fof ( t_uniqueness_o23 , axiom , o23 != o24 & o23 != o25 ) . -fof ( t_uniqueness_o24 , axiom , o24 != o25 ) . +fof ( typeScope_max_object , axiom , ! [ A ] : ( object ( A ) => ( A = eo1 | ( A = eo2 | ( A = eo3 | ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | A = o5 ) ) ) ) ) ) ) ) ) . +fof ( typeScope_min_t_Function , axiom , ! [ A ] : ( A = o2 => ( t_Function ( A ) & object ( A ) ) ) ) . +fof ( typeScope_min_t_FunctionalOutput , axiom , ! [ A ] : ( ( A = o3 | ( A = o4 | A = o5 ) ) => ( t_FunctionalOutput ( A ) & object ( A ) ) ) ) . +fof ( typeScope_min_t_FunctionalInterface , axiom , ! [ A ] : ( ( A = o6 | A = o7 ) => ( t_FunctionalInterface ( A ) & object ( A ) ) ) ) . +fof ( typeScope_max_t_Function , axiom , ! [ A ] : ( ( t_Function ( A ) & object ( A ) ) => A = o2 ) ) . +fof ( typeScope_max_t_FunctionalOutput , axiom , ! [ A ] : ( ( t_FunctionalOutput ( A ) & object ( A ) ) => ( A = o3 | ( A = o4 | A = o5 ) ) ) ) . +fof ( t_uniqueness_eo1 , axiom , eo1 != eo2 & ( eo1 != eo3 & ( eo1 != o1 & ( eo1 != o2 & ( eo1 != o3 & ( eo1 != o4 & eo1 != o5 ) ) ) ) ) ) . +fof ( t_uniqueness_eo2 , axiom , eo2 != eo3 & ( eo2 != o1 & ( eo2 != o2 & ( eo2 != o3 & ( eo2 != o4 & eo2 != o5 ) ) ) ) ) . +fof ( t_uniqueness_eo3 , axiom , eo3 != o1 & ( eo3 != o2 & ( eo3 != o3 & ( eo3 != o4 & eo3 != o5 ) ) ) ) . +fof ( t_uniqueness_o1 , axiom , o1 != o2 & ( o1 != o3 & ( o1 != o4 & o1 != o5 ) ) ) . +fof ( t_uniqueness_o2 , axiom , o2 != o3 & ( o2 != o4 & o2 != o5 ) ) . +fof ( t_uniqueness_o3 , axiom , o3 != o4 & o3 != o5 ) . +fof ( t_uniqueness_o4 , axiom , o4 != o5 ) . fof ( compliance_interface_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_interface_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalInterface ( V_1 ) ) ) ) . fof ( compliance_model_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_model_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalArchitectureModel ( V_1 ) ) ) ) . fof ( compliance_parent_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_parent_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_Function ( V_1 ) ) ) ) . @@ -64,8 +44,8 @@ fof ( containment_noDup_r_terminator_FunctionalData , axiom , ? [ A , B ] : ( r_ fof ( containment_t_FunctionalElement , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : ( ( r_rootElements_FunctionalArchitectureModel ( B , A ) & ~ r_subElements_Function ( B , A ) ) | ( ~ r_rootElements_FunctionalArchitectureModel ( B , A ) & r_subElements_Function ( B , A ) ) ) ) ) . fof ( containment_t_FunctionalData , axiom , ! [ A ] : ( t_FunctionalData ( A ) => ? [ B ] : r_data_FunctionalInterface ( B , A ) ) ) . fof ( containment_t_InformationLink , axiom , ! [ A ] : ( t_InformationLink ( A ) => ? [ B ] : r_outgoingLinks_FunctionalOutput ( B , A ) ) ) . -fof ( containment_t_FAMTerminator , axiom , ! [ A ] : ( t_FAMTerminator ( A ) => ? [ B ] : r_terminator_FunctionalData ( B , A ) ) ) . fof ( containment_t_FunctionalInterface , axiom , ! [ A ] : ( t_FunctionalInterface ( A ) => ? [ B ] : r_interface_FunctionalElement ( B , A ) ) ) . +fof ( containment_t_FAMTerminator , axiom , ! [ A ] : ( t_FAMTerminator ( A ) => ? [ B ] : r_terminator_FunctionalData ( B , A ) ) ) . fof ( containment_noCycle_1 , axiom , ~ ? [ V1 ] : ( r_interface_FunctionalElement ( V1 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V1 ) | ( r_subElements_Function ( V1 , V1 ) | ( r_data_FunctionalInterface ( V1 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V1 ) | r_terminator_FunctionalData ( V1 , V1 ) ) ) ) ) ) ) . fof ( containment_noCycle_2 , axiom , ~ ? [ V1 , V2 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V2 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V1 ) | ( r_subElements_Function ( V2 , V1 ) | ( r_data_FunctionalInterface ( V2 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V1 ) | r_terminator_FunctionalData ( V2 , V1 ) ) ) ) ) ) ) ) . fof ( containment_noCycle_3 , axiom , ~ ? [ V1 , V2 , V3 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V2 , V3 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V3 ) | ( r_subElements_Function ( V2 , V3 ) | ( r_data_FunctionalInterface ( V2 , V3 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V3 ) | r_terminator_FunctionalData ( V2 , V3 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V3 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V3 , V1 ) | ( r_subElements_Function ( V3 , V1 ) | ( r_data_FunctionalInterface ( V3 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V3 , V1 ) | r_terminator_FunctionalData ( V3 , V1 ) ) ) ) ) ) ) ) ) . diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index 38efb459..3770f0af 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -4,4 +4,14 @@ + + + + + + + + + + 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 ef2e0c2f..f66ad93c 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 @@ -1,36 +1,115 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse import ca.mcgill.ecse.dslreasoner.vampire.queries.FamPatterns +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration +import functionalarchitecture.Function +import functionalarchitecture.FunctionalInterface +import functionalarchitecture.FunctionalOutput import functionalarchitecture.FunctionalarchitecturePackage +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace -import java.util.LinkedList -import org.eclipse.emf.ecore.EObject +import java.util.HashMap import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl class FAMTest { def static void main(String[] args) { - //Workspace setup + val Ecore2Logic ecore2Logic = new Ecore2Logic + val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) + val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic + + // Workspace setup val inputs = new FileSystemWorkspace('''initialModels/''', "") val workspace = new FileSystemWorkspace('''output/FAMTest/''', "") workspace.initAndClear - - //Logicproblem writing setup + + // Logicproblem writing setup val reg = Resource.Factory.Registry.INSTANCE val map = reg.extensionToFactoryMap map.put("logicproblem", new XMIResourceFactoryImpl) - println("Input and output workspaces are created") + // Load DSL val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) val partialModel = GeneralTest.loadPartialModel(inputs, "FaModel.xmi") val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) println("DSL loaded") + + val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) + var problem = modelGenerationProblem.output +// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output +// problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output + workspace.writeModel(problem, "Fam.logicproblem") + + println("Problem created") + + //Start Time + var startTime = System.currentTimeMillis + + var LogicReasoner reasoner + // * + reasoner = new VampireSolver + + // ///////////////////////////////////////////////////// + // Minimum Scope + val classMapMin = new HashMap + classMapMin.put(Function, 1) + classMapMin.put(FunctionalInterface, 2) + classMapMin.put(FunctionalOutput, 3) - GeneralTest.createAndSolveProblem(metamodel, partialModel, queries, workspace) + val typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Maximum Scope + val classMapMax = new HashMap + classMapMax.put(Function, 5) + classMapMax.put(FunctionalInterface, 2) + classMapMax.put(FunctionalOutput, 4) + + val typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Define Config File + val vampireConfig = new VampireSolverConfiguration => [ + // add configuration things, in config file first + it.documentationLevel = DocumentationLevel::FULL + + it.typeScopes.minNewElements = 4 + it.typeScopes.maxNewElements = 5 + if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin + if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax + it.contCycleLevel = 5 + it.uniquenessDuplicates = false + ] + + var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) + + /*/ + * + * reasoner = new AlloySolver + * val alloyConfig = new AlloySolverConfiguration => [ + * it.typeScopes.maxNewElements = 7 + * it.typeScopes.minNewElements = 3 + * it.solutionScope.numberOfRequiredSolution = 1 + * it.typeScopes.maxNewIntegers = 0 + * it.documentationLevel = DocumentationLevel::NORMAL + * ] + * solution = reasoner.solve(problem, alloyConfig, workspace) + //*/ + // ///////////////////////////////////////////////////// + + var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 + var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 + + println("Problem solved") + println("Time was: " + totalTimeMin + ":" + totalTimeSec) } - - + } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend index 363b9356..50639577 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend @@ -1,33 +1,108 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import functionalarchitecture.FunctionalarchitecturePackage -import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns +import ca.mcgill.ecse.dslreasoner.vampire.queries +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace +import java.util.HashMap import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl class FileSystemTest { def static void main(String[] args) { - //Workspace setup + val Ecore2Logic ecore2Logic = new Ecore2Logic + val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) + val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic + + // Workspace setup val inputs = new FileSystemWorkspace('''initialModels/''', "") val workspace = new FileSystemWorkspace('''output/FAMTest/''', "") workspace.initAndClear - - //Logicproblem writing setup + + // Logicproblem writing setup val reg = Resource.Factory.Registry.INSTANCE val map = reg.extensionToFactoryMap map.put("logicproblem", new XMIResourceFactoryImpl) println("Input and output workspaces are created") - val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) - val partialModel = GeneralTest.loadPartialModel(inputs, "FunctionalArchitectureModel.xmi") - val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) + val metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE) + val partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi") + //val queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance) println("DSL loaded") - - GeneralTest.createAndSolveProblem(metamodel, partialModel, queries, workspace) + + val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) + var problem = modelGenerationProblem.output +// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output +// problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output + workspace.writeModel(problem, "Fam.logicproblem") + + println("Problem created") + + // Start Time + var startTime = System.currentTimeMillis + + var LogicReasoner reasoner + // * + reasoner = new VampireSolver + + // ///////////////////////////////////////////////////// + // Minimum Scope + val classMapMin = new HashMap +// classMapMin.put(Function, 1) +// classMapMin.put(FunctionalInterface, 2) +// classMapMin.put(FunctionalOutput, 3) + val typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Maximum Scope + val classMapMax = new HashMap +// classMapMax.put(Function, 5) +// classMapMax.put(FunctionalInterface, 2) +// classMapMax.put(FunctionalOutput, 4) + val typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Define Config File + val vampireConfig = new VampireSolverConfiguration => [ + // add configuration things, in config file first + it.documentationLevel = DocumentationLevel::FULL + + it.typeScopes.minNewElements = 4 + it.typeScopes.maxNewElements = 5 + if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin + if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax + it.contCycleLevel = 5 + it.uniquenessDuplicates = false + ] + + var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) + + /*/ + * + * reasoner = new AlloySolver + * val alloyConfig = new AlloySolverConfiguration => [ + * it.typeScopes.maxNewElements = 7 + * it.typeScopes.minNewElements = 3 + * it.solutionScope.numberOfRequiredSolution = 1 + * it.typeScopes.maxNewIntegers = 0 + * it.documentationLevel = DocumentationLevel::NORMAL + * ] + * solution = reasoner.solve(problem, alloyConfig, workspace) + //*/ + // ///////////////////////////////////////////////////// + var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 + var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 + + println("Problem solved") + println("Time was: " + totalTimeMin + ":" + totalTimeSec) } - - + } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend index 949abe87..89375801 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.xtend @@ -1,25 +1,14 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguageFactory -import functionalarchitecture.Function -import functionalarchitecture.FunctionalInterface -import functionalarchitecture.FunctionalOutput import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult -import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace import java.util.HashMap import java.util.List +import java.util.Map import org.eclipse.emf.ecore.EAttribute import org.eclipse.emf.ecore.EClass import org.eclipse.emf.ecore.EEnum @@ -30,100 +19,18 @@ import org.eclipse.emf.ecore.EReference import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl import org.eclipse.viatra.query.runtime.api.IQueryGroup -import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel -class GeneralTest { - def static String createAndSolveProblem(EcoreMetamodelDescriptor metamodel, List partialModel, - ViatraQuerySetDescriptor queries, FileSystemWorkspace workspace) { - val extension VampireLanguageFactory factory = VampireLanguageFactory.eINSTANCE - val Ecore2Logic ecore2Logic = new Ecore2Logic - val Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic) - val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) - val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic - - val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) - var problem = modelGenerationProblem.output -// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output -// problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output - workspace.writeModel(problem, "Fam.logicproblem") - - println("Problem created") - - var startTime = System.currentTimeMillis - - var LogicResult solution - var LogicReasoner reasoner - - // * - reasoner = new VampireSolver - - // Setting up scope - val typeMapMin = new HashMap - val typeMapMax = new HashMap - val list2MapMin = metamodel.classes.toMap[s|s.name] - val list2MapMax = metamodel.classes.toMap[s|s.name] - - // Minimum Scope - typeMapMin.put(ecore2Logic.TypeofEClass(modelGenerationProblem.trace, - list2MapMin.get(Function.simpleName) - ), 1) - typeMapMin.put(ecore2Logic.TypeofEClass(modelGenerationProblem.trace, - list2MapMin.get(FunctionalInterface.simpleName) - ), 2) - typeMapMin.put(ecore2Logic.TypeofEClass(modelGenerationProblem.trace, - list2MapMin.get(FunctionalOutput.simpleName) - ), 3) - - // Maximum Scope - typeMapMax.put(ecore2Logic.TypeofEClass( - modelGenerationProblem.trace, - list2MapMax.get(Function.simpleName) - ), 5) - typeMapMax.put(ecore2Logic.TypeofEClass( - modelGenerationProblem.trace, - list2MapMax.get(FunctionalInterface.simpleName) - ), 2) - typeMapMax.put(ecore2Logic.TypeofEClass( - modelGenerationProblem.trace, - list2MapMax.get(FunctionalOutput.simpleName) - ), 4) - - // Configuration - val vampireConfig = new VampireSolverConfiguration => [ - // add configuration things, in config file first - it.documentationLevel = DocumentationLevel::FULL - it.typeScopes.minNewElements = 4 - it.typeScopes.maxNewElements = 25 - it.typeScopes.minNewElementsByType = typeMapMin - it.typeScopes.maxNewElementsByType = typeMapMax - it.contCycleLevel = 5 - it.uniquenessDuplicates = false - ] - solution = reasoner.solve(problem, vampireConfig, workspace) - - /*/ - * - * reasoner = new AlloySolver - * val alloyConfig = new AlloySolverConfiguration => [ - * it.typeScopes.maxNewElements = 7 - * it.typeScopes.minNewElements = 3 - * it.solutionScope.numberOfRequiredSolution = 1 - * it.typeScopes.maxNewIntegers = 0 - * it.documentationLevel = DocumentationLevel::NORMAL - * ] - * solution = reasoner.solve(problem, alloyConfig, workspace) - //*/ - - - var totalTimeMin = (System.currentTimeMillis - startTime)/60000 - var totalTimeSec = ((System.currentTimeMillis - startTime)/1000)% 60 - - println("Problem solved") - println("Time was: " + totalTimeMin + ":" + totalTimeSec) - - - +class GeneralTest { + def static Map getTypeMap(Map classMap, EcoreMetamodelDescriptor metamodel, Ecore2Logic e2l, Ecore2Logic_Trace trace) { + val typeMap = new HashMap + val listMap = metamodel.classes.toMap[s|s.name] + for (Class elem : classMap.keySet) { + typeMap.put(e2l.TypeofEClass( + trace, listMap.get(elem.simpleName) + ), classMap.get(elem)) + } + return typeMap } def static loadMetamodel(EPackage pckg) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend index eb3f4b14..1fac968b 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend @@ -1,34 +1,108 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import functionalarchitecture.FunctionalarchitecturePackage +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace +import java.util.HashMap import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl -import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries.YakinduPatterns class YakinduTest { def static void main(String[] args) { - //Workspace setup + val Ecore2Logic ecore2Logic = new Ecore2Logic + val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) + val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic + + // Workspace setup val inputs = new FileSystemWorkspace('''initialModels/''', "") val workspace = new FileSystemWorkspace('''output/YakinduTest/''', "") workspace.initAndClear - - //Logicproblem writing setup + + // Logicproblem writing setup val reg = Resource.Factory.Registry.INSTANCE val map = reg.extensionToFactoryMap map.put("logicproblem", new XMIResourceFactoryImpl) println("Input and output workspaces are created") - val metamodel = GeneralTest.loadMetamodel(YakindummPackage.eINSTANCE) - val partialModel = GeneralTest.loadPartialModel(inputs, "Yakindu.xmi") + val metamodel = GeneralTest.loadMetamodel(yakinduPackage.eINSTANCE) + val partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/yakinduinstance.xmi") // val queries = GeneralTest.loadQueries(metamodel, FamPa + val queries = null println("DSL loaded") - -// GeneralTest.createAndSolveProblem(metamodel, partialModel, queries, workspace) + + val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) + var problem = modelGenerationProblem.output +// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output +// problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output + workspace.writeModel(problem, "Yakindu.logicproblem") + + println("Problem created") + + // Start Time + var startTime = System.currentTimeMillis + + var LogicReasoner reasoner + // * + reasoner = new VampireSolver + + // ///////////////////////////////////////////////////// + // Minimum Scope + val classMapMin = new HashMap +// classMapMin.put(Function, 1) +// classMapMin.put(FunctionalInterface, 2) +// classMapMin.put(FunctionalOutput, 3) + val typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Maximum Scope + val classMapMax = new HashMap +// classMapMax.put(Function, 5) +// classMapMax.put(FunctionalInterface, 2) +// classMapMax.put(FunctionalOutput, 4) + val typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.trace) + + // Define Config File + val vampireConfig = new VampireSolverConfiguration => [ + // add configuration things, in config file first + it.documentationLevel = DocumentationLevel::FULL + + it.typeScopes.minNewElements = 20 + it.typeScopes.maxNewElements = 30 + if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin + if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax + it.contCycleLevel = 5 + it.uniquenessDuplicates = false + ] + + var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) + + /*/ + * + * reasoner = new AlloySolver + * val alloyConfig = new AlloySolverConfiguration => [ + * it.typeScopes.maxNewElements = 7 + * it.typeScopes.minNewElements = 3 + * it.solutionScope.numberOfRequiredSolution = 1 + * it.typeScopes.maxNewIntegers = 0 + * it.documentationLevel = DocumentationLevel::NORMAL + * ] + * solution = reasoner.solve(problem, alloyConfig, workspace) + //*/ + // ///////////////////////////////////////////////////// + var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 + var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 + + println("Problem solved") + println("Time was: " + totalTimeMin + ":" + totalTimeSec) } - - + } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 7f92eba4..55d90ac7 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 67bf34bd..8eeb2d28 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index 093855d8..ab6aaf6e 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index 2df2ba62..cd75a66c 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 0c97e8d1..1b920064 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index 7b4bb578..5fc2a391 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -2,37 +2,110 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; import ca.mcgill.ecse.dslreasoner.vampire.queries.FamPatterns; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; +import functionalarchitecture.Function; +import functionalarchitecture.FunctionalOutput; import functionalarchitecture.FunctionalarchitecturePackage; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; +import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; +import java.util.HashMap; import java.util.Map; import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.resource.Resource; import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.ObjectExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class FAMTest { public static void main(final String[] args) { - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FAMTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; - final Map map = reg.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - map.put("logicproblem", _xMIResourceFactoryImpl); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "FaModel.xmi"); - final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); - InputOutput.println("DSL loaded"); - GeneralTest.createAndSolveProblem(metamodel, partialModel, queries, workspace); + try { + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/FAMTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; + final Map map = reg.getExtensionToFactoryMap(); + XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); + map.put("logicproblem", _xMIResourceFactoryImpl); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "FaModel.xmi"); + final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); + InputOutput.println("DSL loaded"); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + LogicProblem problem = modelGenerationProblem.getOutput(); + workspace.writeModel(problem, "Fam.logicproblem"); + InputOutput.println("Problem created"); + long startTime = System.currentTimeMillis(); + LogicReasoner reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + final HashMap classMapMin = new HashMap(); + classMapMin.put(Function.class, Integer.valueOf(1)); + classMapMin.put(functionalarchitecture.FunctionalInterface.class, Integer.valueOf(2)); + classMapMin.put(FunctionalOutput.class, Integer.valueOf(3)); + final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + final HashMap classMapMax = new HashMap(); + classMapMax.put(Function.class, Integer.valueOf(5)); + classMapMax.put(functionalarchitecture.FunctionalInterface.class, Integer.valueOf(2)); + classMapMax.put(FunctionalOutput.class, Integer.valueOf(4)); + final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + it.typeScopes.minNewElements = 4; + it.typeScopes.maxNewElements = 5; + int _size = typeMapMin.size(); + boolean _notEquals = (_size != 0); + if (_notEquals) { + it.typeScopes.minNewElementsByType = typeMapMin; + } + int _size_1 = typeMapMin.size(); + boolean _notEquals_1 = (_size_1 != 0); + if (_notEquals_1) { + it.typeScopes.maxNewElementsByType = typeMapMax; + } + it.contCycleLevel = 5; + it.uniquenessDuplicates = false; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); + long _currentTimeMillis = System.currentTimeMillis(); + long _minus = (_currentTimeMillis - startTime); + long totalTimeMin = (_minus / 60000); + long _currentTimeMillis_1 = System.currentTimeMillis(); + long _minus_1 = (_currentTimeMillis_1 - startTime); + long _divide = (_minus_1 / 1000); + long totalTimeSec = (_divide % 60); + InputOutput.println("Problem solved"); + InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java index 5994b4b4..eedec995 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java @@ -1,38 +1,100 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import functionalarchitecture.FunctionalarchitecturePackage; -import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; -import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; +import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; +import java.util.HashMap; import java.util.Map; import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.resource.Resource; import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.ObjectExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class FileSystemTest { public static void main(final String[] args) { - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FAMTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; - final Map map = reg.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - map.put("logicproblem", _xMIResourceFactoryImpl); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "FunctionalArchitectureModel.xmi"); - final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); - InputOutput.println("DSL loaded"); - GeneralTest.createAndSolveProblem(metamodel, partialModel, queries, workspace); + try { + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/FAMTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; + final Map map = reg.getExtensionToFactoryMap(); + XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); + map.put("logicproblem", _xMIResourceFactoryImpl); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); + InputOutput.println("DSL loaded"); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + LogicProblem problem = modelGenerationProblem.getOutput(); + workspace.writeModel(problem, "Fam.logicproblem"); + InputOutput.println("Problem created"); + long startTime = System.currentTimeMillis(); + LogicReasoner reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + final HashMap classMapMin = new HashMap(); + final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + final HashMap classMapMax = new HashMap(); + final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + it.typeScopes.minNewElements = 4; + it.typeScopes.maxNewElements = 5; + int _size = typeMapMin.size(); + boolean _notEquals = (_size != 0); + if (_notEquals) { + it.typeScopes.minNewElementsByType = typeMapMin; + } + int _size_1 = typeMapMin.size(); + boolean _notEquals_1 = (_size_1 != 0); + if (_notEquals_1) { + it.typeScopes.maxNewElementsByType = typeMapMax; + } + it.contCycleLevel = 5; + it.uniquenessDuplicates = false; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); + long _currentTimeMillis = System.currentTimeMillis(); + long _minus = (_currentTimeMillis - startTime); + long totalTimeMin = (_minus / 60000); + long _currentTimeMillis_1 = System.currentTimeMillis(); + long _minus_1 = (_currentTimeMillis_1 - startTime); + long _divide = (_minus_1 / 1000); + long totalTimeSec = (_divide % 60); + InputOutput.println("Problem solved"); + InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java index 0150ef1d..0bb8f76e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/GeneralTest.java @@ -1,27 +1,12 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguageFactory; import com.google.common.base.Objects; import com.google.common.collect.Iterables; -import functionalarchitecture.Function; -import functionalarchitecture.FunctionalOutput; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; -import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; -import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace; import java.util.Collections; import java.util.HashMap; @@ -43,94 +28,24 @@ import org.eclipse.viatra.query.runtime.api.IQueryGroup; import org.eclipse.viatra.query.runtime.api.IQuerySpecification; import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; import org.eclipse.xtext.xbase.lib.CollectionLiterals; -import org.eclipse.xtext.xbase.lib.Exceptions; -import org.eclipse.xtext.xbase.lib.Extension; import org.eclipse.xtext.xbase.lib.Functions.Function1; -import org.eclipse.xtext.xbase.lib.InputOutput; import org.eclipse.xtext.xbase.lib.IterableExtensions; import org.eclipse.xtext.xbase.lib.ListExtensions; -import org.eclipse.xtext.xbase.lib.ObjectExtensions; -import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class GeneralTest { - public static String createAndSolveProblem(final EcoreMetamodelDescriptor metamodel, final List partialModel, final ViatraQuerySetDescriptor queries, final FileSystemWorkspace workspace) { - try { - String _xblockexpression = null; - { - @Extension - final VampireLanguageFactory factory = VampireLanguageFactory.eINSTANCE; - final Ecore2Logic ecore2Logic = new Ecore2Logic(); - final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); - final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); - final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); - Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); - final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); - LogicProblem problem = modelGenerationProblem.getOutput(); - workspace.writeModel(problem, "Fam.logicproblem"); - InputOutput.println("Problem created"); - long startTime = System.currentTimeMillis(); - LogicResult solution = null; - LogicReasoner reasoner = null; - VampireSolver _vampireSolver = new VampireSolver(); - reasoner = _vampireSolver; - final HashMap typeMapMin = new HashMap(); - final HashMap typeMapMax = new HashMap(); - final Function1 _function = (EClass s) -> { - return s.getName(); - }; - final Map list2MapMin = IterableExtensions.toMap(metamodel.getClasses(), _function); - final Function1 _function_1 = (EClass s) -> { - return s.getName(); - }; - final Map list2MapMax = IterableExtensions.toMap(metamodel.getClasses(), _function_1); - typeMapMin.put( - ecore2Logic.TypeofEClass(modelGenerationProblem.getTrace(), - list2MapMin.get(Function.class.getSimpleName())), Integer.valueOf(1)); - typeMapMin.put( - ecore2Logic.TypeofEClass(modelGenerationProblem.getTrace(), - list2MapMin.get(functionalarchitecture.FunctionalInterface.class.getSimpleName())), Integer.valueOf(2)); - typeMapMin.put( - ecore2Logic.TypeofEClass(modelGenerationProblem.getTrace(), - list2MapMin.get(FunctionalOutput.class.getSimpleName())), Integer.valueOf(3)); - typeMapMax.put( - ecore2Logic.TypeofEClass( - modelGenerationProblem.getTrace(), - list2MapMax.get(Function.class.getSimpleName())), Integer.valueOf(5)); - typeMapMax.put( - ecore2Logic.TypeofEClass( - modelGenerationProblem.getTrace(), - list2MapMax.get(functionalarchitecture.FunctionalInterface.class.getSimpleName())), Integer.valueOf(2)); - typeMapMax.put( - ecore2Logic.TypeofEClass( - modelGenerationProblem.getTrace(), - list2MapMax.get(FunctionalOutput.class.getSimpleName())), Integer.valueOf(4)); - VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); - final Procedure1 _function_2 = (VampireSolverConfiguration it) -> { - it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 4; - it.typeScopes.maxNewElements = 25; - it.typeScopes.minNewElementsByType = typeMapMin; - it.typeScopes.maxNewElementsByType = typeMapMax; - it.contCycleLevel = 5; - it.uniquenessDuplicates = false; - }; - final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function_2); - solution = reasoner.solve(problem, vampireConfig, workspace); - long _currentTimeMillis = System.currentTimeMillis(); - long _minus = (_currentTimeMillis - startTime); - long totalTimeMin = (_minus / 60000); - long _currentTimeMillis_1 = System.currentTimeMillis(); - long _minus_1 = (_currentTimeMillis_1 - startTime); - long _divide = (_minus_1 / 1000); - long totalTimeSec = (_divide % 60); - InputOutput.println("Problem solved"); - _xblockexpression = InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); - } - return _xblockexpression; - } catch (Throwable _e) { - throw Exceptions.sneakyThrow(_e); + public static Map getTypeMap(final Map classMap, final EcoreMetamodelDescriptor metamodel, final Ecore2Logic e2l, final Ecore2Logic_Trace trace) { + final HashMap typeMap = new HashMap(); + final Function1 _function = (EClass s) -> { + return s.getName(); + }; + final Map listMap = IterableExtensions.toMap(metamodel.getClasses(), _function); + Set _keySet = classMap.keySet(); + for (final Class elem : _keySet) { + typeMap.put( + e2l.TypeofEClass(trace, listMap.get(elem.getSimpleName())), classMap.get(elem)); } + return typeMap; } public static EcoreMetamodelDescriptor loadMetamodel(final EPackage pckg) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java index bea4e8a6..81079764 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java @@ -1,34 +1,101 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; +import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; +import java.util.HashMap; import java.util.Map; import org.eclipse.emf.common.util.EList; import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.resource.Resource; import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.ObjectExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class YakinduTest { public static void main(final String[] args) { - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/YakinduTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; - final Map map = reg.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - map.put("logicproblem", _xMIResourceFactoryImpl); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(YakindummPackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "Yakindu.xmi"); - InputOutput.println("DSL loaded"); + try { + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/YakinduTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; + final Map map = reg.getExtensionToFactoryMap(); + XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); + map.put("logicproblem", _xMIResourceFactoryImpl); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(yakinduPackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/yakinduinstance.xmi"); + final Object queries = null; + InputOutput.println("DSL loaded"); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + LogicProblem problem = modelGenerationProblem.getOutput(); + workspace.writeModel(problem, "Yakindu.logicproblem"); + InputOutput.println("Problem created"); + long startTime = System.currentTimeMillis(); + LogicReasoner reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + final HashMap classMapMin = new HashMap(); + final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + final HashMap classMapMax = new HashMap(); + final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + it.typeScopes.minNewElements = 20; + it.typeScopes.maxNewElements = 30; + int _size = typeMapMin.size(); + boolean _notEquals = (_size != 0); + if (_notEquals) { + it.typeScopes.minNewElementsByType = typeMapMin; + } + int _size_1 = typeMapMin.size(); + boolean _notEquals_1 = (_size_1 != 0); + if (_notEquals_1) { + it.typeScopes.maxNewElementsByType = typeMapMax; + } + it.contCycleLevel = 5; + it.uniquenessDuplicates = false; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); + long _currentTimeMillis = System.currentTimeMillis(); + long _minus = (_currentTimeMillis - startTime); + long totalTimeMin = (_minus / 60000); + long _currentTimeMillis_1 = System.currentTimeMillis(); + long _minus_1 = (_currentTimeMillis_1 - startTime); + long _divide = (_minus_1 / 1000); + long totalTimeSec = (_divide % 60); + InputOutput.println("Problem solved"); + InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index c0481fd8..29f8df00 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 53dc2a03..72d33e5d 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 6c84f917..e9c4c0a4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 2f8149678539a94f2f4ca2e7ff5640ff5d7087cc Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Mon, 15 Apr 2019 00:06:29 -0400 Subject: VAMPIRE: close #22, improve test structure for #39, .vql file trouble --- .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1701 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2526 -> 2526 bytes .../plugin.xml | 29 + .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes ...c2VampireLanguageMapper_ContainmentMapper.xtend | 12 +- ...ogic2VampireLanguageMapper_RelationMapper.xtend | 183 ++--- .../Logic2VampireLanguageMapper_ScopeMapper.xtend | 1 + .../Logic2VampireLanguageMapper_Support.xtend | 12 +- .../Logic2VampireLanguageMapper_TypeMapper.xtend | 23 +- .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 5892 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18156 -> 18156 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4215 -> 4215 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 10551 -> 10674 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 8209 -> 6457 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 9839 -> 9839 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13093 -> 13046 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 10705 -> 10792 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 4908 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes ...ic2VampireLanguageMapper_ContainmentMapper.java | 15 +- ...Logic2VampireLanguageMapper_RelationMapper.java | 159 +---- .../Logic2VampireLanguageMapper_Support.java | 18 +- .../Logic2VampireLanguageMapper_TypeMapper.java | 25 +- .../metamodels/filesystem.aird | 379 +++++++++++ .../metamodels/yakindu.aird | 111 ++- .../plugin.xml | 7 - .../test/fam/queries/TerminatorAndInformation.java | 747 --------------------- .../.classpath | 1 + .../META-INF/MANIFEST.MF | 6 +- .../initialModels/FAM/FaModel.xmi | 7 + .../initialModels/FaModel.xmi | 7 - .../output/FAMTest/Fam.logicproblem | 7 +- .../output/FAMTest/vampireProblem.tptp | 72 -- .../plugin.xml | 20 +- .../dslreasoner/vampire/queries/FamPatterns.java | 53 -- .../vampire/queries/TerminatorAndInformation.java | 747 --------------------- .../ecse/dslreasoner/vampire/icse/EcoreTest.xtend | 76 +-- .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 8 +- .../dslreasoner/vampire/icse/FileSystemTest.xtend | 13 +- .../dslreasoner/vampire/icse/YakinduTest.xtend | 6 +- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 6358 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6825 -> 6296 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 6088 -> 6618 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6456 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 6042 -> 6040 bytes .../ecse/dslreasoner/vampire/icse/EcoreTest.java | 61 +- .../ecse/dslreasoner/vampire/icse/FAMTest.java | 7 +- .../dslreasoner/vampire/icse/FileSystemTest.java | 11 +- .../ecse/dslreasoner/vampire/icse/YakinduTest.java | 4 +- .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes 69 files changed, 735 insertions(+), 2092 deletions(-) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.aird delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FAM/FaModel.xmi delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FaModel.xmi delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/TerminatorAndInformation.java (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index d6392a0b..9edfdac5 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index c97efa0f..0979473a 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml index 9ace526f..8069f168 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml @@ -3,6 +3,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 024dcab9..10495630 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 7e128ad1..295d9ec2 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 0bf8ccc6..83b00f77 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index 58a18bbb..f8a7a2f3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 205afcc4..544f5811 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index b388bd43..62aac4ca 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 3092be97..31d4543e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 8b23f34d..7b230b65 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 84682c47..a24c2795 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index e3f67a0c..b35605ae 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index bf354098..5e9cd3bd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index da62f4c1..0001d80f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index 482b884e..b189414a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 81c1f803..b4eec95c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend index 395b4305..8e0e0b11 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend @@ -39,7 +39,15 @@ class Logic2VampireLanguageMapper_ContainmentMapper { for (l : relationsList) { var pointingTo = (l.parameters.get(1) as ComplexTypeReference).referred as Type containmentListCopy.remove(pointingTo) - for (c : pointingTo.subtypes) { + var List allSubtypes = newArrayList + support.listSubtypes(pointingTo, allSubtypes) + for (c : allSubtypes) { + containmentListCopy.remove(c) + } + } + + for (c : containmentListCopy) { + if(c.isIsAbstract) { containmentListCopy.remove(c) } } @@ -135,7 +143,7 @@ class Logic2VampireLanguageMapper_ContainmentMapper { // STEP 2 CONT'D for (e : type2cont.entrySet) { val relFormula = createVLSFofFormula => [ - it.name = support.toIDMultiple("containment", e.key.constant.toString) + it.name = support.toIDMultiple("containment_contained", e.key.constant.toString) it.fofRole = "axiom" it.fofFormula = createVLSUniversalQuantifier => [ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.xtend index 0ae06bc3..2dec281d 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.xtend @@ -44,9 +44,20 @@ class Logic2VampireLanguageMapper_RelationMapper { } + //deciding name of relation + val nameArray = r.name.split(" ") + var relNameVar = "" + if (nameArray.length == 3) { + relNameVar = support.toIDMultiple(nameArray.get(0), nameArray.get(2)) + } + else { + relNameVar = r.name + } + val relName = relNameVar + val comply = createVLSFofFormula=> [ - val nameArray = r.name.split(" ") - it.name = support.toIDMultiple("compliance", nameArray.get(0), nameArray.get(2)) + + it.name = support.toIDMultiple("compliance", relName) it.fofRole = "axiom" it.fofFormula = createVLSUniversalQuantifier => [ for (v : relVar2VLS) { @@ -54,7 +65,7 @@ class Logic2VampireLanguageMapper_RelationMapper { } it.operand = createVLSImplies => [ val rel = createVLSFunction => [ - it.constant = support.toIDMultiple("r", nameArray.get(0), nameArray.get(2)) + it.constant = support.toIDMultiple("r", relName) for (v : relVar2VLS) { it.terms += support.duplicate(v) } @@ -71,89 +82,89 @@ class Logic2VampireLanguageMapper_RelationMapper { def dispatch public void transformRelation(RelationDefinition reldef, Logic2VampireLanguageMapperTrace trace) { - // 1. store all variables in support wrt their name - // 1.1 if variable has type, creating list of type declarations -// val VLSVariable variable = createVLSVariable => [it.name = "A"] - val Map relationVar2VLS = new HashMap - val Map relationVar2TypeDecComply = new HashMap - val Map relationVar2TypeDecRes = new HashMap - val typedefs = new ArrayList - - for (variable : reldef.variables) { - val v = createVLSVariable => [ - it.name = support.toIDMultiple("V", variable.name) - ] - relationVar2VLS.put(variable, v) - - val varTypeComply = createVLSFunction => [ - it.constant = support.toIDMultiple("t", (variable.range as ComplexTypeReference).referred.name) - it.terms += support.duplicate(v) - ] - relationVar2TypeDecComply.put(variable, varTypeComply) - relationVar2TypeDecRes.put(variable, support.duplicate(varTypeComply)) - } - val nameArray = reldef.name.split(" ") - val comply = createVLSFofFormula => [ - it.name = support.toIDMultiple("compliance", nameArray.get(nameArray.length - 2), - nameArray.get(nameArray.length - 1)) - it.fofRole = "axiom" - it.fofFormula = createVLSUniversalQuantifier => [ - for (variable : reldef.variables) { - it.variables += support.duplicate(variable.lookup(relationVar2VLS)) - - } - it.operand = createVLSImplies => [ - it.left = createVLSFunction => [ - it.constant = support.toIDMultiple("rel", reldef.name) - for (variable : reldef.variables) { - val v = createVLSVariable => [ - it.name = variable.lookup(relationVar2VLS).name - ] - it.terms += v - } - ] - it.right = support.unfoldAnd(new ArrayList(relationVar2TypeDecComply.values)) - ] - ] - ] - - val res = createVLSFofFormula => [ - it.name = support.toIDMultiple("relation", nameArray.get(nameArray.length - 2), - nameArray.get(nameArray.length - 1)) - it.fofRole = "axiom" - it.fofFormula = createVLSUniversalQuantifier => [ - for (variable : reldef.variables) { - val v = createVLSVariable => [ - it.name = variable.lookup(relationVar2VLS).name - ] - it.variables += v - - } - it.operand = createVLSImplies => [ - it.left = support.unfoldAnd(new ArrayList(relationVar2TypeDecRes.values)) - it.right = createVLSEquivalent => [ - it.left = createVLSFunction => [ - it.constant = support.toIDMultiple("rel", reldef.name) - for (variable : reldef.variables) { - val v = createVLSVariable => [ - it.name = variable.lookup(relationVar2VLS).name - ] - it.terms += v - - } - ] - it.right = base.transformTerm(reldef.value, trace, relationVar2VLS) - ] - - ] - - ] - - ] - - // trace.relationDefinition2Predicate.put(r,res) - trace.specification.formulas += comply; - trace.specification.formulas += res; +// // 1. store all variables in support wrt their name +// // 1.1 if variable has type, creating list of type declarations +//// val VLSVariable variable = createVLSVariable => [it.name = "A"] +// val Map relationVar2VLS = new HashMap +// val Map relationVar2TypeDecComply = new HashMap +// val Map relationVar2TypeDecRes = new HashMap +// val typedefs = new ArrayList +// +// for (variable : reldef.variables) { +// val v = createVLSVariable => [ +// it.name = support.toIDMultiple("V", variable.name) +// ] +// relationVar2VLS.put(variable, v) +// +// val varTypeComply = createVLSFunction => [ +// it.constant = support.toIDMultiple("t", (variable.range as ComplexTypeReference).referred.name) +// it.terms += support.duplicate(v) +// ] +// relationVar2TypeDecComply.put(variable, varTypeComply) +// relationVar2TypeDecRes.put(variable, support.duplicate(varTypeComply)) +// } +// val nameArray = reldef.name.split(" ") +// val comply = createVLSFofFormula => [ +// it.name = support.toIDMultiple("compliance", nameArray.get(nameArray.length - 2), +// nameArray.get(nameArray.length - 1)) +// it.fofRole = "axiom" +// it.fofFormula = createVLSUniversalQuantifier => [ +// for (variable : reldef.variables) { +// it.variables += support.duplicate(variable.lookup(relationVar2VLS)) +// +// } +// it.operand = createVLSImplies => [ +// it.left = createVLSFunction => [ +// it.constant = support.toIDMultiple("rel", reldef.name) +// for (variable : reldef.variables) { +// val v = createVLSVariable => [ +// it.name = variable.lookup(relationVar2VLS).name +// ] +// it.terms += v +// } +// ] +// it.right = support.unfoldAnd(new ArrayList(relationVar2TypeDecComply.values)) +// ] +// ] +// ] +// +// val res = createVLSFofFormula => [ +// it.name = support.toIDMultiple("relation", nameArray.get(nameArray.length - 2), +// nameArray.get(nameArray.length - 1)) +// it.fofRole = "axiom" +// it.fofFormula = createVLSUniversalQuantifier => [ +// for (variable : reldef.variables) { +// val v = createVLSVariable => [ +// it.name = variable.lookup(relationVar2VLS).name +// ] +// it.variables += v +// +// } +// it.operand = createVLSImplies => [ +// it.left = support.unfoldAnd(new ArrayList(relationVar2TypeDecRes.values)) +// it.right = createVLSEquivalent => [ +// it.left = createVLSFunction => [ +// it.constant = support.toIDMultiple("rel", reldef.name) +// for (variable : reldef.variables) { +// val v = createVLSVariable => [ +// it.name = variable.lookup(relationVar2VLS).name +// ] +// it.terms += v +// +// } +// ] +// it.right = base.transformTerm(reldef.value, trace, relationVar2VLS) +// ] +// +// ] +// +// ] +// +// ] +// +// // trace.relationDefinition2Predicate.put(r,res) +// trace.specification.formulas += comply; +// trace.specification.formulas += res; } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend index 0a8812e4..4a8d2827 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend @@ -29,6 +29,7 @@ class Logic2VampireLanguageMapper_ScopeMapper { // TODO HANDLE ERROR RELATED TO SUM(MIN TYPES)+1(for root) > MAX OBJECTS // TODO HANDLE // 1. make a list of constants equaling the min number of specified objects + //These numbers do not include enums or initial model elements val GLOBAL_MIN = config.typeScopes.minNewElements val GLOBAL_MAX = config.typeScopes.maxNewElements diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.xtend index 195b89bb..680213ab 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.xtend @@ -273,15 +273,11 @@ class Logic2VampireLanguageMapper_Support { } } - def protected List listSubtypes(Type t) { - var List allSubtypes = newArrayList - if (!t.subtypes.isEmpty) { - for (subt : t.subtypes) { - allSubtypes.add(subt) - allSubtypes = listSubtypes(subt) - } + def protected void listSubtypes(Type t, List allSubtypes) { + for (subt : t.subtypes) { + allSubtypes.add(subt) + listSubtypes(subt, allSubtypes) } - return allSubtypes } def protected withAddition(Map map1, Map map2) { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend index 3bc945df..2f3af593 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend @@ -44,14 +44,19 @@ class Logic2VampireLanguageMapper_TypeMapper { // Create a VLSFunction for each Enum Element val List orElems = newArrayList + for (e : type.elements) { + val nameArray = e.name.split(" ") + var relNameVar = "" + if (nameArray.length == 3) { + relNameVar = support.toIDMultiple(nameArray.get(0), nameArray.get(2)) + } else { + relNameVar = e.name + } + val relName = relNameVar + val enumElemPred = createVLSFunction => [ - val splitName = e.name.split(" ") - if (splitName.length > 2) { - it.constant = support.toIDMultiple("e", splitName.get(0), splitName.get(2)) - } else { - it.constant = support.toIDMultiple("e", splitName.get(0)) - } + it.constant = support.toIDMultiple("e", relName) it.terms += support.duplicate(variable) ] trace.element2Predicate.put(e, enumElemPred) @@ -80,7 +85,7 @@ class Logic2VampireLanguageMapper_TypeMapper { // Implement Enum Inheritence Hierarchy val res = createVLSFofFormula => [ - it.name = support.toIDMultiple("typeDef", type.name.split(" ").get(0)) + it.name = support.toIDMultiple("typeDef", type.lookup(trace.type2Predicate).constant.toString) it.fofRole = "axiom" it.fofFormula = createVLSUniversalQuantifier => [ it.variables += support.duplicate(variable) @@ -105,9 +110,9 @@ class Logic2VampireLanguageMapper_TypeMapper { val cst = support.toConstant(cstTerm) trace.uniqueInstances.add(cst) - val index = i + val index = i-globalCounter val enumScope = createVLSFofFormula => [ - it.name = support.toIDMultiple("enumScope", type.name.split(" ").get(0), + it.name = support.toIDMultiple("enumScope", type.lookup(trace.type2Predicate).constant.toString, type.elements.get(index).name.split(" ").get(0)) it.fofRole = "axiom" it.fofFormula = createVLSUniversalQuantifier => [ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index 43e1e477..1ea7e30a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 4e6f6ca0..ee06cb39 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 707a6089..648d9600 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 3171324f..a02821a5 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 301df7fa..b01f92a6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 5e53ea26..7634af4b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index b378ed09..4906adfc 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index 605ac88c..e2c945e3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 0c289e29..f465506c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index cb72fd90..e046604a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index cfe1e8cd..aff62dca 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index c2079147..7212cce7 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 3c70bc14..d23bacad 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 9ef20b23..be78cace 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java index 4cdc7e6a..9deab87f 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java @@ -64,12 +64,19 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { Type _referred = ((ComplexTypeReference) _get).getReferred(); Type pointingTo = ((Type) _referred); containmentListCopy.remove(pointingTo); - EList _subtypes = pointingTo.getSubtypes(); - for (final Type c : _subtypes) { + List allSubtypes = CollectionLiterals.newArrayList(); + this.support.listSubtypes(pointingTo, allSubtypes); + for (final Type c : allSubtypes) { containmentListCopy.remove(c); } } } + for (final Type c : containmentListCopy) { + boolean _isIsAbstract = c.isIsAbstract(); + if (_isIsAbstract) { + containmentListCopy.remove(c); + } + } final String topName = CollectionsUtil.lookup(containmentListCopy.get(0), trace.type2Predicate).getConstant().toString(); final VLSFunction topTerm = this.support.duplicate(CollectionsUtil.lookup(containmentListCopy.get(0), trace.type2Predicate)); VLSFofFormula _createVLSFofFormula = this.factory.createVLSFofFormula(); @@ -132,7 +139,7 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { final VLSFunction toFunc = CollectionsUtil.lookup(toType, trace.type2Predicate); this.addToMap(type2cont, toFunc, rel); EList _subtypes = toType.getSubtypes(); - for (final Type c : _subtypes) { + for (final Type c_1 : _subtypes) { this.addToMap(type2cont, toFunc, rel); } VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); @@ -184,7 +191,7 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { { VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); final Procedure1 _function_4 = (VLSFofFormula it) -> { - it.setName(this.support.toIDMultiple("containment", e.getKey().getConstant().toString())); + it.setName(this.support.toIDMultiple("containment_contained", e.getKey().getConstant().toString())); it.setFofRole("axiom"); VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); final Procedure1 _function_5 = (VLSUniversalQuantifier it_1) -> { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.java index d5745333..c6565f6a 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_RelationMapper.java @@ -3,7 +3,6 @@ package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapper; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapperTrace; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Logic2VampireLanguageMapper_Support; -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSEquivalent; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFofFormula; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSFunction; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSImplies; @@ -17,14 +16,10 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.RelationDeclaration; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.RelationDefinition; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.TypeReference; -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Variable; import hu.bme.mit.inf.dslreasoner.util.CollectionsUtil; import java.util.ArrayList; import java.util.Arrays; -import java.util.Collection; -import java.util.HashMap; import java.util.List; -import java.util.Map; import org.eclipse.emf.common.util.EList; import org.eclipse.xtext.xbase.lib.Conversions; import org.eclipse.xtext.xbase.lib.ExclusiveRange; @@ -64,10 +59,19 @@ public class Logic2VampireLanguageMapper_RelationMapper { relVar2TypeDecComply.add(varTypeComply); } } + final String[] nameArray = r.getName().split(" "); + String relNameVar = ""; + int _length_1 = nameArray.length; + boolean _equals = (_length_1 == 3); + if (_equals) { + relNameVar = this.support.toIDMultiple(nameArray[0], nameArray[2]); + } else { + relNameVar = r.getName(); + } + final String relName = relNameVar; VLSFofFormula _createVLSFofFormula = this.factory.createVLSFofFormula(); final Procedure1 _function = (VLSFofFormula it) -> { - final String[] nameArray = r.getName().split(" "); - it.setName(this.support.toIDMultiple("compliance", nameArray[0], nameArray[2])); + it.setName(this.support.toIDMultiple("compliance", relName)); it.setFofRole("axiom"); VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); final Procedure1 _function_1 = (VLSUniversalQuantifier it_1) -> { @@ -80,7 +84,7 @@ public class Logic2VampireLanguageMapper_RelationMapper { final Procedure1 _function_2 = (VLSImplies it_2) -> { VLSFunction _createVLSFunction = this.factory.createVLSFunction(); final Procedure1 _function_3 = (VLSFunction it_3) -> { - it_3.setConstant(this.support.toIDMultiple("r", nameArray[0], nameArray[2])); + it_3.setConstant(this.support.toIDMultiple("r", relName)); for (final VLSVariable v_1 : relVar2VLS) { EList _terms = it_3.getTerms(); VLSVariable _duplicate_1 = this.support.duplicate(v_1); @@ -104,145 +108,6 @@ public class Logic2VampireLanguageMapper_RelationMapper { } public void _transformRelation(final RelationDefinition reldef, final Logic2VampireLanguageMapperTrace trace) { - final Map relationVar2VLS = new HashMap(); - final Map relationVar2TypeDecComply = new HashMap(); - final Map relationVar2TypeDecRes = new HashMap(); - final ArrayList typedefs = new ArrayList(); - EList _variables = reldef.getVariables(); - for (final Variable variable : _variables) { - { - VLSVariable _createVLSVariable = this.factory.createVLSVariable(); - final Procedure1 _function = (VLSVariable it) -> { - it.setName(this.support.toIDMultiple("V", variable.getName())); - }; - final VLSVariable v = ObjectExtensions.operator_doubleArrow(_createVLSVariable, _function); - relationVar2VLS.put(variable, v); - VLSFunction _createVLSFunction = this.factory.createVLSFunction(); - final Procedure1 _function_1 = (VLSFunction it) -> { - TypeReference _range = variable.getRange(); - it.setConstant(this.support.toIDMultiple("t", ((ComplexTypeReference) _range).getReferred().getName())); - EList _terms = it.getTerms(); - VLSVariable _duplicate = this.support.duplicate(v); - _terms.add(_duplicate); - }; - final VLSFunction varTypeComply = ObjectExtensions.operator_doubleArrow(_createVLSFunction, _function_1); - relationVar2TypeDecComply.put(variable, varTypeComply); - relationVar2TypeDecRes.put(variable, this.support.duplicate(varTypeComply)); - } - } - final String[] nameArray = reldef.getName().split(" "); - VLSFofFormula _createVLSFofFormula = this.factory.createVLSFofFormula(); - final Procedure1 _function = (VLSFofFormula it) -> { - int _length = nameArray.length; - int _minus = (_length - 2); - int _length_1 = nameArray.length; - int _minus_1 = (_length_1 - 1); - it.setName(this.support.toIDMultiple("compliance", nameArray[_minus], - nameArray[_minus_1])); - it.setFofRole("axiom"); - VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); - final Procedure1 _function_1 = (VLSUniversalQuantifier it_1) -> { - EList _variables_1 = reldef.getVariables(); - for (final Variable variable_1 : _variables_1) { - EList _variables_2 = it_1.getVariables(); - VLSVariable _duplicate = this.support.duplicate(CollectionsUtil.lookup(variable_1, relationVar2VLS)); - _variables_2.add(_duplicate); - } - VLSImplies _createVLSImplies = this.factory.createVLSImplies(); - final Procedure1 _function_2 = (VLSImplies it_2) -> { - VLSFunction _createVLSFunction = this.factory.createVLSFunction(); - final Procedure1 _function_3 = (VLSFunction it_3) -> { - it_3.setConstant(this.support.toIDMultiple("rel", reldef.getName())); - EList _variables_3 = reldef.getVariables(); - for (final Variable variable_2 : _variables_3) { - { - VLSVariable _createVLSVariable = this.factory.createVLSVariable(); - final Procedure1 _function_4 = (VLSVariable it_4) -> { - it_4.setName(CollectionsUtil.lookup(variable_2, relationVar2VLS).getName()); - }; - final VLSVariable v = ObjectExtensions.operator_doubleArrow(_createVLSVariable, _function_4); - EList _terms = it_3.getTerms(); - _terms.add(v); - } - } - }; - VLSFunction _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSFunction, _function_3); - it_2.setLeft(_doubleArrow); - Collection _values = relationVar2TypeDecComply.values(); - ArrayList _arrayList = new ArrayList(_values); - it_2.setRight(this.support.unfoldAnd(_arrayList)); - }; - VLSImplies _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSImplies, _function_2); - it_1.setOperand(_doubleArrow); - }; - VLSUniversalQuantifier _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSUniversalQuantifier, _function_1); - it.setFofFormula(_doubleArrow); - }; - final VLSFofFormula comply = ObjectExtensions.operator_doubleArrow(_createVLSFofFormula, _function); - VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); - final Procedure1 _function_1 = (VLSFofFormula it) -> { - int _length = nameArray.length; - int _minus = (_length - 2); - int _length_1 = nameArray.length; - int _minus_1 = (_length_1 - 1); - it.setName(this.support.toIDMultiple("relation", nameArray[_minus], - nameArray[_minus_1])); - it.setFofRole("axiom"); - VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); - final Procedure1 _function_2 = (VLSUniversalQuantifier it_1) -> { - EList _variables_1 = reldef.getVariables(); - for (final Variable variable_1 : _variables_1) { - { - VLSVariable _createVLSVariable = this.factory.createVLSVariable(); - final Procedure1 _function_3 = (VLSVariable it_2) -> { - it_2.setName(CollectionsUtil.lookup(variable_1, relationVar2VLS).getName()); - }; - final VLSVariable v = ObjectExtensions.operator_doubleArrow(_createVLSVariable, _function_3); - EList _variables_2 = it_1.getVariables(); - _variables_2.add(v); - } - } - VLSImplies _createVLSImplies = this.factory.createVLSImplies(); - final Procedure1 _function_3 = (VLSImplies it_2) -> { - Collection _values = relationVar2TypeDecRes.values(); - ArrayList _arrayList = new ArrayList(_values); - it_2.setLeft(this.support.unfoldAnd(_arrayList)); - VLSEquivalent _createVLSEquivalent = this.factory.createVLSEquivalent(); - final Procedure1 _function_4 = (VLSEquivalent it_3) -> { - VLSFunction _createVLSFunction = this.factory.createVLSFunction(); - final Procedure1 _function_5 = (VLSFunction it_4) -> { - it_4.setConstant(this.support.toIDMultiple("rel", reldef.getName())); - EList _variables_2 = reldef.getVariables(); - for (final Variable variable_2 : _variables_2) { - { - VLSVariable _createVLSVariable = this.factory.createVLSVariable(); - final Procedure1 _function_6 = (VLSVariable it_5) -> { - it_5.setName(CollectionsUtil.lookup(variable_2, relationVar2VLS).getName()); - }; - final VLSVariable v = ObjectExtensions.operator_doubleArrow(_createVLSVariable, _function_6); - EList _terms = it_4.getTerms(); - _terms.add(v); - } - } - }; - VLSFunction _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSFunction, _function_5); - it_3.setLeft(_doubleArrow); - it_3.setRight(this.base.transformTerm(reldef.getValue(), trace, relationVar2VLS)); - }; - VLSEquivalent _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSEquivalent, _function_4); - it_2.setRight(_doubleArrow); - }; - VLSImplies _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSImplies, _function_3); - it_1.setOperand(_doubleArrow); - }; - VLSUniversalQuantifier _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSUniversalQuantifier, _function_2); - it.setFofFormula(_doubleArrow); - }; - final VLSFofFormula res = ObjectExtensions.operator_doubleArrow(_createVLSFofFormula_1, _function_1); - EList _formulas = trace.specification.getFormulas(); - _formulas.add(comply); - EList _formulas_1 = trace.specification.getFormulas(); - _formulas_1.add(res); } public void transformRelation(final Relation r, final Logic2VampireLanguageMapperTrace trace) { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.java index 89633ca1..f1d73bec 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_Support.java @@ -403,20 +403,14 @@ public class Logic2VampireLanguageMapper_Support { return _xifexpression; } - protected List listSubtypes(final Type t) { - List allSubtypes = CollectionLiterals.newArrayList(); - boolean _isEmpty = t.getSubtypes().isEmpty(); - boolean _not = (!_isEmpty); - if (_not) { - EList _subtypes = t.getSubtypes(); - for (final Type subt : _subtypes) { - { - allSubtypes.add(subt); - allSubtypes = this.listSubtypes(subt); - } + protected void listSubtypes(final Type t, final List allSubtypes) { + EList _subtypes = t.getSubtypes(); + for (final Type subt : _subtypes) { + { + allSubtypes.add(subt); + this.listSubtypes(subt, allSubtypes); } } - return allSubtypes; } protected HashMap withAddition(final Map map1, final Map map2) { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java index 9b8f049d..b9c1d28d 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java @@ -78,16 +78,19 @@ public class Logic2VampireLanguageMapper_TypeMapper { EList _elements = type_1.getElements(); for (final DefinedElement e : _elements) { { + final String[] nameArray = e.getName().split(" "); + String relNameVar = ""; + int _length = nameArray.length; + boolean _equals = (_length == 3); + if (_equals) { + relNameVar = this.support.toIDMultiple(nameArray[0], nameArray[2]); + } else { + relNameVar = e.getName(); + } + final String relName = relNameVar; VLSFunction _createVLSFunction = this.factory.createVLSFunction(); final Procedure1 _function_1 = (VLSFunction it) -> { - final String[] splitName = e.getName().split(" "); - int _length = splitName.length; - boolean _greaterThan = (_length > 2); - if (_greaterThan) { - it.setConstant(this.support.toIDMultiple("e", splitName[0], splitName[2])); - } else { - it.setConstant(this.support.toIDMultiple("e", splitName[0])); - } + it.setConstant(this.support.toIDMultiple("e", relName)); EList _terms = it.getTerms(); VLSVariable _duplicate = this.support.duplicate(variable); _terms.add(_duplicate); @@ -123,7 +126,7 @@ public class Logic2VampireLanguageMapper_TypeMapper { } VLSFofFormula _createVLSFofFormula = this.factory.createVLSFofFormula(); final Procedure1 _function_1 = (VLSFofFormula it) -> { - it.setName(this.support.toIDMultiple("typeDef", type_1.getName().split(" ")[0])); + it.setName(this.support.toIDMultiple("typeDef", CollectionsUtil.lookup(type_1, trace.type2Predicate).getConstant().toString())); it.setFofRole("axiom"); VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); final Procedure1 _function_2 = (VLSUniversalQuantifier it_1) -> { @@ -160,10 +163,10 @@ public class Logic2VampireLanguageMapper_TypeMapper { final VLSFunctionAsTerm cstTerm = ObjectExtensions.operator_doubleArrow(_createVLSFunctionAsTerm, _function_2); final VLSConstant cst = this.support.toConstant(cstTerm); trace.uniqueInstances.add(cst); - final int index = i; + final int index = (i - globalCounter); VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); final Procedure1 _function_3 = (VLSFofFormula it) -> { - it.setName(this.support.toIDMultiple("enumScope", type_1.getName().split(" ")[0], + it.setName(this.support.toIDMultiple("enumScope", CollectionsUtil.lookup(type_1, trace.type2Predicate).getConstant().toString(), type_1.getElements().get(index).getName().split(" ")[0])); it.setFofRole("axiom"); VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.aird b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.aird new file mode 100644 index 00000000..50f2ba11 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.aird @@ -0,0 +1,379 @@ + + + + filesystem.ecore + filesystem.genmodel + + + + + + + + + + + + + + + + + + + + + + + + bold + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + italic + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO + + + + + + + + + + + labelSize + bold + + + labelSize + + + + + + + + + + labelSize + + + labelSize + + + + + + + + + + labelSize + bold + + + labelSize + + + + + + + + + + labelSize + + + labelSize + + + + + + + + + + + italic + + + + + + + + + + + + italic + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird index ef3746fa..be45a301 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird @@ -52,7 +52,7 @@ - + @@ -61,7 +61,7 @@ - + @@ -70,7 +70,7 @@ - + @@ -79,7 +79,7 @@ - + @@ -88,7 +88,7 @@ - + @@ -97,7 +97,7 @@ - + @@ -106,7 +106,7 @@ - + @@ -115,7 +115,7 @@ - + @@ -124,7 +124,7 @@ - + @@ -133,7 +133,7 @@ - + @@ -142,7 +142,7 @@ - + @@ -151,7 +151,7 @@ - + @@ -160,22 +160,22 @@ - + - + - + - + - + @@ -191,7 +191,7 @@ - + @@ -207,7 +207,7 @@ - + @@ -223,7 +223,7 @@ - + @@ -239,7 +239,7 @@ - + @@ -255,7 +255,7 @@ - + @@ -271,7 +271,7 @@ - + @@ -287,7 +287,7 @@ - + @@ -303,7 +303,7 @@ - + @@ -319,7 +319,7 @@ - + @@ -335,7 +335,7 @@ - + @@ -351,39 +351,39 @@ - + - + - + - + - + - + - + - + - + @@ -392,6 +392,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO italic @@ -401,6 +404,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO italic @@ -410,6 +416,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -418,6 +427,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -426,6 +438,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -434,6 +449,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -442,6 +460,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -450,6 +471,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -458,6 +482,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO italic @@ -467,6 +494,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO italic @@ -476,6 +506,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -484,6 +517,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO @@ -492,6 +528,9 @@ + KEEP_LOCATION + KEEP_SIZE + KEEP_RATIO diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index f9d517b9..c0c367a1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -20,13 +20,6 @@ - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java deleted file mode 100644 index 69a6b9f4..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/TerminatorAndInformation.java +++ /dev/null @@ -1,747 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator; -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
- *         pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
- *         	FunctionalOutput.outgoingLinks(Out,I);
- *         	FunctionalOutput.terminator(Out,T); 
- *         } or {
- *         	InformationLink.to(I,In);
- *         	FunctionalInput.terminator(In,T);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class TerminatorAndInformation extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private FAMTerminator fT; - - private InformationLink fI; - - private static List parameterNames = makeImmutableList("T", "I"); - - private Match(final FAMTerminator pT, final InformationLink pI) { - this.fT = pT; - this.fI = pI; - } - - @Override - public Object get(final String parameterName) { - if ("T".equals(parameterName)) return this.fT; - if ("I".equals(parameterName)) return this.fI; - return null; - } - - public FAMTerminator getT() { - return this.fT; - } - - public InformationLink getI() { - return this.fI; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("T".equals(parameterName) ) { - this.fT = (FAMTerminator) newValue; - return true; - } - if ("I".equals(parameterName) ) { - this.fI = (InformationLink) newValue; - return true; - } - return false; - } - - public void setT(final FAMTerminator pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setI(final InformationLink pI) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fI = pI; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation"; - } - - @Override - public List parameterNames() { - return TerminatorAndInformation.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fI}; - } - - @Override - public TerminatorAndInformation.Match toImmutable() { - return isMutable() ? newMatch(fT, fI) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"T\"=" + prettyPrintValue(fT) + ", "); - result.append("\"I\"=" + prettyPrintValue(fI)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fI); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof TerminatorAndInformation.Match)) { - TerminatorAndInformation.Match other = (TerminatorAndInformation.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fI, other.fI); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public TerminatorAndInformation specification() { - return TerminatorAndInformation.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static TerminatorAndInformation.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static TerminatorAndInformation.Match newMutableMatch(final FAMTerminator pT, final InformationLink pI) { - return new Mutable(pT, pI); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the (partial) match object. - * - */ - public static TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { - return new Immutable(pT, pI); - } - - private static final class Mutable extends TerminatorAndInformation.Match { - Mutable(final FAMTerminator pT, final InformationLink pI) { - super(pT, pI); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends TerminatorAndInformation.Match { - Immutable(final FAMTerminator pT, final InformationLink pI) { - super(pT, pI); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
-   * pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
-   * 	FunctionalOutput.outgoingLinks(Out,I);
-   * 	FunctionalOutput.terminator(Out,T); 
-   * } or {
-   * 	InformationLink.to(I,In);
-   * 	FunctionalInput.terminator(In,T);
-   * }
-   * 
- * - * @see Match - * @see TerminatorAndInformation - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static TerminatorAndInformation.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static TerminatorAndInformation.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_I = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(TerminatorAndInformation.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final FAMTerminator pT, final InformationLink pI) { - return rawStreamAllMatches(new Object[]{pT, pI}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final FAMTerminator pT, final InformationLink pI) { - return rawStreamAllMatches(new Object[]{pT, pI}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI) { - return rawGetOneArbitraryMatch(new Object[]{pT, pI}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final FAMTerminator pT, final InformationLink pI) { - return rawHasMatch(new Object[]{pT, pI}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final FAMTerminator pT, final InformationLink pI) { - return rawCountMatches(new Object[]{pT, pI}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pI}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the (partial) match object. - * - */ - public TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { - return TerminatorAndInformation.Match.newMatch(pT, pI); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfT(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(FAMTerminator.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT() { - return rawStreamAllValuesOfT(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT() { - return rawStreamAllValuesOfT(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for T. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfT(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for T. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT(final InformationLink pI) { - return rawStreamAllValuesOfT(new Object[]{null, pI}); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfT(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT(final InformationLink pI) { - return rawStreamAllValuesOfT(new Object[]{null, pI}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfI(final Object[] parameters) { - return rawStreamAllValues(POSITION_I, parameters).map(InformationLink.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI() { - return rawStreamAllValuesOfI(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI() { - return rawStreamAllValuesOfI(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for I. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfI(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for I. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI(final FAMTerminator pT) { - return rawStreamAllValuesOfI(new Object[]{pT, null}); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfI(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI(final FAMTerminator pT) { - return rawStreamAllValuesOfI(new Object[]{pT, null}).collect(Collectors.toSet()); - } - - @Override - protected TerminatorAndInformation.Match tupleToMatch(final Tuple t) { - try { - return TerminatorAndInformation.Match.newMatch((FAMTerminator) t.get(POSITION_T), (InformationLink) t.get(POSITION_I)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected TerminatorAndInformation.Match arrayToMatch(final Object[] match) { - try { - return TerminatorAndInformation.Match.newMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected TerminatorAndInformation.Match arrayToMatchMutable(final Object[] match) { - try { - return TerminatorAndInformation.Match.newMutableMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return TerminatorAndInformation.instance(); - } - } - - private TerminatorAndInformation() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static TerminatorAndInformation instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected TerminatorAndInformation.Matcher instantiate(final ViatraQueryEngine engine) { - return TerminatorAndInformation.Matcher.on(engine); - } - - @Override - public TerminatorAndInformation.Matcher instantiate() { - return TerminatorAndInformation.Matcher.create(); - } - - @Override - public TerminatorAndInformation.Match newEmptyMatch() { - return TerminatorAndInformation.Match.newEmptyMatch(); - } - - @Override - public TerminatorAndInformation.Match newMatch(final Object... parameters) { - return TerminatorAndInformation.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static TerminatorAndInformation INSTANCE = new TerminatorAndInformation(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static TerminatorAndInformation.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_T = new PParameter("T", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.FAMTerminator", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "FAMTerminator")), PParameterDirection.INOUT); - - private final PParameter parameter_I = new PParameter("I", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.InformationLink", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "InformationLink")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_T, parameter_I); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.terminatorAndInformation"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("T","I"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_T = body.getOrCreateVariableByName("T"); - PVariable var_I = body.getOrCreateVariableByName("I"); - PVariable var_Out = body.getOrCreateVariableByName("Out"); - new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_T, parameter_T), - new ExportedParameter(body, var_I, parameter_I) - )); - // FunctionalOutput.outgoingLinks(Out,I) - new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalOutput"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalOutput", "outgoingLinks"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); - new Equality(body, var__virtual_0_, var_I); - // FunctionalOutput.terminator(Out,T) - new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalOutput"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalData", "terminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); - new Equality(body, var__virtual_1_, var_T); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_T = body.getOrCreateVariableByName("T"); - PVariable var_I = body.getOrCreateVariableByName("I"); - PVariable var_In = body.getOrCreateVariableByName("In"); - new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_T, parameter_T), - new ExportedParameter(body, var_I, parameter_I) - )); - // InformationLink.to(I,In) - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "InformationLink"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_I, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "InformationLink", "to"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalInput"))); - new Equality(body, var__virtual_0_, var_In); - // FunctionalInput.terminator(In,T) - new TypeConstraint(body, Tuples.flatTupleOf(var_In), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FunctionalInput"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_In, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("FamMetamodel", "FunctionalData", "terminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "FAMTerminator"))); - new Equality(body, var__virtual_1_, var_T); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("message", "terminatorAndInformation"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("T") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath index 3f0838b6..f03a6d83 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath @@ -5,5 +5,6 @@ + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF index 2ea274a4..8b69d9a8 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF @@ -3,7 +3,11 @@ Bundle-ManifestVersion: 2 Bundle-Name: Test Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.test;singleton:=true Bundle-Version: 1.0.0.qualifier -Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries +Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries, + ca.mcgill.ecse.dslreasoner.vampire.test.queries.ecore, + ca.mcgill.ecse.dslreasoner.vampire.test.queries.fam, + ca.mcgill.ecse.dslreasoner.vampire.test.queries.filesystem, + ca.mcgill.ecse.dslreasoner.vampire.test.queries.yakindu Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, org.eclipse.emf.ecore, org.eclipse.viatra.query.runtime.rete, diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FAM/FaModel.xmi b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FAM/FaModel.xmi new file mode 100644 index 00000000..cef17e1b --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FAM/FaModel.xmi @@ -0,0 +1,7 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FaModel.xmi b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FaModel.xmi deleted file mode 100644 index cef17e1b..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/FaModel.xmi +++ /dev/null @@ -1,7 +0,0 @@ - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem index 18e58ab0..4f0bbdb1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem @@ -1,7 +1,7 @@ - + @@ -10,6 +10,8 @@ + + @@ -557,7 +559,8 @@ - + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp deleted file mode 100644 index 3d49d42c..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/vampireProblem.tptp +++ /dev/null @@ -1,72 +0,0 @@ -% This is an initial Test Comment -fof ( typeDef_FunctionType , axiom , ! [ A ] : ( t_FunctionType ( A ) <=> ( object ( A ) & ( ( e_Root_FunctionType ( A ) & ( ~ e_Intermediate_FunctionType ( A ) & ~ e_Leaf_FunctionType ( A ) ) ) | ( ( ~ e_Root_FunctionType ( A ) & ( e_Intermediate_FunctionType ( A ) & ~ e_Leaf_FunctionType ( A ) ) ) | ( ~ e_Root_FunctionType ( A ) & ( ~ e_Intermediate_FunctionType ( A ) & e_Leaf_FunctionType ( A ) ) ) ) ) ) ) ) . -fof ( enumScope_FunctionType_Root , axiom , ! [ A ] : ( A = eo1 <=> e_Root_FunctionType ( A ) ) ) . -fof ( enumScope_FunctionType_Intermediate , axiom , ! [ A ] : ( A = eo2 <=> e_Intermediate_FunctionType ( A ) ) ) . -fof ( enumScope_FunctionType_Leaf , axiom , ! [ A ] : ( A = eo3 <=> e_Leaf_FunctionType ( A ) ) ) . -fof ( notObjectHandler , axiom , ! [ A ] : ( ~ object ( A ) <=> ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_InformationLink ( A ) & ( ~ t_FunctionalInterface ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ~ t_FunctionType ( A ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( inheritanceHierarchyHandler , axiom , ! [ A ] : ( object ( A ) <=> ( ( t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( t_FunctionalOutput ( A ) & ( t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( t_InformationLink ( A ) & ~ t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) | ( ~ t_FunctionalArchitectureModel ( A ) & ( ~ t_FunctionalInput ( A ) & ( ~ t_Function ( A ) & ( ~ t_FAMTerminator ( A ) & ( ~ t_FunctionType ( A ) & ( ~ t_FunctionalElement ( A ) & ( ~ t_FunctionalOutput ( A ) & ( ~ t_FunctionalData ( A ) & ( ~ t_InformationLink ( A ) & t_FunctionalInterface ( A ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) . -fof ( typeScope_min_object , axiom , ! [ A ] : ( ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | ( A = eo1 | ( A = eo2 | A = eo3 ) ) ) ) ) ) => object ( A ) ) ) . -fof ( typeScope_max_object , axiom , ! [ A ] : ( object ( A ) => ( A = eo1 | ( A = eo2 | ( A = eo3 | ( A = o1 | ( A = o2 | ( A = o3 | ( A = o4 | A = o5 ) ) ) ) ) ) ) ) ) . -fof ( typeScope_min_t_Function , axiom , ! [ A ] : ( A = o2 => ( t_Function ( A ) & object ( A ) ) ) ) . -fof ( typeScope_min_t_FunctionalOutput , axiom , ! [ A ] : ( ( A = o3 | ( A = o4 | A = o5 ) ) => ( t_FunctionalOutput ( A ) & object ( A ) ) ) ) . -fof ( typeScope_min_t_FunctionalInterface , axiom , ! [ A ] : ( ( A = o6 | A = o7 ) => ( t_FunctionalInterface ( A ) & object ( A ) ) ) ) . -fof ( typeScope_max_t_Function , axiom , ! [ A ] : ( ( t_Function ( A ) & object ( A ) ) => A = o2 ) ) . -fof ( typeScope_max_t_FunctionalOutput , axiom , ! [ A ] : ( ( t_FunctionalOutput ( A ) & object ( A ) ) => ( A = o3 | ( A = o4 | A = o5 ) ) ) ) . -fof ( t_uniqueness_eo1 , axiom , eo1 != eo2 & ( eo1 != eo3 & ( eo1 != o1 & ( eo1 != o2 & ( eo1 != o3 & ( eo1 != o4 & eo1 != o5 ) ) ) ) ) ) . -fof ( t_uniqueness_eo2 , axiom , eo2 != eo3 & ( eo2 != o1 & ( eo2 != o2 & ( eo2 != o3 & ( eo2 != o4 & eo2 != o5 ) ) ) ) ) . -fof ( t_uniqueness_eo3 , axiom , eo3 != o1 & ( eo3 != o2 & ( eo3 != o3 & ( eo3 != o4 & eo3 != o5 ) ) ) ) . -fof ( t_uniqueness_o1 , axiom , o1 != o2 & ( o1 != o3 & ( o1 != o4 & o1 != o5 ) ) ) . -fof ( t_uniqueness_o2 , axiom , o2 != o3 & ( o2 != o4 & o2 != o5 ) ) . -fof ( t_uniqueness_o3 , axiom , o3 != o4 & o3 != o5 ) . -fof ( t_uniqueness_o4 , axiom , o4 != o5 ) . -fof ( compliance_interface_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_interface_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalInterface ( V_1 ) ) ) ) . -fof ( compliance_model_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_model_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_FunctionalArchitectureModel ( V_1 ) ) ) ) . -fof ( compliance_parent_FunctionalElement , axiom , ! [ V_0 , V_1 ] : ( r_parent_FunctionalElement ( V_0 , V_1 ) => ( t_FunctionalElement ( V_0 ) & t_Function ( V_1 ) ) ) ) . -fof ( compliance_rootElements_FunctionalArchitectureModel , axiom , ! [ V_0 , V_1 ] : ( r_rootElements_FunctionalArchitectureModel ( V_0 , V_1 ) => ( t_FunctionalArchitectureModel ( V_0 ) & t_FunctionalElement ( V_1 ) ) ) ) . -fof ( compliance_subElements_Function , axiom , ! [ V_0 , V_1 ] : ( r_subElements_Function ( V_0 , V_1 ) => ( t_Function ( V_0 ) & t_FunctionalElement ( V_1 ) ) ) ) . -fof ( compliance_data_FAMTerminator , axiom , ! [ V_0 , V_1 ] : ( r_data_FAMTerminator ( V_0 , V_1 ) => ( t_FAMTerminator ( V_0 ) & t_FunctionalData ( V_1 ) ) ) ) . -fof ( compliance_from_InformationLink , axiom , ! [ V_0 , V_1 ] : ( r_from_InformationLink ( V_0 , V_1 ) => ( t_InformationLink ( V_0 ) & t_FunctionalOutput ( V_1 ) ) ) ) . -fof ( compliance_to_InformationLink , axiom , ! [ V_0 , V_1 ] : ( r_to_InformationLink ( V_0 , V_1 ) => ( t_InformationLink ( V_0 ) & t_FunctionalInput ( V_1 ) ) ) ) . -fof ( compliance_data_FunctionalInterface , axiom , ! [ V_0 , V_1 ] : ( r_data_FunctionalInterface ( V_0 , V_1 ) => ( t_FunctionalInterface ( V_0 ) & t_FunctionalData ( V_1 ) ) ) ) . -fof ( compliance_element_FunctionalInterface , axiom , ! [ V_0 , V_1 ] : ( r_element_FunctionalInterface ( V_0 , V_1 ) => ( t_FunctionalInterface ( V_0 ) & t_FunctionalElement ( V_1 ) ) ) ) . -fof ( compliance_IncomingLinks_FunctionalInput , axiom , ! [ V_0 , V_1 ] : ( r_IncomingLinks_FunctionalInput ( V_0 , V_1 ) => ( t_FunctionalInput ( V_0 ) & t_InformationLink ( V_1 ) ) ) ) . -fof ( compliance_outgoingLinks_FunctionalOutput , axiom , ! [ V_0 , V_1 ] : ( r_outgoingLinks_FunctionalOutput ( V_0 , V_1 ) => ( t_FunctionalOutput ( V_0 ) & t_InformationLink ( V_1 ) ) ) ) . -fof ( compliance_terminator_FunctionalData , axiom , ! [ V_0 , V_1 ] : ( r_terminator_FunctionalData ( V_0 , V_1 ) => ( t_FunctionalData ( V_0 ) & t_FAMTerminator ( V_1 ) ) ) ) . -fof ( compliance_interface_FunctionalData , axiom , ! [ V_0 , V_1 ] : ( r_interface_FunctionalData ( V_0 , V_1 ) => ( t_FunctionalData ( V_0 ) & t_FunctionalInterface ( V_1 ) ) ) ) . -fof ( compliance_type_Function , axiom , ! [ V_0 , V_1 ] : ( r_type_Function ( V_0 , V_1 ) => ( t_Function ( V_0 ) & t_FunctionType ( V_1 ) ) ) ) . -fof ( containment_topLevel_t_FunctionalArchitectureModel , axiom , ! [ A ] : ( t_FunctionalArchitectureModel ( A ) <=> A = o1 ) ) . -fof ( containment_noDup_r_interface_FunctionalElement , axiom , ? [ A , B ] : ( r_interface_FunctionalElement ( A , B ) => ~ ? [ C , B ] : r_interface_FunctionalElement ( C , B ) ) ) . -fof ( containment_noDup_r_rootElements_FunctionalArchitectureModel , axiom , ? [ A , B ] : ( r_rootElements_FunctionalArchitectureModel ( A , B ) => ~ ? [ C , B ] : r_rootElements_FunctionalArchitectureModel ( C , B ) ) ) . -fof ( containment_noDup_r_subElements_Function , axiom , ? [ A , B ] : ( r_subElements_Function ( A , B ) => ~ ? [ C , B ] : r_subElements_Function ( C , B ) ) ) . -fof ( containment_noDup_r_data_FunctionalInterface , axiom , ? [ A , B ] : ( r_data_FunctionalInterface ( A , B ) => ~ ? [ C , B ] : r_data_FunctionalInterface ( C , B ) ) ) . -fof ( containment_noDup_r_outgoingLinks_FunctionalOutput , axiom , ? [ A , B ] : ( r_outgoingLinks_FunctionalOutput ( A , B ) => ~ ? [ C , B ] : r_outgoingLinks_FunctionalOutput ( C , B ) ) ) . -fof ( containment_noDup_r_terminator_FunctionalData , axiom , ? [ A , B ] : ( r_terminator_FunctionalData ( A , B ) => ~ ? [ C , B ] : r_terminator_FunctionalData ( C , B ) ) ) . -fof ( containment_t_FunctionalElement , axiom , ! [ A ] : ( t_FunctionalElement ( A ) => ? [ B ] : ( ( r_rootElements_FunctionalArchitectureModel ( B , A ) & ~ r_subElements_Function ( B , A ) ) | ( ~ r_rootElements_FunctionalArchitectureModel ( B , A ) & r_subElements_Function ( B , A ) ) ) ) ) . -fof ( containment_t_FunctionalData , axiom , ! [ A ] : ( t_FunctionalData ( A ) => ? [ B ] : r_data_FunctionalInterface ( B , A ) ) ) . -fof ( containment_t_InformationLink , axiom , ! [ A ] : ( t_InformationLink ( A ) => ? [ B ] : r_outgoingLinks_FunctionalOutput ( B , A ) ) ) . -fof ( containment_t_FunctionalInterface , axiom , ! [ A ] : ( t_FunctionalInterface ( A ) => ? [ B ] : r_interface_FunctionalElement ( B , A ) ) ) . -fof ( containment_t_FAMTerminator , axiom , ! [ A ] : ( t_FAMTerminator ( A ) => ? [ B ] : r_terminator_FunctionalData ( B , A ) ) ) . -fof ( containment_noCycle_1 , axiom , ~ ? [ V1 ] : ( r_interface_FunctionalElement ( V1 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V1 ) | ( r_subElements_Function ( V1 , V1 ) | ( r_data_FunctionalInterface ( V1 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V1 ) | r_terminator_FunctionalData ( V1 , V1 ) ) ) ) ) ) ) . -fof ( containment_noCycle_2 , axiom , ~ ? [ V1 , V2 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V2 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V1 ) | ( r_subElements_Function ( V2 , V1 ) | ( r_data_FunctionalInterface ( V2 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V1 ) | r_terminator_FunctionalData ( V2 , V1 ) ) ) ) ) ) ) ) . -fof ( containment_noCycle_3 , axiom , ~ ? [ V1 , V2 , V3 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V2 , V3 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V3 ) | ( r_subElements_Function ( V2 , V3 ) | ( r_data_FunctionalInterface ( V2 , V3 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V3 ) | r_terminator_FunctionalData ( V2 , V3 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V3 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V3 , V1 ) | ( r_subElements_Function ( V3 , V1 ) | ( r_data_FunctionalInterface ( V3 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V3 , V1 ) | r_terminator_FunctionalData ( V3 , V1 ) ) ) ) ) ) ) ) ) . -fof ( containment_noCycle_4 , axiom , ~ ? [ V1 , V2 , V3 , V4 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V2 , V3 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V3 ) | ( r_subElements_Function ( V2 , V3 ) | ( r_data_FunctionalInterface ( V2 , V3 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V3 ) | r_terminator_FunctionalData ( V2 , V3 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V3 , V4 ) | ( r_rootElements_FunctionalArchitectureModel ( V3 , V4 ) | ( r_subElements_Function ( V3 , V4 ) | ( r_data_FunctionalInterface ( V3 , V4 ) | ( r_outgoingLinks_FunctionalOutput ( V3 , V4 ) | r_terminator_FunctionalData ( V3 , V4 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V4 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V4 , V1 ) | ( r_subElements_Function ( V4 , V1 ) | ( r_data_FunctionalInterface ( V4 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V4 , V1 ) | r_terminator_FunctionalData ( V4 , V1 ) ) ) ) ) ) ) ) ) ) . -fof ( containment_noCycle_5 , axiom , ~ ? [ V1 , V2 , V3 , V4 , V5 ] : ( ( r_interface_FunctionalElement ( V1 , V2 ) | ( r_rootElements_FunctionalArchitectureModel ( V1 , V2 ) | ( r_subElements_Function ( V1 , V2 ) | ( r_data_FunctionalInterface ( V1 , V2 ) | ( r_outgoingLinks_FunctionalOutput ( V1 , V2 ) | r_terminator_FunctionalData ( V1 , V2 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V2 , V3 ) | ( r_rootElements_FunctionalArchitectureModel ( V2 , V3 ) | ( r_subElements_Function ( V2 , V3 ) | ( r_data_FunctionalInterface ( V2 , V3 ) | ( r_outgoingLinks_FunctionalOutput ( V2 , V3 ) | r_terminator_FunctionalData ( V2 , V3 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V3 , V4 ) | ( r_rootElements_FunctionalArchitectureModel ( V3 , V4 ) | ( r_subElements_Function ( V3 , V4 ) | ( r_data_FunctionalInterface ( V3 , V4 ) | ( r_outgoingLinks_FunctionalOutput ( V3 , V4 ) | r_terminator_FunctionalData ( V3 , V4 ) ) ) ) ) ) & ( ( r_interface_FunctionalElement ( V4 , V5 ) | ( r_rootElements_FunctionalArchitectureModel ( V4 , V5 ) | ( r_subElements_Function ( V4 , V5 ) | ( r_data_FunctionalInterface ( V4 , V5 ) | ( r_outgoingLinks_FunctionalOutput ( V4 , V5 ) | r_terminator_FunctionalData ( V4 , V5 ) ) ) ) ) ) & ( r_interface_FunctionalElement ( V5 , V1 ) | ( r_rootElements_FunctionalArchitectureModel ( V5 , V1 ) | ( r_subElements_Function ( V5 , V1 ) | ( r_data_FunctionalInterface ( V5 , V1 ) | ( r_outgoingLinks_FunctionalOutput ( V5 , V1 ) | r_terminator_FunctionalData ( V5 , V1 ) ) ) ) ) ) ) ) ) ) ) . -fof ( upperMultiplicity_interface_FunctionalElement , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalElement ( V_src ) & ( t_FunctionalInterface ( V_trg_1 ) & t_FunctionalInterface ( V_trg_2 ) ) ) => ( ( r_interface_FunctionalElement ( V_src , V_trg_1 ) & r_interface_FunctionalElement ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( lowerMultiplicity_model_FunctionalElement , axiom , ! [ V_src ] : ( t_FunctionalElement ( V_src ) => ? [ V_trg_1 ] : ( t_FunctionalArchitectureModel ( V_trg_1 ) & r_model_FunctionalElement ( V_src , V_trg_1 ) ) ) ) . -fof ( upperMultiplicity_model_FunctionalElement , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalElement ( V_src ) & ( t_FunctionalArchitectureModel ( V_trg_1 ) & t_FunctionalArchitectureModel ( V_trg_2 ) ) ) => ( ( r_model_FunctionalElement ( V_src , V_trg_1 ) & r_model_FunctionalElement ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_parent_FunctionalElement , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalElement ( V_src ) & ( t_Function ( V_trg_1 ) & t_Function ( V_trg_2 ) ) ) => ( ( r_parent_FunctionalElement ( V_src , V_trg_1 ) & r_parent_FunctionalElement ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_data_FAMTerminator , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FAMTerminator ( V_src ) & ( t_FunctionalData ( V_trg_1 ) & t_FunctionalData ( V_trg_2 ) ) ) => ( ( r_data_FAMTerminator ( V_src , V_trg_1 ) & r_data_FAMTerminator ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_from_InformationLink , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_InformationLink ( V_src ) & ( t_FunctionalOutput ( V_trg_1 ) & t_FunctionalOutput ( V_trg_2 ) ) ) => ( ( r_from_InformationLink ( V_src , V_trg_1 ) & r_from_InformationLink ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( lowerMultiplicity_to_InformationLink , axiom , ! [ V_src ] : ( t_InformationLink ( V_src ) => ? [ V_trg_1 ] : ( t_FunctionalInput ( V_trg_1 ) & r_to_InformationLink ( V_src , V_trg_1 ) ) ) ) . -fof ( upperMultiplicity_to_InformationLink , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_InformationLink ( V_src ) & ( t_FunctionalInput ( V_trg_1 ) & t_FunctionalInput ( V_trg_2 ) ) ) => ( ( r_to_InformationLink ( V_src , V_trg_1 ) & r_to_InformationLink ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_element_FunctionalInterface , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalInterface ( V_src ) & ( t_FunctionalElement ( V_trg_1 ) & t_FunctionalElement ( V_trg_2 ) ) ) => ( ( r_element_FunctionalInterface ( V_src , V_trg_1 ) & r_element_FunctionalInterface ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_terminator_FunctionalData , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalData ( V_src ) & ( t_FAMTerminator ( V_trg_1 ) & t_FAMTerminator ( V_trg_2 ) ) ) => ( ( r_terminator_FunctionalData ( V_src , V_trg_1 ) & r_terminator_FunctionalData ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( upperMultiplicity_interface_FunctionalData , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_FunctionalData ( V_src ) & ( t_FunctionalInterface ( V_trg_1 ) & t_FunctionalInterface ( V_trg_2 ) ) ) => ( ( r_interface_FunctionalData ( V_src , V_trg_1 ) & r_interface_FunctionalData ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . -fof ( oppositeReference_interface_FunctionalElement , axiom , ! [ V_src , V_trg ] : ( ( t_FunctionalElement ( V_src ) & t_FunctionalInterface ( V_trg ) ) => ( r_interface_FunctionalElement ( V_src , V_trg ) <=> r_element_FunctionalInterface ( V_trg , V_src ) ) ) ) . -fof ( oppositeReference_parent_FunctionalElement , axiom , ! [ V_src , V_trg ] : ( ( t_FunctionalElement ( V_src ) & t_Function ( V_trg ) ) => ( r_parent_FunctionalElement ( V_src , V_trg ) <=> r_subElements_Function ( V_trg , V_src ) ) ) ) . -fof ( oppositeReference_data_FAMTerminator , axiom , ! [ V_src , V_trg ] : ( ( t_FAMTerminator ( V_src ) & t_FunctionalData ( V_trg ) ) => ( r_data_FAMTerminator ( V_src , V_trg ) <=> r_terminator_FunctionalData ( V_trg , V_src ) ) ) ) . -fof ( oppositeReference_from_InformationLink , axiom , ! [ V_src , V_trg ] : ( ( t_InformationLink ( V_src ) & t_FunctionalOutput ( V_trg ) ) => ( r_from_InformationLink ( V_src , V_trg ) <=> r_outgoingLinks_FunctionalOutput ( V_trg , V_src ) ) ) ) . -fof ( oppositeReference_to_InformationLink , axiom , ! [ V_src , V_trg ] : ( ( t_InformationLink ( V_src ) & t_FunctionalInput ( V_trg ) ) => ( r_to_InformationLink ( V_src , V_trg ) <=> r_IncomingLinks_FunctionalInput ( V_trg , V_src ) ) ) ) . -fof ( oppositeReference_data_FunctionalInterface , axiom , ! [ V_src , V_trg ] : ( ( t_FunctionalInterface ( V_src ) & t_FunctionalData ( V_trg ) ) => ( r_data_FunctionalInterface ( V_src , V_trg ) <=> r_interface_FunctionalData ( V_trg , V_src ) ) ) ) . -fof ( lowerMultiplicity_type_Function , axiom , ! [ V_src ] : ( t_Function ( V_src ) => ? [ V_trg_1 ] : ( t_FunctionType ( V_trg_1 ) & r_type_Function ( V_src , V_trg_1 ) ) ) ) . -fof ( upperMultiplicity_type_Function , axiom , ! [ V_src , V_trg_1 , V_trg_2 ] : ( ( t_Function ( V_src ) & ( t_FunctionType ( V_trg_1 ) & t_FunctionType ( V_trg_2 ) ) ) => ( ( r_type_Function ( V_src , V_trg_1 ) & r_type_Function ( V_src , V_trg_2 ) ) => ~ V_trg_1 != V_trg_2 ) ) ) . diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index 3770f0af..0d17c01b 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -1,7 +1,10 @@ - - - + + + + + + @@ -11,7 +14,18 @@ + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.java deleted file mode 100644 index cf1378da..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.java +++ /dev/null @@ -1,53 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import ca.mcgill.ecse.dslreasoner.vampire.queries.TerminatorAndInformation; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedPatternGroup; - -/** - * A pattern group formed of all public patterns defined in FamPatterns.vql. - * - *

Use the static instance as any {@link interface org.eclipse.viatra.query.runtime.api.IQueryGroup}, to conveniently prepare - * a VIATRA Query engine for matching all patterns originally defined in file FamPatterns.vql, - * in order to achieve better performance than one-by-one on-demand matcher initialization. - * - *

From package ca.mcgill.ecse.dslreasoner.vampire.queries, the group contains the definition of the following patterns:

    - *
  • terminatorAndInformation
  • - *
- * - * @see IQueryGroup - * - */ -@SuppressWarnings("all") -public final class FamPatterns extends BaseGeneratedPatternGroup { - /** - * Access the pattern group. - * - * @return the singleton instance of the group - * @throws ViatraQueryRuntimeException if there was an error loading the generated code of pattern specifications - * - */ - public static FamPatterns instance() { - if (INSTANCE == null) { - INSTANCE = new FamPatterns(); - } - return INSTANCE; - } - - private static FamPatterns INSTANCE; - - private FamPatterns() { - querySpecifications.add(TerminatorAndInformation.instance()); - } - - public TerminatorAndInformation getTerminatorAndInformation() { - return TerminatorAndInformation.instance(); - } - - public TerminatorAndInformation.Matcher getTerminatorAndInformation(final ViatraQueryEngine engine) { - return TerminatorAndInformation.Matcher.on(engine); - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/TerminatorAndInformation.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/TerminatorAndInformation.java deleted file mode 100644 index cb0708ad..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src-gen/ca/mcgill/ecse/dslreasoner/vampire/queries/TerminatorAndInformation.java +++ /dev/null @@ -1,747 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/queries/FamPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.vampire.queries; - -import functionalarchitecture.FAMTerminator; -import functionalarchitecture.InformationLink; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EStructuralFeatureInstancesKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.ParameterReference; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
- *         pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
- *         	FunctionalOutput.outgoingLinks(Out,I);
- *         	FunctionalOutput.terminator(Out,T); 
- *         } or {
- *         	InformationLink.to(I,In);
- *         	FunctionalInput.terminator(In,T);
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class TerminatorAndInformation extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.vampire.queries.terminatorAndInformation pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private FAMTerminator fT; - - private InformationLink fI; - - private static List parameterNames = makeImmutableList("T", "I"); - - private Match(final FAMTerminator pT, final InformationLink pI) { - this.fT = pT; - this.fI = pI; - } - - @Override - public Object get(final String parameterName) { - if ("T".equals(parameterName)) return this.fT; - if ("I".equals(parameterName)) return this.fI; - return null; - } - - public FAMTerminator getT() { - return this.fT; - } - - public InformationLink getI() { - return this.fI; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("T".equals(parameterName) ) { - this.fT = (FAMTerminator) newValue; - return true; - } - if ("I".equals(parameterName) ) { - this.fI = (InformationLink) newValue; - return true; - } - return false; - } - - public void setT(final FAMTerminator pT) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fT = pT; - } - - public void setI(final InformationLink pI) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fI = pI; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.terminatorAndInformation"; - } - - @Override - public List parameterNames() { - return TerminatorAndInformation.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fT, fI}; - } - - @Override - public TerminatorAndInformation.Match toImmutable() { - return isMutable() ? newMatch(fT, fI) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"T\"=" + prettyPrintValue(fT) + ", "); - result.append("\"I\"=" + prettyPrintValue(fI)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fT, fI); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof TerminatorAndInformation.Match)) { - TerminatorAndInformation.Match other = (TerminatorAndInformation.Match) obj; - return Objects.equals(fT, other.fT) && Objects.equals(fI, other.fI); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public TerminatorAndInformation specification() { - return TerminatorAndInformation.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static TerminatorAndInformation.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static TerminatorAndInformation.Match newMutableMatch(final FAMTerminator pT, final InformationLink pI) { - return new Mutable(pT, pI); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the (partial) match object. - * - */ - public static TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { - return new Immutable(pT, pI); - } - - private static final class Mutable extends TerminatorAndInformation.Match { - Mutable(final FAMTerminator pT, final InformationLink pI) { - super(pT, pI); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends TerminatorAndInformation.Match { - Immutable(final FAMTerminator pT, final InformationLink pI) { - super(pT, pI); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.vampire.queries.terminatorAndInformation pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}Constraint(message="terminatorAndInformation", severity="error", key={T})
-   * pattern terminatorAndInformation(T : FAMTerminator, I : InformationLink) = {
-   * 	FunctionalOutput.outgoingLinks(Out,I);
-   * 	FunctionalOutput.terminator(Out,T); 
-   * } or {
-   * 	InformationLink.to(I,In);
-   * 	FunctionalInput.terminator(In,T);
-   * }
-   * 
- * - * @see Match - * @see TerminatorAndInformation - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static TerminatorAndInformation.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static TerminatorAndInformation.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_T = 0; - - private final static int POSITION_I = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(TerminatorAndInformation.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final FAMTerminator pT, final InformationLink pI) { - return rawStreamAllMatches(new Object[]{pT, pI}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final FAMTerminator pT, final InformationLink pI) { - return rawStreamAllMatches(new Object[]{pT, pI}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI) { - return rawGetOneArbitraryMatch(new Object[]{pT, pI}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final FAMTerminator pT, final InformationLink pI) { - return rawHasMatch(new Object[]{pT, pI}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final FAMTerminator pT, final InformationLink pI) { - return rawCountMatches(new Object[]{pT, pI}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final FAMTerminator pT, final InformationLink pI, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pT, pI}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pT the fixed value of pattern parameter T, or null if not bound. - * @param pI the fixed value of pattern parameter I, or null if not bound. - * @return the (partial) match object. - * - */ - public TerminatorAndInformation.Match newMatch(final FAMTerminator pT, final InformationLink pI) { - return TerminatorAndInformation.Match.newMatch(pT, pI); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfT(final Object[] parameters) { - return rawStreamAllValues(POSITION_T, parameters).map(FAMTerminator.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT() { - return rawStreamAllValuesOfT(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT() { - return rawStreamAllValuesOfT(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for T. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfT(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for T. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfT(final InformationLink pI) { - return rawStreamAllValuesOfT(new Object[]{null, pI}); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfT(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for T. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfT(final InformationLink pI) { - return rawStreamAllValuesOfT(new Object[]{null, pI}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfI(final Object[] parameters) { - return rawStreamAllValues(POSITION_I, parameters).map(InformationLink.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI() { - return rawStreamAllValuesOfI(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI() { - return rawStreamAllValuesOfI(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for I. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfI(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for I. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfI(final FAMTerminator pT) { - return rawStreamAllValuesOfI(new Object[]{pT, null}); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI(final TerminatorAndInformation.Match partialMatch) { - return rawStreamAllValuesOfI(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for I. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfI(final FAMTerminator pT) { - return rawStreamAllValuesOfI(new Object[]{pT, null}).collect(Collectors.toSet()); - } - - @Override - protected TerminatorAndInformation.Match tupleToMatch(final Tuple t) { - try { - return TerminatorAndInformation.Match.newMatch((FAMTerminator) t.get(POSITION_T), (InformationLink) t.get(POSITION_I)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected TerminatorAndInformation.Match arrayToMatch(final Object[] match) { - try { - return TerminatorAndInformation.Match.newMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected TerminatorAndInformation.Match arrayToMatchMutable(final Object[] match) { - try { - return TerminatorAndInformation.Match.newMutableMatch((FAMTerminator) match[POSITION_T], (InformationLink) match[POSITION_I]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return TerminatorAndInformation.instance(); - } - } - - private TerminatorAndInformation() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static TerminatorAndInformation instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected TerminatorAndInformation.Matcher instantiate(final ViatraQueryEngine engine) { - return TerminatorAndInformation.Matcher.on(engine); - } - - @Override - public TerminatorAndInformation.Matcher instantiate() { - return TerminatorAndInformation.Matcher.create(); - } - - @Override - public TerminatorAndInformation.Match newEmptyMatch() { - return TerminatorAndInformation.Match.newEmptyMatch(); - } - - @Override - public TerminatorAndInformation.Match newMatch(final Object... parameters) { - return TerminatorAndInformation.Match.newMatch((functionalarchitecture.FAMTerminator) parameters[0], (functionalarchitecture.InformationLink) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.queries.TerminatorAndInformation (visibility: PUBLIC, simpleName: TerminatorAndInformation, identifier: ca.mcgill.ecse.dslreasoner.vampire.queries.TerminatorAndInformation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static TerminatorAndInformation INSTANCE = new TerminatorAndInformation(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static TerminatorAndInformation.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_T = new PParameter("T", "functionalarchitecture.FAMTerminator", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FAMTerminator")), PParameterDirection.INOUT); - - private final PParameter parameter_I = new PParameter("I", "functionalarchitecture.InformationLink", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_T, parameter_I); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.vampire.queries.terminatorAndInformation"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("T","I"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_T = body.getOrCreateVariableByName("T"); - PVariable var_I = body.getOrCreateVariableByName("I"); - PVariable var_Out = body.getOrCreateVariableByName("Out"); - new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FAMTerminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_T, parameter_T), - new ExportedParameter(body, var_I, parameter_I) - )); - // FunctionalOutput.outgoingLinks(Out,I) - new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalOutput"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalOutput", "outgoingLinks"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink"))); - new Equality(body, var__virtual_0_, var_I); - // FunctionalOutput.terminator(Out,T) - new TypeConstraint(body, Tuples.flatTupleOf(var_Out), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalOutput"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_Out, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalData", "terminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FAMTerminator"))); - new Equality(body, var__virtual_1_, var_T); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_T = body.getOrCreateVariableByName("T"); - PVariable var_I = body.getOrCreateVariableByName("I"); - PVariable var_In = body.getOrCreateVariableByName("In"); - new TypeConstraint(body, Tuples.flatTupleOf(var_T), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FAMTerminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_T, parameter_T), - new ExportedParameter(body, var_I, parameter_I) - )); - // InformationLink.to(I,In) - new TypeConstraint(body, Tuples.flatTupleOf(var_I), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink"))); - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_I, var__virtual_0_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "InformationLink", "to"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_0_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalInput"))); - new Equality(body, var__virtual_0_, var_In); - // FunctionalInput.terminator(In,T) - new TypeConstraint(body, Tuples.flatTupleOf(var_In), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalInput"))); - PVariable var__virtual_1_ = body.getOrCreateVariableByName(".virtual{1}"); - new TypeConstraint(body, Tuples.flatTupleOf(var_In, var__virtual_1_), new EStructuralFeatureInstancesKey(getFeatureLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FunctionalData", "terminator"))); - new TypeConstraint(body, Tuples.flatTupleOf(var__virtual_1_), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("http://www.inf.mit.bme.hu/viatrasolver/example/fam", "FAMTerminator"))); - new Equality(body, var__virtual_1_, var_T); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("Constraint"); - annotation.addAttribute("message", "terminatorAndInformation"); - annotation.addAttribute("severity", "error"); - annotation.addAttribute("key", Arrays.asList(new Object[] { - new ParameterReference("T") - })); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend index 18b3badd..35b76350 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend @@ -1,11 +1,10 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration -import functionalarchitecture.FunctionalarchitecturePackage import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration -import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult @@ -13,91 +12,48 @@ import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace -import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace -import java.util.List -import org.eclipse.emf.ecore.EAttribute -import org.eclipse.emf.ecore.EClass -import org.eclipse.emf.ecore.EEnum -import org.eclipse.emf.ecore.EEnumLiteral -import org.eclipse.emf.ecore.EObject -import org.eclipse.emf.ecore.EReference -import org.eclipse.emf.ecore.resource.Resource -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl class EcoreTest { def static void main(String[] args) { val inputs = new FileSystemWorkspace('''initialModels/''', "") - val workspace = new FileSystemWorkspace('''output/FAMTest/''', "") + val workspace = new FileSystemWorkspace('''output/FEcoreTest/''', "") workspace.initAndClear println("Input and output workspaces are created") - val metamodel = loadMetamodel() - val partialModel = loadPartialModel(inputs) -// val queries = loadQueries(metamodel) + val metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE) + val partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi") +// val queries = GeneralTest.loadQueries(metamodel, ecorePatterns.instance) + val queries = null println("DSL loaded") - + val Ecore2Logic ecore2Logic = new Ecore2Logic val Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic) val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic - - val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel,new Ecore2LogicConfiguration()) - val modelExtensionProblem = instanceModel2Logic.transform(modelGenerationProblem,partialModel) + + val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) + val modelExtensionProblem = instanceModel2Logic.transform(modelGenerationProblem, partialModel) // val validModelExtensionProblem = viatra2Logic.transformQueries(queries,modelGenerationProblem,new Viatra2LogicConfiguration) - val logicProblem = modelGenerationProblem.output // val logicProblem = modelExtensionProblem.output // val logicProblem = validModelExtensionProblem.output - - println("Problem created") - + var LogicResult solution var LogicReasoner reasoner - //* + // * reasoner = new VampireSolver val vampireConfig = new VampireSolverConfiguration => [ - //add configuration things, in config file first + // add configuration things, in config file first it.documentationLevel = DocumentationLevel::FULL ] - - solution = reasoner.solve(logicProblem, vampireConfig, workspace) - - println("Problem solved") - - - } - def private static loadMetamodel() { - val pckg = FunctionalarchitecturePackage.eINSTANCE - val List classes = pckg.getEClassifiers.filter(EClass).toList - val List enums = pckg.getEClassifiers.filter(EEnum).toList - val List literals = enums.map[getELiterals].flatten.toList - val List references = classes.map[getEReferences].flatten.toList - val List attributes = classes.map[getEAttributes].flatten.toList - return new EcoreMetamodelDescriptor(classes,#{},false,enums,literals,references,attributes) - } + solution = reasoner.solve(logicProblem, vampireConfig, workspace) - def private static loadPartialModel(ReasonerWorkspace inputs) { - Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("*", new XMIResourceFactoryImpl()); -// inputs.readModel(EObject,"FunctionalArchitectureModel.xmi").eResource.allContents.toList - inputs.readModel(EObject,"FamInstance.xmi").eResource.allContents.toList - } + println("Problem solved") - def private static loadQueries(EcoreMetamodelDescriptor metamodel) { -// val i = Patterns.instance -// val patterns = i.specifications.toList -// val wfPatterns = patterns.filter[it.allAnnotations.exists[it.name== "Constraint"]].toSet -// val derivedFeatures = new LinkedHashMap -// derivedFeatures.put(i.type,metamodel.attributes.filter[it.name == "type"].head) -// derivedFeatures.put(i.model,metamodel.references.filter[it.name == "model"].head) -// val res = new ViatraQuerySetDescriptor( -// patterns, -// wfPatterns, -// derivedFeatures -// ) -// return res } + } 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 f66ad93c..3fc3d70f 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 @@ -1,6 +1,5 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import ca.mcgill.ecse.dslreasoner.vampire.queries.FamPatterns import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import functionalarchitecture.Function @@ -39,14 +38,15 @@ class FAMTest { // Load DSL val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) - val partialModel = GeneralTest.loadPartialModel(inputs, "FaModel.xmi") - val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) + val partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi") +// val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) + val queries = null println("DSL loaded") val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) var problem = modelGenerationProblem.output -// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output + problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output // problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output workspace.writeModel(problem, "Fam.logicproblem") diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend index 50639577..d4cbb299 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend @@ -1,7 +1,7 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import ca.mcgill.ecse.dslreasoner.vampire.queries import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage +import ca.mcgill.ecse.dslreasoner.vampire.queries.FileSystemPatterns import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic @@ -24,7 +24,7 @@ class FileSystemTest { // Workspace setup val inputs = new FileSystemWorkspace('''initialModels/''', "") - val workspace = new FileSystemWorkspace('''output/FAMTest/''', "") + val workspace = new FileSystemWorkspace('''output/FileSystemTest/''', "") workspace.initAndClear // Logicproblem writing setup @@ -34,9 +34,10 @@ class FileSystemTest { println("Input and output workspaces are created") + val metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE) val partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi") - //val queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance) + val queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance) println("DSL loaded") @@ -44,7 +45,7 @@ class FileSystemTest { var problem = modelGenerationProblem.output // problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output // problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output - workspace.writeModel(problem, "Fam.logicproblem") + workspace.writeModel(problem, "FileSystem.logicproblem") println("Problem created") @@ -75,8 +76,8 @@ class FileSystemTest { // add configuration things, in config file first it.documentationLevel = DocumentationLevel::FULL - it.typeScopes.minNewElements = 4 - it.typeScopes.maxNewElements = 5 + it.typeScopes.minNewElements = 40 + it.typeScopes.maxNewElements = 59 if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax it.contCycleLevel = 5 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend index 1fac968b..f0d88b49 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend @@ -35,7 +35,7 @@ class YakinduTest { val metamodel = GeneralTest.loadMetamodel(yakinduPackage.eINSTANCE) val partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/yakinduinstance.xmi") -// val queries = GeneralTest.loadQueries(metamodel, FamPa +// val queries = GeneralTest.loadQueries(metamodel, yakinduPatterns.instance) val queries = null println("DSL loaded") @@ -75,8 +75,8 @@ class YakinduTest { // add configuration things, in config file first it.documentationLevel = DocumentationLevel::FULL - it.typeScopes.minNewElements = 20 - it.typeScopes.maxNewElements = 30 + it.typeScopes.minNewElements = 53 + it.typeScopes.maxNewElements = 53 if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax it.contCycleLevel = 5 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 55d90ac7..2cecdaac 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 8eeb2d28..a34ab846 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index ab6aaf6e..a18fd1a5 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index cd75a66c..0969c84c 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 1b920064..f0af3ba5 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java index 820dd354..7019f162 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java @@ -1,9 +1,9 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; +import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; -import com.google.common.collect.Iterables; -import functionalarchitecture.FunctionalarchitecturePackage; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; @@ -17,27 +17,11 @@ import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; -import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace; -import java.util.Collections; -import java.util.List; -import java.util.Map; import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EAttribute; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EEnum; -import org.eclipse.emf.ecore.EEnumLiteral; import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EReference; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; -import org.eclipse.xtext.xbase.lib.CollectionLiterals; import org.eclipse.xtext.xbase.lib.Exceptions; -import org.eclipse.xtext.xbase.lib.Functions.Function1; import org.eclipse.xtext.xbase.lib.InputOutput; -import org.eclipse.xtext.xbase.lib.IterableExtensions; -import org.eclipse.xtext.xbase.lib.IteratorExtensions; -import org.eclipse.xtext.xbase.lib.ListExtensions; import org.eclipse.xtext.xbase.lib.ObjectExtensions; import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @@ -49,12 +33,13 @@ public class EcoreTest { _builder.append("initialModels/"); final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FAMTest/"); + _builder_1.append("output/FEcoreTest/"); final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); workspace.initAndClear(); InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = EcoreTest.loadMetamodel(); - final List partialModel = EcoreTest.loadPartialModel(inputs); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); + final Object queries = null; InputOutput.println("DSL loaded"); final Ecore2Logic ecore2Logic = new Ecore2Logic(); final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); @@ -80,38 +65,4 @@ public class EcoreTest { throw Exceptions.sneakyThrow(_e); } } - - private static EcoreMetamodelDescriptor loadMetamodel() { - final FunctionalarchitecturePackage pckg = FunctionalarchitecturePackage.eINSTANCE; - final List classes = IterableExtensions.toList(Iterables.filter(pckg.getEClassifiers(), EClass.class)); - final List enums = IterableExtensions.toList(Iterables.filter(pckg.getEClassifiers(), EEnum.class)); - final Function1> _function = (EEnum it) -> { - return it.getELiterals(); - }; - final List literals = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(enums, _function))); - final Function1> _function_1 = (EClass it) -> { - return it.getEReferences(); - }; - final List references = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(classes, _function_1))); - final Function1> _function_2 = (EClass it) -> { - return it.getEAttributes(); - }; - final List attributes = IterableExtensions.toList(Iterables.concat(ListExtensions.>map(classes, _function_2))); - return new EcoreMetamodelDescriptor(classes, Collections.unmodifiableSet(CollectionLiterals.newHashSet()), false, enums, literals, references, attributes); - } - - private static List loadPartialModel(final ReasonerWorkspace inputs) { - List _xblockexpression = null; - { - Map _extensionToFactoryMap = Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - _extensionToFactoryMap.put("*", _xMIResourceFactoryImpl); - _xblockexpression = IteratorExtensions.toList(inputs.readModel(EObject.class, "FamInstance.xmi").eResource().getAllContents()); - } - return _xblockexpression; - } - - private static Object loadQueries(final EcoreMetamodelDescriptor metamodel) { - return null; - } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index 5fc2a391..08f1b4a7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -1,7 +1,6 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import ca.mcgill.ecse.dslreasoner.vampire.queries.FamPatterns; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; import functionalarchitecture.Function; @@ -18,7 +17,6 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; import java.util.HashMap; @@ -53,12 +51,13 @@ public class FAMTest { map.put("logicproblem", _xMIResourceFactoryImpl); InputOutput.println("Input and output workspaces are created"); final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "FaModel.xmi"); - final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi"); + final Object queries = null; InputOutput.println("DSL loaded"); Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); LogicProblem problem = modelGenerationProblem.getOutput(); + problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); workspace.writeModel(problem, "Fam.logicproblem"); InputOutput.println("Problem created"); long startTime = System.currentTimeMillis(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java index eedec995..f7f8a5ee 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java @@ -2,6 +2,7 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; +import ca.mcgill.ecse.dslreasoner.vampire.queries.FileSystemPatterns; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; @@ -15,6 +16,7 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; +import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; import java.util.HashMap; @@ -40,7 +42,7 @@ public class FileSystemTest { _builder.append("initialModels/"); final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FAMTest/"); + _builder_1.append("output/FileSystemTest/"); final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); workspace.initAndClear(); final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; @@ -50,11 +52,12 @@ public class FileSystemTest { InputOutput.println("Input and output workspaces are created"); final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); + final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance()); InputOutput.println("DSL loaded"); Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); LogicProblem problem = modelGenerationProblem.getOutput(); - workspace.writeModel(problem, "Fam.logicproblem"); + workspace.writeModel(problem, "FileSystem.logicproblem"); InputOutput.println("Problem created"); long startTime = System.currentTimeMillis(); LogicReasoner reasoner = null; @@ -67,8 +70,8 @@ public class FileSystemTest { VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); final Procedure1 _function = (VampireSolverConfiguration it) -> { it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 4; - it.typeScopes.maxNewElements = 5; + it.typeScopes.minNewElements = 40; + it.typeScopes.maxNewElements = 59; int _size = typeMapMin.size(); boolean _notEquals = (_size != 0); if (_notEquals) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java index 81079764..3a322ee0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java @@ -68,8 +68,8 @@ public class YakinduTest { VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); final Procedure1 _function = (VampireSolverConfiguration it) -> { it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 20; - it.typeScopes.maxNewElements = 30; + it.typeScopes.minNewElements = 53; + it.typeScopes.maxNewElements = 53; int _size = typeMapMin.size(); boolean _notEquals = (_size != 0); if (_notEquals) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 29f8df00..c5ed4b90 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 72d33e5d..21fdd9b7 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index e9c4c0a4..b1887ff2 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 515d94e442c644a9984422f11efecacc5041db60 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Wed, 24 Apr 2019 02:30:50 -0400 Subject: VAMPIRE: add to #40. I am tired --- .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1701 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2526 -> 2526 bytes .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../builder/Logic2VampireLanguageMapperTrace.xtend | 2 + ...c2VampireLanguageMapper_ContainmentMapper.xtend | 60 ++++-- .../Logic2VampireLanguageMapper_ScopeMapper.xtend | 1 + .../Logic2VampireLanguageMapper_TypeMapper.xtend | 23 ++- .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 5892 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18156 -> 18159 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4215 -> 4481 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 10674 -> 11150 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 6457 -> 6457 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 9839 -> 9839 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13046 -> 13048 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 10792 -> 11070 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 4908 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../builder/Logic2VampireLanguageMapperTrace.java | 2 + ...ic2VampireLanguageMapper_ContainmentMapper.java | 64 +++++-- .../Logic2VampireLanguageMapper_TypeMapper.java | 22 ++- .../plugin.xml | 111 +++++++++++ .../plugin.xml | 211 +++++++++++++++++++++ .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 4 +- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4545 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6296 -> 6302 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 6618 -> 6618 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6456 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 6040 -> 6040 bytes .../ecse/dslreasoner/vampire/icse/FAMTest.java | 4 +- .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes 49 files changed, 468 insertions(+), 36 deletions(-) (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index 9edfdac5..3ab0ceba 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index 0979473a..3d2fc82c 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 10495630..599f4b11 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 295d9ec2..39db4d8f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 83b00f77..261f76db 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index f8a7a2f3..23282723 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 544f5811..df1b5191 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 62aac4ca..712d5877 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 31d4543e..52de9434 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 7b230b65..5074417c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index a24c2795..9411e824 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index b35605ae..bc079ba9 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index 5e9cd3bd..2f3d05aa 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index 0001d80f..62275f93 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index b189414a..c5c4ea67 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index b4eec95c..45665484 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.xtend index 22bd4ab5..b9928383 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.xtend @@ -30,6 +30,8 @@ class Logic2VampireLanguageMapperTrace { //Necessary containers public var Logic2VampireLanguageMapper_TypeMapperTrace typeMapperTrace + public var Map definedElement2String = new HashMap + public val Map type2Predicate = new HashMap; public val Map element2Predicate = new HashMap public val Map type2PossibleNot = new HashMap diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend index 8e0e0b11..c56b54be 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.xtend @@ -14,10 +14,11 @@ import java.util.List import java.util.Map import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.* +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.TypeDefinition class Logic2VampireLanguageMapper_ContainmentMapper { - private val extension VampireLanguageFactory factory = VampireLanguageFactory.eINSTANCE - private val Logic2VampireLanguageMapper_Support support = new Logic2VampireLanguageMapper_Support + val extension VampireLanguageFactory factory = VampireLanguageFactory.eINSTANCE + val Logic2VampireLanguageMapper_Support support = new Logic2VampireLanguageMapper_Support val Logic2VampireLanguageMapper base private val VLSVariable variable = createVLSVariable => [it.name = "A"] @@ -34,6 +35,8 @@ class Logic2VampireLanguageMapper_ContainmentMapper { val containmentListCopy = hierarchy.typesOrderedInHierarchy val relationsList = hierarchy.containmentRelations + val toRemove = newArrayList + // STEP 1 // Find root element for (l : relationsList) { @@ -46,16 +49,51 @@ class Logic2VampireLanguageMapper_ContainmentMapper { } } - for (c : containmentListCopy) { - if(c.isIsAbstract) { - containmentListCopy.remove(c) - } - } - +// OLD +// for (c : containmentListCopy) { +// if(c.isIsAbstract) { +// toRemove.add(c) +// } +// } // State that there must exist 1 and only 1 root element - val topName = containmentListCopy.get(0).lookup(trace.type2Predicate).constant.toString - val topTerm = support.duplicate(containmentListCopy.get(0).lookup(trace.type2Predicate)) +// val topName = containmentListCopy.get(0).lookup(trace.type2Predicate).constant.toString +// val topTerm = support.duplicate(containmentListCopy.get(0).lookup(trace.type2Predicate)) + var topTermVar = containmentListCopy.get(0) + for (l : relationsList) { + var pointingFrom = (l.parameters.get(0) as ComplexTypeReference).referred as Type + if(containmentListCopy.contains(pointingFrom)) { + //The correct topTerm will be identified + topTermVar = pointingFrom + } + } + + val topName = topTermVar.lookup(trace.type2Predicate).constant.toString + val topTerm = support.duplicate(topTermVar.lookup(trace.type2Predicate)) + + + + var topLvlIsInInitModel = false + var topLvlString = "" + for ( c : topTermVar.subtypes) { + if (c.class.simpleName.equals("TypeDefinitionImpl") ) { + + for (d : (c as TypeDefinition).elements) { + if (trace.definedElement2String.containsKey(d)) { + topLvlIsInInitModel = true + topLvlString = d.lookup(trace.definedElement2String) + } + } + + } + + + } + val topInIM = topLvlIsInInitModel + val topStr = topLvlString + print(topInIM) + print(topStr) + val contTop = createVLSFofFormula => [ it.name = support.toIDMultiple("containment_topLevel", topName) it.fofRole = "axiom" @@ -67,7 +105,7 @@ class Logic2VampireLanguageMapper_ContainmentMapper { it.right = createVLSEquality => [ it.left = support.duplicate(variable) it.right = createVLSConstant => [ - it.name = "o1" + it.name = if (topInIM) topStr else "o1" ] ] ] diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend index 4a8d2827..c50aa770 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ScopeMapper.xtend @@ -30,6 +30,7 @@ class Logic2VampireLanguageMapper_ScopeMapper { // TODO HANDLE // 1. make a list of constants equaling the min number of specified objects //These numbers do not include enums or initial model elements + val GLOBAL_MIN = config.typeScopes.minNewElements val GLOBAL_MAX = config.typeScopes.maxNewElements diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend index 2f3af593..2a121446 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.xtend @@ -33,14 +33,24 @@ class Logic2VampireLanguageMapper_TypeMapper { // 1. Each type (class) is a predicate with a single variable as input for (type : types) { val typePred = createVLSFunction => [ - it.constant = support.toIDMultiple("t", type.name.split(" ").get(0)) + if(type.name.split(" ").length == 3) { + it.constant = support.toIDMultiple("t", type.name.split(" ").get(0), type.name.split(" ").get(2)) + } + else { + it.constant = support.toIDMultiple("t", type.name.split(" ").get(0)) + } it.terms += support.duplicate(variable) ] trace.type2Predicate.put(type, typePred) } // 2. Map each ENUM type definition to fof formula + // This also Handles initial Model stuff for (type : types.filter(TypeDefinition)) { + + //Detect if is an Enum + //Otherwise, it is a defined element (from initial model) + val isNotEnum = type.supertypes.length == 1 && type.supertypes.get(0).isIsAbstract // Create a VLSFunction for each Enum Element val List orElems = newArrayList @@ -104,15 +114,20 @@ class Logic2VampireLanguageMapper_TypeMapper { for (var i = globalCounter; i < globalCounter + type.elements.length; i++) { // Create objects for the enum elements val num = i + 1 + val index = i-globalCounter + val cstTerm = createVLSFunctionAsTerm => [ it.functor = "eo" + num ] + if (isNotEnum) { + trace.definedElement2String.put(type.elements.get(index),cstTerm.functor) + } + val cst = support.toConstant(cstTerm) trace.uniqueInstances.add(cst) - - val index = i-globalCounter + val enumScope = createVLSFofFormula => [ - it.name = support.toIDMultiple("enumScope", type.lookup(trace.type2Predicate).constant.toString, + it.name = support.toIDMultiple(if(isNotEnum) "definedType" else "enumScope", type.lookup(trace.type2Predicate).constant.toString, type.elements.get(index).name.split(" ").get(0)) it.fofRole = "axiom" it.fofFormula = createVLSUniversalQuantifier => [ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index 1ea7e30a..cab2b7ec 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index ee06cb39..80a74b4c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 648d9600..2dc1ce19 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index a02821a5..3c14aa6c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index b01f92a6..b51b8ceb 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 7634af4b..02b4f393 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 4906adfc..1feb9930 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index e2c945e3..fbc106a5 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index f465506c..77ffdd4b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index e046604a..070afd3c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index aff62dca..cd1b994d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 7212cce7..2cc7c421 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index d23bacad..25a165b1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index be78cace..8697d473 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.java index 24df5fcd..621a6e58 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapperTrace.java @@ -29,6 +29,8 @@ public class Logic2VampireLanguageMapperTrace { public Logic2VampireLanguageMapper_TypeMapperTrace typeMapperTrace; + public Map definedElement2String = new HashMap(); + public final Map type2Predicate = new HashMap(); public final Map element2Predicate = new HashMap(); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java index 9deab87f..855d7637 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_ContainmentMapper.java @@ -19,9 +19,11 @@ import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguageFactory; import com.google.common.base.Objects; import com.google.common.collect.Iterables; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.ComplexTypeReference; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.DefinedElement; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Relation; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.RelationDeclaration; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.TypeDefinition; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.TypeReference; import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.ContainmentHierarchy; import hu.bme.mit.inf.dslreasoner.util.CollectionsUtil; @@ -34,6 +36,7 @@ import org.eclipse.emf.common.util.EList; import org.eclipse.xtext.xbase.lib.CollectionLiterals; import org.eclipse.xtext.xbase.lib.Conversions; import org.eclipse.xtext.xbase.lib.Extension; +import org.eclipse.xtext.xbase.lib.InputOutput; import org.eclipse.xtext.xbase.lib.ObjectExtensions; import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @@ -58,6 +61,7 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { final ContainmentHierarchy hierarchy = hierarchies.get(0); final EList containmentListCopy = hierarchy.getTypesOrderedInHierarchy(); final EList relationsList = hierarchy.getContainmentRelations(); + final ArrayList toRemove = CollectionLiterals.newArrayList(); for (final Relation l : relationsList) { { TypeReference _get = l.getParameters().get(1); @@ -71,14 +75,40 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { } } } - for (final Type c : containmentListCopy) { - boolean _isIsAbstract = c.isIsAbstract(); - if (_isIsAbstract) { - containmentListCopy.remove(c); + Type topTermVar = containmentListCopy.get(0); + for (final Relation l_1 : relationsList) { + { + TypeReference _get = l_1.getParameters().get(0); + Type _referred = ((ComplexTypeReference) _get).getReferred(); + Type pointingFrom = ((Type) _referred); + boolean _contains = containmentListCopy.contains(pointingFrom); + if (_contains) { + topTermVar = pointingFrom; + } + } + } + final String topName = CollectionsUtil.lookup(topTermVar, trace.type2Predicate).getConstant().toString(); + final VLSFunction topTerm = this.support.duplicate(CollectionsUtil.lookup(topTermVar, trace.type2Predicate)); + boolean topLvlIsInInitModel = false; + String topLvlString = ""; + EList _subtypes = topTermVar.getSubtypes(); + for (final Type c : _subtypes) { + boolean _equals = c.getClass().getSimpleName().equals("TypeDefinitionImpl"); + if (_equals) { + EList _elements = ((TypeDefinition) c).getElements(); + for (final DefinedElement d : _elements) { + boolean _containsKey = trace.definedElement2String.containsKey(d); + if (_containsKey) { + topLvlIsInInitModel = true; + topLvlString = CollectionsUtil.lookup(d, trace.definedElement2String); + } + } } } - final String topName = CollectionsUtil.lookup(containmentListCopy.get(0), trace.type2Predicate).getConstant().toString(); - final VLSFunction topTerm = this.support.duplicate(CollectionsUtil.lookup(containmentListCopy.get(0), trace.type2Predicate)); + final boolean topInIM = topLvlIsInInitModel; + final String topStr = topLvlString; + InputOutput.print(Boolean.valueOf(topInIM)); + InputOutput.print(topStr); VLSFofFormula _createVLSFofFormula = this.factory.createVLSFofFormula(); final Procedure1 _function = (VLSFofFormula it) -> { it.setName(this.support.toIDMultiple("containment_topLevel", topName)); @@ -96,7 +126,13 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { it_3.setLeft(this.support.duplicate(this.variable)); VLSConstant _createVLSConstant = this.factory.createVLSConstant(); final Procedure1 _function_4 = (VLSConstant it_4) -> { - it_4.setName("o1"); + String _xifexpression = null; + if (topInIM) { + _xifexpression = topStr; + } else { + _xifexpression = "o1"; + } + it_4.setName(_xifexpression); }; VLSConstant _doubleArrow = ObjectExtensions.operator_doubleArrow(_createVLSConstant, _function_4); it_3.setRight(_doubleArrow); @@ -130,16 +166,16 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { final VLSVariable varC = ObjectExtensions.operator_doubleArrow(_createVLSVariable_2, _function_3); final ArrayList varList = CollectionLiterals.newArrayList(varB, varA); final Map> type2cont = new HashMap>(); - for (final Relation l_1 : relationsList) { + for (final Relation l_2 : relationsList) { { - final VLSFunction rel = this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_1), trace.rel2Predicate), varList); - TypeReference _get = l_1.getParameters().get(1); + final VLSFunction rel = this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_2), trace.rel2Predicate), varList); + TypeReference _get = l_2.getParameters().get(1); Type _referred = ((ComplexTypeReference) _get).getReferred(); final Type toType = ((Type) _referred); final VLSFunction toFunc = CollectionsUtil.lookup(toType, trace.type2Predicate); this.addToMap(type2cont, toFunc, rel); - EList _subtypes = toType.getSubtypes(); - for (final Type c_1 : _subtypes) { + EList _subtypes_1 = toType.getSubtypes(); + for (final Type c_1 : _subtypes_1) { this.addToMap(type2cont, toFunc, rel); } VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); @@ -244,9 +280,9 @@ public class Logic2VampireLanguageMapper_ContainmentMapper { variables.add(_doubleArrow); for (int j = 0; (j < i); j++) { { - for (final Relation l_2 : relationsList) { + for (final Relation l_3 : relationsList) { { - final VLSFunction rel = this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_2), trace.rel2Predicate), CollectionLiterals.newArrayList(variables.get(j), variables.get(((j + 1) % i)))); + final VLSFunction rel = this.support.duplicate(CollectionsUtil.lookup(((RelationDeclaration) l_3), trace.rel2Predicate), CollectionLiterals.newArrayList(variables.get(j), variables.get(((j + 1) % i)))); disjunctionList.add(rel); } } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java index b9c1d28d..2d9d566d 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Logic2VampireLanguageMapper_TypeMapper.java @@ -62,7 +62,13 @@ public class Logic2VampireLanguageMapper_TypeMapper { { VLSFunction _createVLSFunction = this.factory.createVLSFunction(); final Procedure1 _function_1 = (VLSFunction it) -> { - it.setConstant(this.support.toIDMultiple("t", type.getName().split(" ")[0])); + int _length = type.getName().split(" ").length; + boolean _equals = (_length == 3); + if (_equals) { + it.setConstant(this.support.toIDMultiple("t", type.getName().split(" ")[0], type.getName().split(" ")[2])); + } else { + it.setConstant(this.support.toIDMultiple("t", type.getName().split(" ")[0])); + } EList _terms = it.getTerms(); VLSVariable _duplicate = this.support.duplicate(variable); _terms.add(_duplicate); @@ -74,6 +80,7 @@ public class Logic2VampireLanguageMapper_TypeMapper { Iterable _filter = Iterables.filter(types, TypeDefinition.class); for (final TypeDefinition type_1 : _filter) { { + final boolean isNotEnum = ((((Object[])Conversions.unwrapArray(type_1.getSupertypes(), Object.class)).length == 1) && type_1.getSupertypes().get(0).isIsAbstract()); final List orElems = CollectionLiterals.newArrayList(); EList _elements = type_1.getElements(); for (final DefinedElement e : _elements) { @@ -156,17 +163,26 @@ public class Logic2VampireLanguageMapper_TypeMapper { for (int i = globalCounter; (i < (globalCounter + ((Object[])Conversions.unwrapArray(type_1.getElements(), Object.class)).length)); i++) { { final int num = (i + 1); + final int index = (i - globalCounter); VLSFunctionAsTerm _createVLSFunctionAsTerm = this.factory.createVLSFunctionAsTerm(); final Procedure1 _function_2 = (VLSFunctionAsTerm it) -> { it.setFunctor(("eo" + Integer.valueOf(num))); }; final VLSFunctionAsTerm cstTerm = ObjectExtensions.operator_doubleArrow(_createVLSFunctionAsTerm, _function_2); + if (isNotEnum) { + trace.definedElement2String.put(type_1.getElements().get(index), cstTerm.getFunctor()); + } final VLSConstant cst = this.support.toConstant(cstTerm); trace.uniqueInstances.add(cst); - final int index = (i - globalCounter); VLSFofFormula _createVLSFofFormula_1 = this.factory.createVLSFofFormula(); final Procedure1 _function_3 = (VLSFofFormula it) -> { - it.setName(this.support.toIDMultiple("enumScope", CollectionsUtil.lookup(type_1, trace.type2Predicate).getConstant().toString(), + String _xifexpression = null; + if (isNotEnum) { + _xifexpression = "definedType"; + } else { + _xifexpression = "enumScope"; + } + it.setName(this.support.toIDMultiple(_xifexpression, CollectionsUtil.lookup(type_1, trace.type2Predicate).getConstant().toString(), type_1.getElements().get(index).getName().split(" ")[0])); it.setFofRole("axiom"); VLSUniversalQuantifier _createVLSUniversalQuantifier = this.factory.createVLSUniversalQuantifier(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index c0c367a1..a2a573fc 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -20,6 +20,117 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index 0d17c01b..f8fc4d59 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -7,6 +7,11 @@ + + + + + @@ -14,6 +19,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -22,6 +124,115 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 3fc3d70f..bbea9822 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 @@ -81,8 +81,8 @@ class FAMTest { // add configuration things, in config file first it.documentationLevel = DocumentationLevel::FULL - it.typeScopes.minNewElements = 4 - it.typeScopes.maxNewElements = 5 + it.typeScopes.minNewElements = 24 + it.typeScopes.maxNewElements = 25 if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax it.contCycleLevel = 5 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 2cecdaac..7e2c1f12 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index a34ab846..9ac7c906 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index a18fd1a5..60e770c6 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index 0969c84c..ecbaed63 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index f0af3ba5..5b017f34 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index 08f1b4a7..1fcaf9bd 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -77,8 +77,8 @@ public class FAMTest { VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); final Procedure1 _function = (VampireSolverConfiguration it) -> { it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 4; - it.typeScopes.maxNewElements = 5; + it.typeScopes.minNewElements = 24; + it.typeScopes.maxNewElements = 25; int _size = typeMapMin.size(); boolean _notEquals = (_size != 0); if (_notEquals) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index c5ed4b90..1bcd0a44 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 21fdd9b7..6272497d 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index b1887ff2..2f327d75 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From f1f2a1fac60aa00aa21cf9165e34666c108e8e4b Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Sun, 12 May 2019 22:27:13 -0400 Subject: Pre-realisticBranchCreation Commit --- .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1701 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2526 -> 2526 bytes .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 5892 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18150 -> 18149 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4656 -> 4656 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 11904 -> 11904 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 6454 -> 6454 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 10667 -> 10667 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13046 -> 13046 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 11136 -> 11136 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 4908 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../metamodels/yakindu.aird | 1 - .../metamodels/yakindu.ecore | 39 +- .../metamodels/yakindu.genmodel | 2 +- .../metamodels/yakindu.genmodel_ | 34 + .../plugin.xml | 78 +- .../yakindu/queries/yakinduMutatedPatterns.vql | 270 ----- .../yakindu/queries/yakinduMutatedPatterns.vql_ | 270 +++++ .../test/yakindu/queries/yakinduPatterns.vql | 16 +- .../standalone/test/ecore/queries/.gitignore | 13 - .../standalone/test/fam/queries/.gitignore | 10 - .../standalone/test/fam/queries/Type.java | 770 --------------- .../standalone/test/yakindu/Choice.java | 2 +- .../standalone/test/yakindu/CompositeElement.java | 4 +- .../dslreasoner/standalone/test/yakindu/Entry.java | 2 +- .../dslreasoner/standalone/test/yakindu/Exit.java | 2 +- .../standalone/test/yakindu/FinalState.java | 2 +- .../standalone/test/yakindu/Pseudostate.java | 2 +- .../standalone/test/yakindu/Region.java | 4 +- .../standalone/test/yakindu/RegularState.java | 2 +- .../dslreasoner/standalone/test/yakindu/State.java | 2 +- .../standalone/test/yakindu/Statechart.java | 2 +- .../standalone/test/yakindu/Synchronization.java | 2 +- .../standalone/test/yakindu/Transition.java | 6 +- .../standalone/test/yakindu/Vertex.java | 6 +- .../standalone/test/yakindu/YakinduFactory.java | 114 +++ .../standalone/test/yakindu/YakinduPackage.java | 1038 ++++++++++++++++++++ .../standalone/test/yakindu/impl/ChoiceImpl.java | 4 +- .../test/yakindu/impl/CompositeElementImpl.java | 16 +- .../standalone/test/yakindu/impl/EntryImpl.java | 4 +- .../standalone/test/yakindu/impl/ExitImpl.java | 4 +- .../test/yakindu/impl/FinalStateImpl.java | 4 +- .../test/yakindu/impl/PseudostateImpl.java | 4 +- .../standalone/test/yakindu/impl/RegionImpl.java | 16 +- .../test/yakindu/impl/RegularStateImpl.java | 4 +- .../standalone/test/yakindu/impl/StateImpl.java | 20 +- .../test/yakindu/impl/StatechartImpl.java | 4 +- .../test/yakindu/impl/SynchronizationImpl.java | 4 +- .../test/yakindu/impl/TransitionImpl.java | 54 +- .../standalone/test/yakindu/impl/VertexImpl.java | 32 +- .../test/yakindu/impl/YakinduFactoryImpl.java | 183 ++++ .../test/yakindu/impl/YakinduPackageImpl.java | 494 ++++++++++ .../test/yakindu/impl/yakinduFactoryImpl.java | 183 ---- .../test/yakindu/impl/yakinduPackageImpl.java | 494 ---------- .../test/yakindu/util/YakinduAdapterFactory.java | 336 +++++++ .../test/yakindu/util/YakinduSwitch.java | 378 +++++++ .../test/yakindu/util/yakinduAdapterFactory.java | 336 ------- .../test/yakindu/util/yakinduSwitch.java | 378 ------- .../standalone/test/yakindu/yakinduFactory.java | 114 --- .../standalone/test/yakindu/yakinduPackage.java | 1038 -------------------- .../plugin.xml | 3 - .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4545 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6314 -> 6314 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 7116 -> 7116 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6456 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 6678 -> 7025 bytes .../ecse/dslreasoner/vampire/icse/YakinduTest.java | 108 +- .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes 89 files changed, 2992 insertions(+), 3916 deletions(-) create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel_ delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql_ delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduPackage.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduFactoryImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduPackageImpl.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduAdapterFactory.java create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduSwitch.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index 3ab0ceba..3f997d1e 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index 3d2fc82c..fd411426 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 599f4b11..ec6f2b5e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 39db4d8f..142268cc 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 261f76db..83816584 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index 23282723..ef0e981f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index df1b5191..7ec5c9c6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 712d5877..0efc1f64 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 52de9434..35e9ce12 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 5074417c..90005e11 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 9411e824..8e4e1612 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index bc079ba9..cc1180a8 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index 2f3d05aa..8a562c45 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index 62275f93..fb30c8b3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index c5c4ea67..bc26963e 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 45665484..d83995ca 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index cab2b7ec..43712734 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 677cb718..b395b0c5 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index d071aa8a..3e571f5b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 48090814..6c116851 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 154e42a2..7ba8f303 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 61774e26..ad62b1f9 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 2798d324..150ac835 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index 5f3f349b..c181e53c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 787c44a2..68d8cfb3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index b6e94088..1bef8bd1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index cd1b994d..9c4555e0 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 2cc7c421..7bd6797c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 25a165b1..6a10d85a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 8697d473..26460f68 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird index be45a301..518acc99 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.aird @@ -2,7 +2,6 @@ yakindu.ecore - yakindu.genmodel diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore index 0c944db8..0e800e4a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore @@ -1,26 +1,33 @@ - - + + - - + + - + - - + + - - - - - + + + + + - + - - - + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel index b1f75d76..46801b3e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel @@ -5,7 +5,7 @@ rootExtendsClass="org.eclipse.emf.ecore.impl.MinimalEObjectImpl$Container" importerID="org.eclipse.emf.importer.ecore" complianceLevel="8.0" copyrightFields="false" operationReflection="true" importOrganizing="true"> yakindu.ecore - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel_ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel_ new file mode 100644 index 00000000..b1f75d76 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.genmodel_ @@ -0,0 +1,34 @@ + + + yakindu.ecore + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml index a2a573fc..0335dc9f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/plugin.xml @@ -4,10 +4,6 @@ - - - - @@ -34,74 +30,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -129,6 +57,8 @@ + + @@ -140,4 +70,8 @@ + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql deleted file mode 100644 index 2e498670..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql +++ /dev/null @@ -1,270 +0,0 @@ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries - -import epackage "YakinduMetamodel" - -///////// -// Entry -///////// - -pattern entryInRegion_M0(r1 : Region, e1 : Entry) { - Region.vertices(r1, e1); -} -pattern entryInRegion_M1(r1 : Region, e1) { - Region.vertices(r1, e1); -} -pattern entryInRegion_M2(r1 : Region, e1: Entry) { - // For positive constraint - Region(r1);Entry(e1); -} - - -//@Constraint(severity="error", message="error", key = {r1}) -pattern noEntryInRegion_M0(r1 : Region) { - neg find entryInRegion_M0(r1, _); -} -pattern noEntryInRegion_M1(r1 : Region) { - neg find entryInRegion_M1(r1, _); -} -pattern noEntryInRegion_M2(r1 : Region) { - neg find entryInRegion_M2(r1, _); -} -pattern noEntryInRegion_M3(r1 : Region) { - find entryInRegion_M0(r1, _); -} -pattern noEntryInRegion_M4(r1 : Region) { - find entryInRegion_M1(r1, _); -} -pattern noEntryInRegion_M5(r1 : Region) { - find entryInRegion_M2(r1, _); -} - -//@Constraint(severity="error", message="error", key = {r}) -pattern multipleEntryInRegion_M0(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M1(r : Region) { - find entryInRegion_M1(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M2(r : Region) { - find entryInRegion_M2(r, e1); - find entryInRegion_M0(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M3(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M1(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M4(r : Region) { - find entryInRegion_M2(r, e1); - find entryInRegion_M2(r, e2); - e1 != e2; -} -pattern multipleEntryInRegion_M5(r : Region) { - find entryInRegion_M0(r, e1); - find entryInRegion_M0(r, e2); -} - - -pattern transition_M0(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Transition.target(t, trg); -} -pattern transition_M1(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Vertex(trg); -} -pattern transition_M2(t : Transition, src : Vertex, trg : Vertex) { - Vertex(src); - Transition.target(t, trg); -} -pattern transition_M3(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t_x, src); - Transition.target(t, trg); -} -pattern transition_M4(t : Transition, src : Vertex, trg : Vertex) { - Transition.source(t, src); - Transition.target(t_x, trg); -} - -//@Constraint(severity="error", message="error", key = {e}) -pattern incomingToEntry_M0(t : Transition, e : Entry) { - find transition_M0(t, _, e); -} -pattern incomingToEntry_1(t : Transition, e) { - find transition_M0(t, _, e); -} -pattern incomingToEntry_2(t : Transition, e : Entry) { - find transition_M1(t, _, e); -} -pattern incomingToEntry_3(t : Transition, e : Entry) { - find transition_M2(t, _, e); -} -pattern incomingToEntry_4(t : Transition, e : Entry) { - find transition_M3(t, _, e); -} -pattern incomingToEntry_5(t : Transition, e : Entry) { - find transition_M4(t, _, e); -} - -pattern noOutgoingTransitionFromEntry_M0(e : Entry) { - neg find transition_M0(_, e, _); -} - -pattern noOutgoingTransitionFromEntry_M1(e) { - Vertex(e); - neg find transition_M0(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M2(e : Entry) { - neg find transition_M1(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M3(e : Entry) { - neg find transition_M2(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M4(e : Entry) { - neg find transition_M3(_, e, _); -} -pattern noOutgoingTransitionFromEntry_M5(e : Entry) { - neg find transition_M4(_, e, _); -} - - -//@Constraint(severity="error", message="error", key = {e}) -pattern multipleTransitionFromEntry_M0(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M1(e, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M2(e : Entry, t1 : Transition, t2: Transition) { - Transition(t1); - Entry.outgoingTransitions(e,t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M3(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Transition(t2); - t1!=t2; -} -pattern multipleTransitionFromEntry_M4(e : Entry, t1 : Transition, t2: Transition) { - Entry.outgoingTransitions(e,t1); - Entry.outgoingTransitions(e,t2); -} - -///////// -// Exit -///////// - -//@Constraint(severity="error", message="error", key = {e}) -pattern outgoingFromExit_M0(t : Transition, e : Exit) { - Exit.outgoingTransitions(e,t); -} -pattern outgoingFromExit_M1(t : Transition, e) { - Vertex.outgoingTransitions(e,t); -} -pattern outgoingFromExit_M2(t : Transition, e : Exit) { - Transition(t); - Exit(e); -} - -///////// -// Final -///////// - -//@Constraint(severity="error", message="error", key = {f}) -pattern outgoingFromFinal_M0(t : Transition, f : FinalState) { - FinalState.outgoingTransitions(f,t); -} -pattern outgoingFromFinal_M1(t : Transition, f) { - Vertex.outgoingTransitions(f,t); -} -pattern outgoingFromFinal_M2(t : Transition, f : FinalState) { - Transition(t); - FinalState(f); -} - -///////// -// State vs Region -///////// - -//@Constraint(severity="error", message="error", key = {region}) -pattern noStateInRegion_M0(region: Region) { - neg find StateInRegion_M0(region,_); -} -pattern noStateInRegion_M1(region: Region) { - neg find StateInRegion_M1(region,_); -} -pattern noStateInRegion_M2(region: Region) { - neg find StateInRegion_M2(region,_); -} -pattern noStateInRegion_M3(region: Region) { - find StateInRegion_M0(region,_); -} - -pattern StateInRegion_M0(region: Region, state: State) { - Region.vertices(region,state); -} -pattern StateInRegion_M1(region: Region, state) { - Region.vertices(region,state); -} -pattern StateInRegion_M2(region: Region, state:State) { - Region(region);State(state); -} - -///////// -// Choice -///////// - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoOutgoing_M0(c : Choice) { - neg find transition_M0(_, c, _); -} -pattern choiceHasNoOutgoing_M1(c:Vertex) { - neg find transition_M0(_, c, _); -} -pattern choiceHasNoOutgoing_M2(c : Choice) { - neg find transition_M1(_, c, _); -} -pattern choiceHasNoOutgoing_M3(c : Choice) { - neg find transition_M2(_, c, _); -} -pattern choiceHasNoOutgoing_M4(c : Choice) { - neg find transition_M3(_, c, _); -} -pattern choiceHasNoOutgoing_M5(c : Choice) { - neg find transition_M4(_, c, _); -} -pattern choiceHasNoOutgoing_M6(c : Choice) { - find transition_M0(_, c, _); -} - -@Constraint(severity="error", message="error", key = {c}) -pattern choiceHasNoIncoming_M0(c: Choice) { - neg find transition_M0(_, _, c); -} -pattern choiceHasNoIncoming_M1(c:Vertex) { - neg find transition_M0(_, _, c); -} -pattern choiceHasNoIncoming_M2(c: Choice) { - neg find transition_M1(_, _, c); -} -pattern choiceHasNoIncoming_M3(c: Choice) { - neg find transition_M2(_, _, c); -} -pattern choiceHasNoIncoming_M4(c: Choice) { - neg find transition_M3(_, _, c); -} -pattern choiceHasNoIncoming_M5(c: Choice) { - neg find transition_M4(_, _, c); -} -pattern choiceHasNoIncoming_M6(c: Choice) { - find transition_M0(_, _, c); -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql_ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql_ new file mode 100644 index 00000000..2e498670 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduMutatedPatterns.vql_ @@ -0,0 +1,270 @@ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries + +import epackage "YakinduMetamodel" + +///////// +// Entry +///////// + +pattern entryInRegion_M0(r1 : Region, e1 : Entry) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M1(r1 : Region, e1) { + Region.vertices(r1, e1); +} +pattern entryInRegion_M2(r1 : Region, e1: Entry) { + // For positive constraint + Region(r1);Entry(e1); +} + + +//@Constraint(severity="error", message="error", key = {r1}) +pattern noEntryInRegion_M0(r1 : Region) { + neg find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M1(r1 : Region) { + neg find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M2(r1 : Region) { + neg find entryInRegion_M2(r1, _); +} +pattern noEntryInRegion_M3(r1 : Region) { + find entryInRegion_M0(r1, _); +} +pattern noEntryInRegion_M4(r1 : Region) { + find entryInRegion_M1(r1, _); +} +pattern noEntryInRegion_M5(r1 : Region) { + find entryInRegion_M2(r1, _); +} + +//@Constraint(severity="error", message="error", key = {r}) +pattern multipleEntryInRegion_M0(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M1(r : Region) { + find entryInRegion_M1(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M2(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M0(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M3(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M1(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M4(r : Region) { + find entryInRegion_M2(r, e1); + find entryInRegion_M2(r, e2); + e1 != e2; +} +pattern multipleEntryInRegion_M5(r : Region) { + find entryInRegion_M0(r, e1); + find entryInRegion_M0(r, e2); +} + + +pattern transition_M0(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t, trg); +} +pattern transition_M1(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Vertex(trg); +} +pattern transition_M2(t : Transition, src : Vertex, trg : Vertex) { + Vertex(src); + Transition.target(t, trg); +} +pattern transition_M3(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t_x, src); + Transition.target(t, trg); +} +pattern transition_M4(t : Transition, src : Vertex, trg : Vertex) { + Transition.source(t, src); + Transition.target(t_x, trg); +} + +//@Constraint(severity="error", message="error", key = {e}) +pattern incomingToEntry_M0(t : Transition, e : Entry) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_1(t : Transition, e) { + find transition_M0(t, _, e); +} +pattern incomingToEntry_2(t : Transition, e : Entry) { + find transition_M1(t, _, e); +} +pattern incomingToEntry_3(t : Transition, e : Entry) { + find transition_M2(t, _, e); +} +pattern incomingToEntry_4(t : Transition, e : Entry) { + find transition_M3(t, _, e); +} +pattern incomingToEntry_5(t : Transition, e : Entry) { + find transition_M4(t, _, e); +} + +pattern noOutgoingTransitionFromEntry_M0(e : Entry) { + neg find transition_M0(_, e, _); +} + +pattern noOutgoingTransitionFromEntry_M1(e) { + Vertex(e); + neg find transition_M0(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M2(e : Entry) { + neg find transition_M1(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M3(e : Entry) { + neg find transition_M2(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M4(e : Entry) { + neg find transition_M3(_, e, _); +} +pattern noOutgoingTransitionFromEntry_M5(e : Entry) { + neg find transition_M4(_, e, _); +} + + +//@Constraint(severity="error", message="error", key = {e}) +pattern multipleTransitionFromEntry_M0(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M1(e, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M2(e : Entry, t1 : Transition, t2: Transition) { + Transition(t1); + Entry.outgoingTransitions(e,t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M3(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Transition(t2); + t1!=t2; +} +pattern multipleTransitionFromEntry_M4(e : Entry, t1 : Transition, t2: Transition) { + Entry.outgoingTransitions(e,t1); + Entry.outgoingTransitions(e,t2); +} + +///////// +// Exit +///////// + +//@Constraint(severity="error", message="error", key = {e}) +pattern outgoingFromExit_M0(t : Transition, e : Exit) { + Exit.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M1(t : Transition, e) { + Vertex.outgoingTransitions(e,t); +} +pattern outgoingFromExit_M2(t : Transition, e : Exit) { + Transition(t); + Exit(e); +} + +///////// +// Final +///////// + +//@Constraint(severity="error", message="error", key = {f}) +pattern outgoingFromFinal_M0(t : Transition, f : FinalState) { + FinalState.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M1(t : Transition, f) { + Vertex.outgoingTransitions(f,t); +} +pattern outgoingFromFinal_M2(t : Transition, f : FinalState) { + Transition(t); + FinalState(f); +} + +///////// +// State vs Region +///////// + +//@Constraint(severity="error", message="error", key = {region}) +pattern noStateInRegion_M0(region: Region) { + neg find StateInRegion_M0(region,_); +} +pattern noStateInRegion_M1(region: Region) { + neg find StateInRegion_M1(region,_); +} +pattern noStateInRegion_M2(region: Region) { + neg find StateInRegion_M2(region,_); +} +pattern noStateInRegion_M3(region: Region) { + find StateInRegion_M0(region,_); +} + +pattern StateInRegion_M0(region: Region, state: State) { + Region.vertices(region,state); +} +pattern StateInRegion_M1(region: Region, state) { + Region.vertices(region,state); +} +pattern StateInRegion_M2(region: Region, state:State) { + Region(region);State(state); +} + +///////// +// Choice +///////// + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoOutgoing_M0(c : Choice) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M1(c:Vertex) { + neg find transition_M0(_, c, _); +} +pattern choiceHasNoOutgoing_M2(c : Choice) { + neg find transition_M1(_, c, _); +} +pattern choiceHasNoOutgoing_M3(c : Choice) { + neg find transition_M2(_, c, _); +} +pattern choiceHasNoOutgoing_M4(c : Choice) { + neg find transition_M3(_, c, _); +} +pattern choiceHasNoOutgoing_M5(c : Choice) { + neg find transition_M4(_, c, _); +} +pattern choiceHasNoOutgoing_M6(c : Choice) { + find transition_M0(_, c, _); +} + +@Constraint(severity="error", message="error", key = {c}) +pattern choiceHasNoIncoming_M0(c: Choice) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M1(c:Vertex) { + neg find transition_M0(_, _, c); +} +pattern choiceHasNoIncoming_M2(c: Choice) { + neg find transition_M1(_, _, c); +} +pattern choiceHasNoIncoming_M3(c: Choice) { + neg find transition_M2(_, _, c); +} +pattern choiceHasNoIncoming_M4(c: Choice) { + neg find transition_M3(_, _, c); +} +pattern choiceHasNoIncoming_M5(c: Choice) { + neg find transition_M4(_, _, c); +} +pattern choiceHasNoIncoming_M6(c: Choice) { + find transition_M0(_, _, c); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql index 597b1691..ea8184de 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql @@ -217,11 +217,11 @@ pattern twoSynch(s1 : Synchronization, s2 : Synchronization) { /** * Model generation task: at least one synch */ -//@Constraint(severity="error", message="error", key = {s}) -//pattern noSynch(s:Statechart) { -// Statechart(s); -// neg find synch(_); -//} -//pattern synch(s:Synchronization) { -// Synchronization(s); -//} \ No newline at end of file +@Constraint(severity="error", message="error", key = {s}) +pattern noSynch(s:Statechart) { + Statechart(s); + neg find synch(_); +} +pattern synch(s:Synchronization) { + Synchronization(s); +} \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore deleted file mode 100644 index a9786e0f..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/ecore/queries/.gitignore +++ /dev/null @@ -1,13 +0,0 @@ -/.DirectSupertype.java._trace -/.Ecore.java._trace -/.LoopInInheritence.java._trace -/.NonSymmetricOpposite.java._trace -/.Opposite.java._trace -/.OppositeDifferentClass.java._trace -/.EcorePatterns.java._trace -/DirectSupertype.java -/EcorePatterns.java -/LoopInInheritence.java -/NonSymmetricOpposite.java -/Opposite.java -/OppositeDifferentClass.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore deleted file mode 100644 index 60f1891b..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/.gitignore +++ /dev/null @@ -1,10 +0,0 @@ -/.FamPatterns.java._trace -/.Model.java._trace -/.Parent.java._trace -/.RootElements.java._trace -/.TerminatorAndInformation.java._trace -/.Type.java._trace -/FamPatterns.java -/Model.java -/Parent.java -/RootElements.java diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java deleted file mode 100644 index bc3230c5..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src-gen/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/Type.java +++ /dev/null @@ -1,770 +0,0 @@ -/** - * Generated from platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/fam/queries/famPatterns.vql - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries; - -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function; -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType; -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Parent; -import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.RootElements; -import java.util.Arrays; -import java.util.Collection; -import java.util.LinkedHashSet; -import java.util.List; -import java.util.Objects; -import java.util.Optional; -import java.util.Set; -import java.util.function.Consumer; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import org.apache.log4j.Logger; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EDataType; -import org.eclipse.viatra.query.runtime.api.IPatternMatch; -import org.eclipse.viatra.query.runtime.api.IQuerySpecification; -import org.eclipse.viatra.query.runtime.api.ViatraQueryEngine; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFPQuery; -import org.eclipse.viatra.query.runtime.api.impl.BaseGeneratedEMFQuerySpecification; -import org.eclipse.viatra.query.runtime.api.impl.BaseMatcher; -import org.eclipse.viatra.query.runtime.api.impl.BasePatternMatch; -import org.eclipse.viatra.query.runtime.emf.types.EClassTransitiveInstancesKey; -import org.eclipse.viatra.query.runtime.emf.types.EDataTypeInSlotsKey; -import org.eclipse.viatra.query.runtime.matchers.backend.QueryEvaluationHint; -import org.eclipse.viatra.query.runtime.matchers.psystem.PBody; -import org.eclipse.viatra.query.runtime.matchers.psystem.PVariable; -import org.eclipse.viatra.query.runtime.matchers.psystem.annotations.PAnnotation; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.Equality; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.ExportedParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicdeferred.NegativePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.ConstantValue; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.PositivePatternCall; -import org.eclipse.viatra.query.runtime.matchers.psystem.basicenumerables.TypeConstraint; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameter; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PParameterDirection; -import org.eclipse.viatra.query.runtime.matchers.psystem.queries.PVisibility; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuple; -import org.eclipse.viatra.query.runtime.matchers.tuple.Tuples; -import org.eclipse.viatra.query.runtime.util.ViatraQueryLoggingUtil; - -/** - * A pattern-specific query specification that can instantiate Matcher in a type-safe way. - * - *

Original source: - *

- *         {@literal @}QueryBasedFeature 
- *         pattern type(This : Function, Target : FunctionType) = {
- *         	find rootElements(_Model, This);
- *         	Target == FunctionType::Root;
- *         } or {
- *         	neg find parent(_Child, This);
- *         	neg find rootElements(_Model, This);
- *         	Target == FunctionType::Leaf;
- *         } or  {
- *         	find parent(This, _Par);
- *         	find parent(_Child, This);
- *         	Target == FunctionType::Intermediate;
- *         }
- * 
- * - * @see Matcher - * @see Match - * - */ -@SuppressWarnings("all") -public final class Type extends BaseGeneratedEMFQuerySpecification { - /** - * Pattern-specific match representation of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type pattern, - * to be used in conjunction with {@link Matcher}. - * - *

Class fields correspond to parameters of the pattern. Fields with value null are considered unassigned. - * Each instance is a (possibly partial) substitution of pattern parameters, - * usable to represent a match of the pattern in the result of a query, - * or to specify the bound (fixed) input parameters when issuing a query. - * - * @see Matcher - * - */ - public static abstract class Match extends BasePatternMatch { - private Function fThis; - - private FunctionType fTarget; - - private static List parameterNames = makeImmutableList("This", "Target"); - - private Match(final Function pThis, final FunctionType pTarget) { - this.fThis = pThis; - this.fTarget = pTarget; - } - - @Override - public Object get(final String parameterName) { - if ("This".equals(parameterName)) return this.fThis; - if ("Target".equals(parameterName)) return this.fTarget; - return null; - } - - public Function getThis() { - return this.fThis; - } - - public FunctionType getTarget() { - return this.fTarget; - } - - @Override - public boolean set(final String parameterName, final Object newValue) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - if ("This".equals(parameterName) ) { - this.fThis = (Function) newValue; - return true; - } - if ("Target".equals(parameterName) ) { - this.fTarget = (FunctionType) newValue; - return true; - } - return false; - } - - public void setThis(final Function pThis) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fThis = pThis; - } - - public void setTarget(final FunctionType pTarget) { - if (!isMutable()) throw new java.lang.UnsupportedOperationException(); - this.fTarget = pTarget; - } - - @Override - public String patternName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"; - } - - @Override - public List parameterNames() { - return Type.Match.parameterNames; - } - - @Override - public Object[] toArray() { - return new Object[]{fThis, fTarget}; - } - - @Override - public Type.Match toImmutable() { - return isMutable() ? newMatch(fThis, fTarget) : this; - } - - @Override - public String prettyPrint() { - StringBuilder result = new StringBuilder(); - result.append("\"This\"=" + prettyPrintValue(fThis) + ", "); - result.append("\"Target\"=" + prettyPrintValue(fTarget)); - return result.toString(); - } - - @Override - public int hashCode() { - return Objects.hash(fThis, fTarget); - } - - @Override - public boolean equals(final Object obj) { - if (this == obj) - return true; - if (obj == null) { - return false; - } - if ((obj instanceof Type.Match)) { - Type.Match other = (Type.Match) obj; - return Objects.equals(fThis, other.fThis) && Objects.equals(fTarget, other.fTarget); - } else { - // this should be infrequent - if (!(obj instanceof IPatternMatch)) { - return false; - } - IPatternMatch otherSig = (IPatternMatch) obj; - return Objects.equals(specification(), otherSig.specification()) && Arrays.deepEquals(toArray(), otherSig.toArray()); - } - } - - @Override - public Type specification() { - return Type.instance(); - } - - /** - * Returns an empty, mutable match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @return the empty match. - * - */ - public static Type.Match newEmptyMatch() { - return new Mutable(null, null); - } - - /** - * Returns a mutable (partial) match. - * Fields of the mutable match can be filled to create a partial match, usable as matcher input. - * - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return the new, mutable (partial) match object. - * - */ - public static Type.Match newMutableMatch(final Function pThis, final FunctionType pTarget) { - return new Mutable(pThis, pTarget); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return the (partial) match object. - * - */ - public static Type.Match newMatch(final Function pThis, final FunctionType pTarget) { - return new Immutable(pThis, pTarget); - } - - private static final class Mutable extends Type.Match { - Mutable(final Function pThis, final FunctionType pTarget) { - super(pThis, pTarget); - } - - @Override - public boolean isMutable() { - return true; - } - } - - private static final class Immutable extends Type.Match { - Immutable(final Function pThis, final FunctionType pTarget) { - super(pThis, pTarget); - } - - @Override - public boolean isMutable() { - return false; - } - } - } - - /** - * Generated pattern matcher API of the ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type pattern, - * providing pattern-specific query methods. - * - *

Use the pattern matcher on a given model via {@link #on(ViatraQueryEngine)}, - * e.g. in conjunction with {@link ViatraQueryEngine#on(QueryScope)}. - * - *

Matches of the pattern will be represented as {@link Match}. - * - *

Original source: - *

-   * {@literal @}QueryBasedFeature 
-   * pattern type(This : Function, Target : FunctionType) = {
-   * 	find rootElements(_Model, This);
-   * 	Target == FunctionType::Root;
-   * } or {
-   * 	neg find parent(_Child, This);
-   * 	neg find rootElements(_Model, This);
-   * 	Target == FunctionType::Leaf;
-   * } or  {
-   * 	find parent(This, _Par);
-   * 	find parent(_Child, This);
-   * 	Target == FunctionType::Intermediate;
-   * }
-   * 
- * - * @see Match - * @see Type - * - */ - public static class Matcher extends BaseMatcher { - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - public static Type.Matcher on(final ViatraQueryEngine engine) { - // check if matcher already exists - Matcher matcher = engine.getExistingMatcher(querySpecification()); - if (matcher == null) { - matcher = (Matcher)engine.getMatcher(querySpecification()); - } - return matcher; - } - - /** - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * @return an initialized matcher - * @noreference This method is for internal matcher initialization by the framework, do not call it manually. - * - */ - public static Type.Matcher create() { - return new Matcher(); - } - - private final static int POSITION_THIS = 0; - - private final static int POSITION_TARGET = 1; - - private final static Logger LOGGER = ViatraQueryLoggingUtil.getLogger(Type.Matcher.class); - - /** - * Initializes the pattern matcher within an existing VIATRA Query engine. - * If the pattern matcher is already constructed in the engine, only a light-weight reference is returned. - * - * @param engine the existing VIATRA Query engine in which this matcher will be created. - * @throws ViatraQueryRuntimeException if an error occurs during pattern matcher creation - * - */ - private Matcher() { - super(querySpecification()); - } - - /** - * Returns the set of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return matches represented as a Match object. - * - */ - public Collection getAllMatches(final Function pThis, final FunctionType pTarget) { - return rawStreamAllMatches(new Object[]{pThis, pTarget}).collect(Collectors.toSet()); - } - - /** - * Returns a stream of all matches of the pattern that conform to the given fixed values of some parameters. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return a stream of matches represented as a Match object. - * - */ - public Stream streamAllMatches(final Function pThis, final FunctionType pTarget) { - return rawStreamAllMatches(new Object[]{pThis, pTarget}); - } - - /** - * Returns an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return a match represented as a Match object, or null if no match is found. - * - */ - public Optional getOneArbitraryMatch(final Function pThis, final FunctionType pTarget) { - return rawGetOneArbitraryMatch(new Object[]{pThis, pTarget}); - } - - /** - * Indicates whether the given combination of specified pattern parameters constitute a valid pattern match, - * under any possible substitution of the unspecified parameters (if any). - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return true if the input is a valid (partial) match of the pattern. - * - */ - public boolean hasMatch(final Function pThis, final FunctionType pTarget) { - return rawHasMatch(new Object[]{pThis, pTarget}); - } - - /** - * Returns the number of all matches of the pattern that conform to the given fixed values of some parameters. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return the number of pattern matches found. - * - */ - public int countMatches(final Function pThis, final FunctionType pTarget) { - return rawCountMatches(new Object[]{pThis, pTarget}); - } - - /** - * Executes the given processor on an arbitrarily chosen match of the pattern that conforms to the given fixed values of some parameters. - * Neither determinism nor randomness of selection is guaranteed. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @param processor the action that will process the selected match. - * @return true if the pattern has at least one match with the given parameter values, false if the processor was not invoked - * - */ - public boolean forOneArbitraryMatch(final Function pThis, final FunctionType pTarget, final Consumer processor) { - return rawForOneArbitraryMatch(new Object[]{pThis, pTarget}, processor); - } - - /** - * Returns a new (partial) match. - * This can be used e.g. to call the matcher with a partial match. - *

The returned match will be immutable. Use {@link #newEmptyMatch()} to obtain a mutable match object. - * @param pThis the fixed value of pattern parameter This, or null if not bound. - * @param pTarget the fixed value of pattern parameter Target, or null if not bound. - * @return the (partial) match object. - * - */ - public Type.Match newMatch(final Function pThis, final FunctionType pTarget) { - return Type.Match.newMatch(pThis, pTarget); - } - - /** - * Retrieve the set of values that occur in matches for This. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfThis(final Object[] parameters) { - return rawStreamAllValues(POSITION_THIS, parameters).map(Function.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for This. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfThis() { - return rawStreamAllValuesOfThis(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for This. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfThis() { - return rawStreamAllValuesOfThis(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for This. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfThis(final Type.Match partialMatch) { - return rawStreamAllValuesOfThis(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for This. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfThis(final FunctionType pTarget) { - return rawStreamAllValuesOfThis(new Object[]{null, pTarget}); - } - - /** - * Retrieve the set of values that occur in matches for This. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfThis(final Type.Match partialMatch) { - return rawStreamAllValuesOfThis(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for This. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfThis(final FunctionType pTarget) { - return rawStreamAllValuesOfThis(new Object[]{null, pTarget}).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for Target. - * @return the Set of all values or empty set if there are no matches - * - */ - protected Stream rawStreamAllValuesOfTarget(final Object[] parameters) { - return rawStreamAllValues(POSITION_TARGET, parameters).map(FunctionType.class::cast); - } - - /** - * Retrieve the set of values that occur in matches for Target. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfTarget() { - return rawStreamAllValuesOfTarget(emptyArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for Target. - * @return the Set of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfTarget() { - return rawStreamAllValuesOfTarget(emptyArray()); - } - - /** - * Retrieve the set of values that occur in matches for Target. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfTarget(final Type.Match partialMatch) { - return rawStreamAllValuesOfTarget(partialMatch.toArray()); - } - - /** - * Retrieve the set of values that occur in matches for Target. - *

- * NOTE: It is important not to modify the source model while the stream is being processed. - * If the match set of the pattern changes during processing, the contents of the stream is undefined. - * In such cases, either rely on {@link #getAllMatches()} or collect the results of the stream in end-user code. - * - * @return the Stream of all values or empty set if there are no matches - * - */ - public Stream streamAllValuesOfTarget(final Function pThis) { - return rawStreamAllValuesOfTarget(new Object[]{pThis, null}); - } - - /** - * Retrieve the set of values that occur in matches for Target. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfTarget(final Type.Match partialMatch) { - return rawStreamAllValuesOfTarget(partialMatch.toArray()).collect(Collectors.toSet()); - } - - /** - * Retrieve the set of values that occur in matches for Target. - * @return the Set of all values or empty set if there are no matches - * - */ - public Set getAllValuesOfTarget(final Function pThis) { - return rawStreamAllValuesOfTarget(new Object[]{pThis, null}).collect(Collectors.toSet()); - } - - @Override - protected Type.Match tupleToMatch(final Tuple t) { - try { - return Type.Match.newMatch((Function) t.get(POSITION_THIS), (FunctionType) t.get(POSITION_TARGET)); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in tuple not properly typed!",e); - return null; - } - } - - @Override - protected Type.Match arrayToMatch(final Object[] match) { - try { - return Type.Match.newMatch((Function) match[POSITION_THIS], (FunctionType) match[POSITION_TARGET]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - @Override - protected Type.Match arrayToMatchMutable(final Object[] match) { - try { - return Type.Match.newMutableMatch((Function) match[POSITION_THIS], (FunctionType) match[POSITION_TARGET]); - } catch(ClassCastException e) { - LOGGER.error("Element(s) in array not properly typed!",e); - return null; - } - } - - /** - * @return the singleton instance of the query specification of this pattern - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static IQuerySpecification querySpecification() { - return Type.instance(); - } - } - - private Type() { - super(GeneratedPQuery.INSTANCE); - } - - /** - * @return the singleton instance of the query specification - * @throws ViatraQueryRuntimeException if the pattern definition could not be loaded - * - */ - public static Type instance() { - try{ - return LazyHolder.INSTANCE; - } catch (ExceptionInInitializerError err) { - throw processInitializerError(err); - } - } - - @Override - protected Type.Matcher instantiate(final ViatraQueryEngine engine) { - return Type.Matcher.on(engine); - } - - @Override - public Type.Matcher instantiate() { - return Type.Matcher.create(); - } - - @Override - public Type.Match newEmptyMatch() { - return Type.Match.newEmptyMatch(); - } - - @Override - public Type.Match newMatch(final Object... parameters) { - return Type.Match.newMatch((ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function) parameters[0], (ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType) parameters[1]); - } - - /** - * Inner class allowing the singleton instance of {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type (visibility: PUBLIC, simpleName: Type, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created - * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type (visibility: PUBLIC, simpleName: Type, identifier: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.Type, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. - * - *

This workaround is required e.g. to support recursion. - * - */ - private static class LazyHolder { - private final static Type INSTANCE = new Type(); - - /** - * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. - * This initialization order is required to support indirect recursion. - * - *

The static initializer is defined using a helper field to work around limitations of the code generator. - * - */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); - - public static Object ensureInitialized() { - INSTANCE.ensureInitializedInternal(); - return null; - } - } - - private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static Type.GeneratedPQuery INSTANCE = new GeneratedPQuery(); - - private final PParameter parameter_This = new PParameter("This", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.Function", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("FamMetamodel", "Function")), PParameterDirection.INOUT); - - private final PParameter parameter_Target = new PParameter("Target", "ca.mcgill.ecse.dslreasoner.standalone.test.fam.FunctionType", new EDataTypeInSlotsKey((EDataType)getClassifierLiteralSafe("FamMetamodel", "FunctionType")), PParameterDirection.INOUT); - - private final List parameters = Arrays.asList(parameter_This, parameter_Target); - - private GeneratedPQuery() { - super(PVisibility.PUBLIC); - } - - @Override - public String getFullyQualifiedName() { - return "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.type"; - } - - @Override - public List getParameterNames() { - return Arrays.asList("This","Target"); - } - - @Override - public List getParameters() { - return parameters; - } - - @Override - public Set doGetContainedBodies() { - setEvaluationHints(new QueryEvaluationHint(null, QueryEvaluationHint.BackendRequirement.UNSPECIFIED)); - Set bodies = new LinkedHashSet<>(); - { - PBody body = new PBody(this); - PVariable var_This = body.getOrCreateVariableByName("This"); - PVariable var_Target = body.getOrCreateVariableByName("Target"); - PVariable var__Model = body.getOrCreateVariableByName("_Model"); - new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_This, parameter_This), - new ExportedParameter(body, var_Target, parameter_Target) - )); - // find rootElements(_Model, This) - new PositivePatternCall(body, Tuples.flatTupleOf(var__Model, var_This), RootElements.instance().getInternalQueryRepresentation()); - // Target == FunctionType::Root - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Root").getInstance()); - new Equality(body, var_Target, var__virtual_0_); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_This = body.getOrCreateVariableByName("This"); - PVariable var_Target = body.getOrCreateVariableByName("Target"); - PVariable var__Child = body.getOrCreateVariableByName("_Child"); - PVariable var__Model = body.getOrCreateVariableByName("_Model"); - new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_This, parameter_This), - new ExportedParameter(body, var_Target, parameter_Target) - )); - // neg find parent(_Child, This) - new NegativePatternCall(body, Tuples.flatTupleOf(var__Child, var_This), Parent.instance().getInternalQueryRepresentation()); - // neg find rootElements(_Model, This) - new NegativePatternCall(body, Tuples.flatTupleOf(var__Model, var_This), RootElements.instance().getInternalQueryRepresentation()); - // Target == FunctionType::Leaf - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Leaf").getInstance()); - new Equality(body, var_Target, var__virtual_0_); - bodies.add(body); - } - { - PBody body = new PBody(this); - PVariable var_This = body.getOrCreateVariableByName("This"); - PVariable var_Target = body.getOrCreateVariableByName("Target"); - PVariable var__Par = body.getOrCreateVariableByName("_Par"); - PVariable var__Child = body.getOrCreateVariableByName("_Child"); - new TypeConstraint(body, Tuples.flatTupleOf(var_This), new EClassTransitiveInstancesKey((EClass)getClassifierLiteral("FamMetamodel", "Function"))); - new TypeConstraint(body, Tuples.flatTupleOf(var_Target), new EDataTypeInSlotsKey((EDataType)getClassifierLiteral("FamMetamodel", "FunctionType"))); - body.setSymbolicParameters(Arrays.asList( - new ExportedParameter(body, var_This, parameter_This), - new ExportedParameter(body, var_Target, parameter_Target) - )); - // find parent(This, _Par) - new PositivePatternCall(body, Tuples.flatTupleOf(var_This, var__Par), Parent.instance().getInternalQueryRepresentation()); - // find parent(_Child, This) - new PositivePatternCall(body, Tuples.flatTupleOf(var__Child, var_This), Parent.instance().getInternalQueryRepresentation()); - // Target == FunctionType::Intermediate - PVariable var__virtual_0_ = body.getOrCreateVariableByName(".virtual{0}"); - new ConstantValue(body, var__virtual_0_, getEnumLiteral("FamMetamodel", "FunctionType", "Intermediate").getInstance()); - new Equality(body, var_Target, var__virtual_0_); - bodies.add(body); - } - { - PAnnotation annotation = new PAnnotation("QueryBasedFeature"); - addAnnotation(annotation); - } - return bodies; - } - } -} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java index cc4049c4..fc2f0328 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Choice.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getChoice() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getChoice() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java index 037b1b3c..b0e38bcf 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/CompositeElement.java @@ -18,7 +18,7 @@ import org.eclipse.emf.ecore.EObject; *

  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions Regions}
  • * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getCompositeElement() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getCompositeElement() * @model abstract="true" * @generated */ @@ -33,7 +33,7 @@ public interface CompositeElement extends EObject { *

    * * @return the value of the 'Regions' containment reference list. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getCompositeElement_Regions() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getCompositeElement_Regions() * @model containment="true" * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java index da40c481..c8adb603 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Entry.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getEntry() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getEntry() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java index 9f8e12d3..b134c14f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Exit.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getExit() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getExit() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java index 33703d36..5ec2a16a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/FinalState.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getFinalState() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getFinalState() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java index e6a003f9..670a172a 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Pseudostate.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getPseudostate() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getPseudostate() * @model abstract="true" * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java index f4c3f114..84081ae8 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Region.java @@ -18,7 +18,7 @@ import org.eclipse.emf.ecore.EObject; *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices Vertices}
  • * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegion() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getRegion() * @model * @generated */ @@ -33,7 +33,7 @@ public interface Region extends EObject { *

    * * @return the value of the 'Vertices' containment reference list. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegion_Vertices() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getRegion_Vertices() * @model containment="true" ordered="false" * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java index 7db584e5..4ad05644 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/RegularState.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getRegularState() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getRegularState() * @model abstract="true" * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java index 3c65be40..09667a01 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/State.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getState() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getState() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java index 33a1dd7a..0f8e383d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Statechart.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getStatechart() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getStatechart() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java index f1294200..a06bc066 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Synchronization.java @@ -9,7 +9,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; * * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getSynchronization() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getSynchronization() * @model * @generated */ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java index 543cc73b..c90c8d23 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Transition.java @@ -17,7 +17,7 @@ import org.eclipse.emf.ecore.EObject; *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}
  • * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getTransition() * @model * @generated */ @@ -33,7 +33,7 @@ public interface Transition extends EObject { * * @return the value of the 'Target' reference. * @see #setTarget(Vertex) - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition_Target() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getTransition_Target() * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions * @model opposite="incomingTransitions" required="true" ordered="false" * @generated @@ -61,7 +61,7 @@ public interface Transition extends EObject { * * @return the value of the 'Source' container reference. * @see #setSource(Vertex) - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getTransition_Source() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getTransition_Source() * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions * @model opposite="outgoingTransitions" transient="false" ordered="false" * @generated diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java index 6005a550..e4631e42 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/Vertex.java @@ -19,7 +19,7 @@ import org.eclipse.emf.ecore.EObject; *
  • {@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}
  • * * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getVertex() * @model abstract="true" * @generated */ @@ -35,7 +35,7 @@ public interface Vertex extends EObject { *

    * * @return the value of the 'Incoming Transitions' reference list. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex_IncomingTransitions() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getVertex_IncomingTransitions() * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget * @model opposite="target" ordered="false" * @generated @@ -53,7 +53,7 @@ public interface Vertex extends EObject { *

    * * @return the value of the 'Outgoing Transitions' containment reference list. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#getVertex_OutgoingTransitions() + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#getVertex_OutgoingTransitions() * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource * @model opposite="source" containment="true" ordered="false" * @generated diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduFactory.java new file mode 100644 index 00000000..53afae22 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduFactory.java @@ -0,0 +1,114 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.ecore.EFactory; + +/** + * + * The Factory for the model. + * It provides a create method for each non-abstract class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage + * @generated + */ +public interface YakinduFactory extends EFactory { + /** + * The singleton instance of the factory. + * + * + * @generated + */ + YakinduFactory eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduFactoryImpl.init(); + + /** + * Returns a new object of class 'Region'. + * + * + * @return a new object of class 'Region'. + * @generated + */ + Region createRegion(); + + /** + * Returns a new object of class 'Transition'. + * + * + * @return a new object of class 'Transition'. + * @generated + */ + Transition createTransition(); + + /** + * Returns a new object of class 'Statechart'. + * + * + * @return a new object of class 'Statechart'. + * @generated + */ + Statechart createStatechart(); + + /** + * Returns a new object of class 'Entry'. + * + * + * @return a new object of class 'Entry'. + * @generated + */ + Entry createEntry(); + + /** + * Returns a new object of class 'Synchronization'. + * + * + * @return a new object of class 'Synchronization'. + * @generated + */ + Synchronization createSynchronization(); + + /** + * Returns a new object of class 'State'. + * + * + * @return a new object of class 'State'. + * @generated + */ + State createState(); + + /** + * Returns a new object of class 'Choice'. + * + * + * @return a new object of class 'Choice'. + * @generated + */ + Choice createChoice(); + + /** + * Returns a new object of class 'Exit'. + * + * + * @return a new object of class 'Exit'. + * @generated + */ + Exit createExit(); + + /** + * Returns a new object of class 'Final State'. + * + * + * @return a new object of class 'Final State'. + * @generated + */ + FinalState createFinalState(); + + /** + * Returns the package supported by this factory. + * + * + * @return the package supported by this factory. + * @generated + */ + YakinduPackage getYakinduPackage(); + +} //YakinduFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduPackage.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduPackage.java new file mode 100644 index 00000000..7fbe176c --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/YakinduPackage.java @@ -0,0 +1,1038 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * + * The Package for the model. + * It contains accessors for the meta objects to represent + *
      + *
    • each class,
    • + *
    • each feature of each class,
    • + *
    • each operation of each class,
    • + *
    • each enum,
    • + *
    • and each data type
    • + *
    + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduFactory + * @model kind="package" + * @generated + */ +public interface YakinduPackage extends EPackage { + /** + * The package name. + * + * + * @generated + */ + String eNAME = "yakindu"; + + /** + * The package namespace URI. + * + * + * @generated + */ + String eNS_URI = "YakinduMetamodel"; + + /** + * The package namespace name. + * + * + * @generated + */ + String eNS_PREFIX = "yakindu"; + + /** + * The singleton instance of the package. + * + * + * @generated + */ + YakinduPackage eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl.init(); + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getVertex() + * @generated + */ + int VERTEX = 1; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int VERTEX__INCOMING_TRANSITIONS = 0; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int VERTEX__OUTGOING_TRANSITIONS = 1; + + /** + * The number of structural features of the 'Vertex' class. + * + * + * @generated + * @ordered + */ + int VERTEX_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Vertex' class. + * + * + * @generated + * @ordered + */ + int VERTEX_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getPseudostate() + * @generated + */ + int PSEUDOSTATE = 0; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Pseudostate' class. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Pseudostate' class. + * + * + * @generated + * @ordered + */ + int PSEUDOSTATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getRegion() + * @generated + */ + int REGION = 2; + + /** + * The feature id for the 'Vertices' containment reference list. + * + * + * @generated + * @ordered + */ + int REGION__VERTICES = 0; + + /** + * The number of structural features of the 'Region' class. + * + * + * @generated + * @ordered + */ + int REGION_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'Region' class. + * + * + * @generated + * @ordered + */ + int REGION_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getTransition() + * @generated + */ + int TRANSITION = 3; + + /** + * The feature id for the 'Target' reference. + * + * + * @generated + * @ordered + */ + int TRANSITION__TARGET = 0; + + /** + * The feature id for the 'Source' container reference. + * + * + * @generated + * @ordered + */ + int TRANSITION__SOURCE = 1; + + /** + * The number of structural features of the 'Transition' class. + * + * + * @generated + * @ordered + */ + int TRANSITION_FEATURE_COUNT = 2; + + /** + * The number of operations of the 'Transition' class. + * + * + * @generated + * @ordered + */ + int TRANSITION_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getCompositeElement() + * @generated + */ + int COMPOSITE_ELEMENT = 9; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT__REGIONS = 0; + + /** + * The number of structural features of the 'Composite Element' class. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT_FEATURE_COUNT = 1; + + /** + * The number of operations of the 'Composite Element' class. + * + * + * @generated + * @ordered + */ + int COMPOSITE_ELEMENT_OPERATION_COUNT = 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getStatechart() + * @generated + */ + int STATECHART = 4; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATECHART__REGIONS = COMPOSITE_ELEMENT__REGIONS; + + /** + * The number of structural features of the 'Statechart' class. + * + * + * @generated + * @ordered + */ + int STATECHART_FEATURE_COUNT = COMPOSITE_ELEMENT_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Statechart' class. + * + * + * @generated + * @ordered + */ + int STATECHART_OPERATION_COUNT = COMPOSITE_ELEMENT_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getEntry() + * @generated + */ + int ENTRY = 5; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int ENTRY__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int ENTRY__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Entry' class. + * + * + * @generated + * @ordered + */ + int ENTRY_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Entry' class. + * + * + * @generated + * @ordered + */ + int ENTRY_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getSynchronization() + * @generated + */ + int SYNCHRONIZATION = 6; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Synchronization' class. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Synchronization' class. + * + * + * @generated + * @ordered + */ + int SYNCHRONIZATION_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getRegularState() + * @generated + */ + int REGULAR_STATE = 8; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Regular State' class. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Regular State' class. + * + * + * @generated + * @ordered + */ + int REGULAR_STATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getState() + * @generated + */ + int STATE = 7; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; + + /** + * The feature id for the 'Regions' containment reference list. + * + * + * @generated + * @ordered + */ + int STATE__REGIONS = REGULAR_STATE_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'State' class. + * + * + * @generated + * @ordered + */ + int STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 1; + + /** + * The number of operations of the 'State' class. + * + * + * @generated + * @ordered + */ + int STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getChoice() + * @generated + */ + int CHOICE = 10; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int CHOICE__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int CHOICE__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Choice' class. + * + * + * @generated + * @ordered + */ + int CHOICE_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Choice' class. + * + * + * @generated + * @ordered + */ + int CHOICE_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getExit() + * @generated + */ + int EXIT = 11; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int EXIT__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int EXIT__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Exit' class. + * + * + * @generated + * @ordered + */ + int EXIT_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Exit' class. + * + * + * @generated + * @ordered + */ + int EXIT_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; + + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getFinalState() + * @generated + */ + int FINAL_STATE = 12; + + /** + * The feature id for the 'Incoming Transitions' reference list. + * + * + * @generated + * @ordered + */ + int FINAL_STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; + + /** + * The feature id for the 'Outgoing Transitions' containment reference list. + * + * + * @generated + * @ordered + */ + int FINAL_STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; + + /** + * The number of structural features of the 'Final State' class. + * + * + * @generated + * @ordered + */ + int FINAL_STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 0; + + /** + * The number of operations of the 'Final State' class. + * + * + * @generated + * @ordered + */ + int FINAL_STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; + + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. + * + * + * @return the meta object for class 'Pseudostate'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate + * @generated + */ + EClass getPseudostate(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. + * + * + * @return the meta object for class 'Vertex'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex + * @generated + */ + EClass getVertex(); + + /** + * Returns the meta object for the reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions Incoming Transitions}'. + * + * + * @return the meta object for the reference list 'Incoming Transitions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions() + * @see #getVertex() + * @generated + */ + EReference getVertex_IncomingTransitions(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}'. + * + * + * @return the meta object for the containment reference list 'Outgoing Transitions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions() + * @see #getVertex() + * @generated + */ + EReference getVertex_OutgoingTransitions(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. + * + * + * @return the meta object for class 'Region'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region + * @generated + */ + EClass getRegion(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices Vertices}'. + * + * + * @return the meta object for the containment reference list 'Vertices'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices() + * @see #getRegion() + * @generated + */ + EReference getRegion_Vertices(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. + * + * + * @return the meta object for class 'Transition'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition + * @generated + */ + EClass getTransition(); + + /** + * Returns the meta object for the reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}'. + * + * + * @return the meta object for the reference 'Target'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget() + * @see #getTransition() + * @generated + */ + EReference getTransition_Target(); + + /** + * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}'. + * + * + * @return the meta object for the container reference 'Source'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource() + * @see #getTransition() + * @generated + */ + EReference getTransition_Source(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. + * + * + * @return the meta object for class 'Statechart'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart + * @generated + */ + EClass getStatechart(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. + * + * + * @return the meta object for class 'Entry'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry + * @generated + */ + EClass getEntry(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. + * + * + * @return the meta object for class 'Synchronization'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization + * @generated + */ + EClass getSynchronization(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. + * + * + * @return the meta object for class 'State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State + * @generated + */ + EClass getState(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. + * + * + * @return the meta object for class 'Regular State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState + * @generated + */ + EClass getRegularState(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. + * + * + * @return the meta object for class 'Composite Element'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement + * @generated + */ + EClass getCompositeElement(); + + /** + * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions Regions}'. + * + * + * @return the meta object for the containment reference list 'Regions'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions() + * @see #getCompositeElement() + * @generated + */ + EReference getCompositeElement_Regions(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. + * + * + * @return the meta object for class 'Choice'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice + * @generated + */ + EClass getChoice(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. + * + * + * @return the meta object for class 'Exit'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit + * @generated + */ + EClass getExit(); + + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. + * + * + * @return the meta object for class 'Final State'. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState + * @generated + */ + EClass getFinalState(); + + /** + * Returns the factory that creates the instances of the model. + * + * + * @return the factory that creates the instances of the model. + * @generated + */ + YakinduFactory getYakinduFactory(); + + /** + * + * Defines literals for the meta objects that represent + *
      + *
    • each class,
    • + *
    • each feature of each class,
    • + *
    • each operation of each class,
    • + *
    • each enum,
    • + *
    • and each data type
    • + *
    + * + * @generated + */ + interface Literals { + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getPseudostate() + * @generated + */ + EClass PSEUDOSTATE = eINSTANCE.getPseudostate(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getVertex() + * @generated + */ + EClass VERTEX = eINSTANCE.getVertex(); + + /** + * The meta object literal for the 'Incoming Transitions' reference list feature. + * + * + * @generated + */ + EReference VERTEX__INCOMING_TRANSITIONS = eINSTANCE.getVertex_IncomingTransitions(); + + /** + * The meta object literal for the 'Outgoing Transitions' containment reference list feature. + * + * + * @generated + */ + EReference VERTEX__OUTGOING_TRANSITIONS = eINSTANCE.getVertex_OutgoingTransitions(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getRegion() + * @generated + */ + EClass REGION = eINSTANCE.getRegion(); + + /** + * The meta object literal for the 'Vertices' containment reference list feature. + * + * + * @generated + */ + EReference REGION__VERTICES = eINSTANCE.getRegion_Vertices(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getTransition() + * @generated + */ + EClass TRANSITION = eINSTANCE.getTransition(); + + /** + * The meta object literal for the 'Target' reference feature. + * + * + * @generated + */ + EReference TRANSITION__TARGET = eINSTANCE.getTransition_Target(); + + /** + * The meta object literal for the 'Source' container reference feature. + * + * + * @generated + */ + EReference TRANSITION__SOURCE = eINSTANCE.getTransition_Source(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getStatechart() + * @generated + */ + EClass STATECHART = eINSTANCE.getStatechart(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getEntry() + * @generated + */ + EClass ENTRY = eINSTANCE.getEntry(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getSynchronization() + * @generated + */ + EClass SYNCHRONIZATION = eINSTANCE.getSynchronization(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getState() + * @generated + */ + EClass STATE = eINSTANCE.getState(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getRegularState() + * @generated + */ + EClass REGULAR_STATE = eINSTANCE.getRegularState(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getCompositeElement() + * @generated + */ + EClass COMPOSITE_ELEMENT = eINSTANCE.getCompositeElement(); + + /** + * The meta object literal for the 'Regions' containment reference list feature. + * + * + * @generated + */ + EReference COMPOSITE_ELEMENT__REGIONS = eINSTANCE.getCompositeElement_Regions(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getChoice() + * @generated + */ + EClass CHOICE = eINSTANCE.getChoice(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getExit() + * @generated + */ + EClass EXIT = eINSTANCE.getExit(); + + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.YakinduPackageImpl#getFinalState() + * @generated + */ + EClass FINAL_STATE = eINSTANCE.getFinalState(); + + } + +} //YakinduPackage diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java index 8fc4883b..b757b42f 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ChoiceImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class ChoiceImpl extends PseudostateImpl implements Choice { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.CHOICE; + return YakinduPackage.Literals.CHOICE; } } //ChoiceImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java index 0218f9c7..8441ed27 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/CompositeElementImpl.java @@ -4,7 +4,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import java.util.Collection; @@ -60,7 +60,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.COMPOSITE_ELEMENT; + return YakinduPackage.Literals.COMPOSITE_ELEMENT; } /** @@ -70,7 +70,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container */ public EList getRegions() { if (regions == null) { - regions = new EObjectContainmentEList(Region.class, this, yakinduPackage.COMPOSITE_ELEMENT__REGIONS); + regions = new EObjectContainmentEList(Region.class, this, YakinduPackage.COMPOSITE_ELEMENT__REGIONS); } return regions; } @@ -83,7 +83,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: return ((InternalEList)getRegions()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); @@ -97,7 +97,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: return getRegions(); } return super.eGet(featureID, resolve, coreType); @@ -112,7 +112,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: getRegions().clear(); getRegions().addAll((Collection)newValue); return; @@ -128,7 +128,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container @Override public void eUnset(int featureID) { switch (featureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: getRegions().clear(); return; } @@ -143,7 +143,7 @@ public abstract class CompositeElementImpl extends MinimalEObjectImpl.Container @Override public boolean eIsSet(int featureID) { switch (featureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: return regions != null && !regions.isEmpty(); } return super.eIsSet(featureID); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java index d0334475..0603c2a4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/EntryImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class EntryImpl extends PseudostateImpl implements Entry { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.ENTRY; + return YakinduPackage.Literals.ENTRY; } } //EntryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java index d1448776..4859ef03 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/ExitImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class ExitImpl extends PseudostateImpl implements Exit { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.EXIT; + return YakinduPackage.Literals.EXIT; } } //ExitImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java index 716c096e..c4d4e157 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/FinalStateImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class FinalStateImpl extends RegularStateImpl implements FinalState { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.FINAL_STATE; + return YakinduPackage.Literals.FINAL_STATE; } } //FinalStateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java index b9fc27f3..56c44b78 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/PseudostateImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public abstract class PseudostateImpl extends VertexImpl implements Pseudostate */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.PSEUDOSTATE; + return YakinduPackage.Literals.PSEUDOSTATE; } } //PseudostateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java index fa873aeb..fa529ad6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegionImpl.java @@ -4,7 +4,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import java.util.Collection; @@ -60,7 +60,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.REGION; + return YakinduPackage.Literals.REGION; } /** @@ -70,7 +70,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { */ public EList getVertices() { if (vertices == null) { - vertices = new EObjectContainmentEList(Vertex.class, this, yakinduPackage.REGION__VERTICES); + vertices = new EObjectContainmentEList(Vertex.class, this, YakinduPackage.REGION__VERTICES); } return vertices; } @@ -83,7 +83,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.REGION__VERTICES: + case YakinduPackage.REGION__VERTICES: return ((InternalEList)getVertices()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); @@ -97,7 +97,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case yakinduPackage.REGION__VERTICES: + case YakinduPackage.REGION__VERTICES: return getVertices(); } return super.eGet(featureID, resolve, coreType); @@ -112,7 +112,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case yakinduPackage.REGION__VERTICES: + case YakinduPackage.REGION__VERTICES: getVertices().clear(); getVertices().addAll((Collection)newValue); return; @@ -128,7 +128,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { @Override public void eUnset(int featureID) { switch (featureID) { - case yakinduPackage.REGION__VERTICES: + case YakinduPackage.REGION__VERTICES: getVertices().clear(); return; } @@ -143,7 +143,7 @@ public class RegionImpl extends MinimalEObjectImpl.Container implements Region { @Override public boolean eIsSet(int featureID) { switch (featureID) { - case yakinduPackage.REGION__VERTICES: + case YakinduPackage.REGION__VERTICES: return vertices != null && !vertices.isEmpty(); } return super.eIsSet(featureID); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java index bbe21a14..5361d4d5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/RegularStateImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public abstract class RegularStateImpl extends VertexImpl implements RegularStat */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.REGULAR_STATE; + return YakinduPackage.Literals.REGULAR_STATE; } } //RegularStateImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java index 66ab2a8f..85938d63 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StateImpl.java @@ -5,7 +5,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import java.util.Collection; @@ -59,7 +59,7 @@ public class StateImpl extends RegularStateImpl implements State { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.STATE; + return YakinduPackage.Literals.STATE; } /** @@ -69,7 +69,7 @@ public class StateImpl extends RegularStateImpl implements State { */ public EList getRegions() { if (regions == null) { - regions = new EObjectContainmentEList(Region.class, this, yakinduPackage.STATE__REGIONS); + regions = new EObjectContainmentEList(Region.class, this, YakinduPackage.STATE__REGIONS); } return regions; } @@ -82,7 +82,7 @@ public class StateImpl extends RegularStateImpl implements State { @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.STATE__REGIONS: + case YakinduPackage.STATE__REGIONS: return ((InternalEList)getRegions()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); @@ -96,7 +96,7 @@ public class StateImpl extends RegularStateImpl implements State { @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case yakinduPackage.STATE__REGIONS: + case YakinduPackage.STATE__REGIONS: return getRegions(); } return super.eGet(featureID, resolve, coreType); @@ -111,7 +111,7 @@ public class StateImpl extends RegularStateImpl implements State { @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case yakinduPackage.STATE__REGIONS: + case YakinduPackage.STATE__REGIONS: getRegions().clear(); getRegions().addAll((Collection)newValue); return; @@ -127,7 +127,7 @@ public class StateImpl extends RegularStateImpl implements State { @Override public void eUnset(int featureID) { switch (featureID) { - case yakinduPackage.STATE__REGIONS: + case YakinduPackage.STATE__REGIONS: getRegions().clear(); return; } @@ -142,7 +142,7 @@ public class StateImpl extends RegularStateImpl implements State { @Override public boolean eIsSet(int featureID) { switch (featureID) { - case yakinduPackage.STATE__REGIONS: + case YakinduPackage.STATE__REGIONS: return regions != null && !regions.isEmpty(); } return super.eIsSet(featureID); @@ -157,7 +157,7 @@ public class StateImpl extends RegularStateImpl implements State { public int eBaseStructuralFeatureID(int derivedFeatureID, Class baseClass) { if (baseClass == CompositeElement.class) { switch (derivedFeatureID) { - case yakinduPackage.STATE__REGIONS: return yakinduPackage.COMPOSITE_ELEMENT__REGIONS; + case YakinduPackage.STATE__REGIONS: return YakinduPackage.COMPOSITE_ELEMENT__REGIONS; default: return -1; } } @@ -173,7 +173,7 @@ public class StateImpl extends RegularStateImpl implements State { public int eDerivedStructuralFeatureID(int baseFeatureID, Class baseClass) { if (baseClass == CompositeElement.class) { switch (baseFeatureID) { - case yakinduPackage.COMPOSITE_ELEMENT__REGIONS: return yakinduPackage.STATE__REGIONS; + case YakinduPackage.COMPOSITE_ELEMENT__REGIONS: return YakinduPackage.STATE__REGIONS; default: return -1; } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java index 056820ca..a74110da 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/StatechartImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class StatechartImpl extends CompositeElementImpl implements Statechart { */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.STATECHART; + return YakinduPackage.Literals.STATECHART; } } //StatechartImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java index 28ef69ea..3b6cd8eb 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/SynchronizationImpl.java @@ -3,7 +3,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.ecore.EClass; @@ -31,7 +31,7 @@ public class SynchronizationImpl extends PseudostateImpl implements Synchronizat */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.SYNCHRONIZATION; + return YakinduPackage.Literals.SYNCHRONIZATION; } } //SynchronizationImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java index ea1677ee..dfbca048 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/TransitionImpl.java @@ -4,7 +4,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.common.notify.NotificationChain; @@ -58,7 +58,7 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.TRANSITION; + return YakinduPackage.Literals.TRANSITION; } /** @@ -72,7 +72,7 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran target = (Vertex)eResolveProxy(oldTarget); if (target != oldTarget) { if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, yakinduPackage.TRANSITION__TARGET, oldTarget, target)); + eNotify(new ENotificationImpl(this, Notification.RESOLVE, YakinduPackage.TRANSITION__TARGET, oldTarget, target)); } } return target; @@ -96,7 +96,7 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran Vertex oldTarget = target; target = newTarget; if (eNotificationRequired()) { - ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__TARGET, oldTarget, newTarget); + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, YakinduPackage.TRANSITION__TARGET, oldTarget, newTarget); if (msgs == null) msgs = notification; else msgs.add(notification); } return msgs; @@ -111,14 +111,14 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran if (newTarget != target) { NotificationChain msgs = null; if (target != null) - msgs = ((InternalEObject)target).eInverseRemove(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + msgs = ((InternalEObject)target).eInverseRemove(this, YakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); if (newTarget != null) - msgs = ((InternalEObject)newTarget).eInverseAdd(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + msgs = ((InternalEObject)newTarget).eInverseAdd(this, YakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); msgs = basicSetTarget(newTarget, msgs); if (msgs != null) msgs.dispatch(); } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__TARGET, newTarget, newTarget)); + eNotify(new ENotificationImpl(this, Notification.SET, YakinduPackage.TRANSITION__TARGET, newTarget, newTarget)); } /** @@ -127,7 +127,7 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran * @generated */ public Vertex getSource() { - if (eContainerFeatureID() != yakinduPackage.TRANSITION__SOURCE) return null; + if (eContainerFeatureID() != YakinduPackage.TRANSITION__SOURCE) return null; return (Vertex)eInternalContainer(); } @@ -137,7 +137,7 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran * @generated */ public NotificationChain basicSetSource(Vertex newSource, NotificationChain msgs) { - msgs = eBasicSetContainer((InternalEObject)newSource, yakinduPackage.TRANSITION__SOURCE, msgs); + msgs = eBasicSetContainer((InternalEObject)newSource, YakinduPackage.TRANSITION__SOURCE, msgs); return msgs; } @@ -147,19 +147,19 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran * @generated */ public void setSource(Vertex newSource) { - if (newSource != eInternalContainer() || (eContainerFeatureID() != yakinduPackage.TRANSITION__SOURCE && newSource != null)) { + if (newSource != eInternalContainer() || (eContainerFeatureID() != YakinduPackage.TRANSITION__SOURCE && newSource != null)) { if (EcoreUtil.isAncestor(this, newSource)) throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); NotificationChain msgs = null; if (eInternalContainer() != null) msgs = eBasicRemoveFromContainer(msgs); if (newSource != null) - msgs = ((InternalEObject)newSource).eInverseAdd(this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); + msgs = ((InternalEObject)newSource).eInverseAdd(this, YakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); msgs = basicSetSource(newSource, msgs); if (msgs != null) msgs.dispatch(); } else if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, yakinduPackage.TRANSITION__SOURCE, newSource, newSource)); + eNotify(new ENotificationImpl(this, Notification.SET, YakinduPackage.TRANSITION__SOURCE, newSource, newSource)); } /** @@ -170,11 +170,11 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: if (target != null) - msgs = ((InternalEObject)target).eInverseRemove(this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); + msgs = ((InternalEObject)target).eInverseRemove(this, YakinduPackage.VERTEX__INCOMING_TRANSITIONS, Vertex.class, msgs); return basicSetTarget((Vertex)otherEnd, msgs); - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: if (eInternalContainer() != null) msgs = eBasicRemoveFromContainer(msgs); return basicSetSource((Vertex)otherEnd, msgs); @@ -190,9 +190,9 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: return basicSetTarget(null, msgs); - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: return basicSetSource(null, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); @@ -206,8 +206,8 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { switch (eContainerFeatureID()) { - case yakinduPackage.TRANSITION__SOURCE: - return eInternalContainer().eInverseRemove(this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); + case YakinduPackage.TRANSITION__SOURCE: + return eInternalContainer().eInverseRemove(this, YakinduPackage.VERTEX__OUTGOING_TRANSITIONS, Vertex.class, msgs); } return super.eBasicRemoveFromContainerFeature(msgs); } @@ -220,10 +220,10 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: if (resolve) return getTarget(); return basicGetTarget(); - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: return getSource(); } return super.eGet(featureID, resolve, coreType); @@ -237,10 +237,10 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: setTarget((Vertex)newValue); return; - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: setSource((Vertex)newValue); return; } @@ -255,10 +255,10 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public void eUnset(int featureID) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: setTarget((Vertex)null); return; - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: setSource((Vertex)null); return; } @@ -273,9 +273,9 @@ public class TransitionImpl extends MinimalEObjectImpl.Container implements Tran @Override public boolean eIsSet(int featureID) { switch (featureID) { - case yakinduPackage.TRANSITION__TARGET: + case YakinduPackage.TRANSITION__TARGET: return target != null; - case yakinduPackage.TRANSITION__SOURCE: + case YakinduPackage.TRANSITION__SOURCE: return getSource() != null; } return super.eIsSet(featureID); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java index 6f5b9ed3..6384fb51 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/VertexImpl.java @@ -4,7 +4,7 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; import java.util.Collection; @@ -72,7 +72,7 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements */ @Override protected EClass eStaticClass() { - return yakinduPackage.Literals.VERTEX; + return YakinduPackage.Literals.VERTEX; } /** @@ -82,7 +82,7 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements */ public EList getIncomingTransitions() { if (incomingTransitions == null) { - incomingTransitions = new EObjectWithInverseResolvingEList(Transition.class, this, yakinduPackage.VERTEX__INCOMING_TRANSITIONS, yakinduPackage.TRANSITION__TARGET); + incomingTransitions = new EObjectWithInverseResolvingEList(Transition.class, this, YakinduPackage.VERTEX__INCOMING_TRANSITIONS, YakinduPackage.TRANSITION__TARGET); } return incomingTransitions; } @@ -94,7 +94,7 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements */ public EList getOutgoingTransitions() { if (outgoingTransitions == null) { - outgoingTransitions = new EObjectContainmentWithInverseEList(Transition.class, this, yakinduPackage.VERTEX__OUTGOING_TRANSITIONS, yakinduPackage.TRANSITION__SOURCE); + outgoingTransitions = new EObjectContainmentWithInverseEList(Transition.class, this, YakinduPackage.VERTEX__OUTGOING_TRANSITIONS, YakinduPackage.TRANSITION__SOURCE); } return outgoingTransitions; } @@ -108,9 +108,9 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: return ((InternalEList)(InternalEList)getIncomingTransitions()).basicAdd(otherEnd, msgs); - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: return ((InternalEList)(InternalEList)getOutgoingTransitions()).basicAdd(otherEnd, msgs); } return super.eInverseAdd(otherEnd, featureID, msgs); @@ -124,9 +124,9 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: return ((InternalEList)getIncomingTransitions()).basicRemove(otherEnd, msgs); - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: return ((InternalEList)getOutgoingTransitions()).basicRemove(otherEnd, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); @@ -140,9 +140,9 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: return getIncomingTransitions(); - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: return getOutgoingTransitions(); } return super.eGet(featureID, resolve, coreType); @@ -157,11 +157,11 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public void eSet(int featureID, Object newValue) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: getIncomingTransitions().clear(); getIncomingTransitions().addAll((Collection)newValue); return; - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: getOutgoingTransitions().clear(); getOutgoingTransitions().addAll((Collection)newValue); return; @@ -177,10 +177,10 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public void eUnset(int featureID) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: getIncomingTransitions().clear(); return; - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: getOutgoingTransitions().clear(); return; } @@ -195,9 +195,9 @@ public abstract class VertexImpl extends MinimalEObjectImpl.Container implements @Override public boolean eIsSet(int featureID) { switch (featureID) { - case yakinduPackage.VERTEX__INCOMING_TRANSITIONS: + case YakinduPackage.VERTEX__INCOMING_TRANSITIONS: return incomingTransitions != null && !incomingTransitions.isEmpty(); - case yakinduPackage.VERTEX__OUTGOING_TRANSITIONS: + case YakinduPackage.VERTEX__OUTGOING_TRANSITIONS: return outgoingTransitions != null && !outgoingTransitions.isEmpty(); } return super.eIsSet(featureID); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduFactoryImpl.java new file mode 100644 index 00000000..bd5ee1bd --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduFactoryImpl.java @@ -0,0 +1,183 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.impl.EFactoryImpl; + +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +/** + * + * An implementation of the model Factory. + * + * @generated + */ +public class YakinduFactoryImpl extends EFactoryImpl implements YakinduFactory { + /** + * Creates the default factory implementation. + * + * + * @generated + */ + public static YakinduFactory init() { + try { + YakinduFactory theYakinduFactory = (YakinduFactory)EPackage.Registry.INSTANCE.getEFactory(YakinduPackage.eNS_URI); + if (theYakinduFactory != null) { + return theYakinduFactory; + } + } + catch (Exception exception) { + EcorePlugin.INSTANCE.log(exception); + } + return new YakinduFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * + * + * @generated + */ + public YakinduFactoryImpl() { + super(); + } + + /** + * + * + * @generated + */ + @Override + public EObject create(EClass eClass) { + switch (eClass.getClassifierID()) { + case YakinduPackage.REGION: return createRegion(); + case YakinduPackage.TRANSITION: return createTransition(); + case YakinduPackage.STATECHART: return createStatechart(); + case YakinduPackage.ENTRY: return createEntry(); + case YakinduPackage.SYNCHRONIZATION: return createSynchronization(); + case YakinduPackage.STATE: return createState(); + case YakinduPackage.CHOICE: return createChoice(); + case YakinduPackage.EXIT: return createExit(); + case YakinduPackage.FINAL_STATE: return createFinalState(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + public Region createRegion() { + RegionImpl region = new RegionImpl(); + return region; + } + + /** + * + * + * @generated + */ + public Transition createTransition() { + TransitionImpl transition = new TransitionImpl(); + return transition; + } + + /** + * + * + * @generated + */ + public Statechart createStatechart() { + StatechartImpl statechart = new StatechartImpl(); + return statechart; + } + + /** + * + * + * @generated + */ + public Entry createEntry() { + EntryImpl entry = new EntryImpl(); + return entry; + } + + /** + * + * + * @generated + */ + public Synchronization createSynchronization() { + SynchronizationImpl synchronization = new SynchronizationImpl(); + return synchronization; + } + + /** + * + * + * @generated + */ + public State createState() { + StateImpl state = new StateImpl(); + return state; + } + + /** + * + * + * @generated + */ + public Choice createChoice() { + ChoiceImpl choice = new ChoiceImpl(); + return choice; + } + + /** + * + * + * @generated + */ + public Exit createExit() { + ExitImpl exit = new ExitImpl(); + return exit; + } + + /** + * + * + * @generated + */ + public FinalState createFinalState() { + FinalStateImpl finalState = new FinalStateImpl(); + return finalState; + } + + /** + * + * + * @generated + */ + public YakinduPackage getYakinduPackage() { + return (YakinduPackage)getEPackage(); + } + + /** + * + * + * @deprecated + * @generated + */ + @Deprecated + public static YakinduPackage getPackage() { + return YakinduPackage.eINSTANCE; + } + +} //YakinduFactoryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduPackageImpl.java new file mode 100644 index 00000000..0796c5d8 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/YakinduPackageImpl.java @@ -0,0 +1,494 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduFactory; +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +import org.eclipse.emf.ecore.impl.EPackageImpl; + +/** + * + * An implementation of the model Package. + * + * @generated + */ +public class YakinduPackageImpl extends EPackageImpl implements YakinduPackage { + /** + * + * + * @generated + */ + private EClass pseudostateEClass = null; + + /** + * + * + * @generated + */ + private EClass vertexEClass = null; + + /** + * + * + * @generated + */ + private EClass regionEClass = null; + + /** + * + * + * @generated + */ + private EClass transitionEClass = null; + + /** + * + * + * @generated + */ + private EClass statechartEClass = null; + + /** + * + * + * @generated + */ + private EClass entryEClass = null; + + /** + * + * + * @generated + */ + private EClass synchronizationEClass = null; + + /** + * + * + * @generated + */ + private EClass stateEClass = null; + + /** + * + * + * @generated + */ + private EClass regularStateEClass = null; + + /** + * + * + * @generated + */ + private EClass compositeElementEClass = null; + + /** + * + * + * @generated + */ + private EClass choiceEClass = null; + + /** + * + * + * @generated + */ + private EClass exitEClass = null; + + /** + * + * + * @generated + */ + private EClass finalStateEClass = null; + + /** + * Creates an instance of the model Package, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + *

    Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * + * + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage#eNS_URI + * @see #init() + * @generated + */ + private YakinduPackageImpl() { + super(eNS_URI, YakinduFactory.eINSTANCE); + } + + /** + * + * + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. + * + *

    This method is used to initialize {@link YakinduPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * + * + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static YakinduPackage init() { + if (isInited) return (YakinduPackage)EPackage.Registry.INSTANCE.getEPackage(YakinduPackage.eNS_URI); + + // Obtain or create and register package + Object registeredYakinduPackage = EPackage.Registry.INSTANCE.get(eNS_URI); + YakinduPackageImpl theYakinduPackage = registeredYakinduPackage instanceof YakinduPackageImpl ? (YakinduPackageImpl)registeredYakinduPackage : new YakinduPackageImpl(); + + isInited = true; + + // Create package meta-data objects + theYakinduPackage.createPackageContents(); + + // Initialize created meta-data + theYakinduPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theYakinduPackage.freeze(); + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(YakinduPackage.eNS_URI, theYakinduPackage); + return theYakinduPackage; + } + + /** + * + * + * @generated + */ + public EClass getPseudostate() { + return pseudostateEClass; + } + + /** + * + * + * @generated + */ + public EClass getVertex() { + return vertexEClass; + } + + /** + * + * + * @generated + */ + public EReference getVertex_IncomingTransitions() { + return (EReference)vertexEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getVertex_OutgoingTransitions() { + return (EReference)vertexEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getRegion() { + return regionEClass; + } + + /** + * + * + * @generated + */ + public EReference getRegion_Vertices() { + return (EReference)regionEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getTransition() { + return transitionEClass; + } + + /** + * + * + * @generated + */ + public EReference getTransition_Target() { + return (EReference)transitionEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EReference getTransition_Source() { + return (EReference)transitionEClass.getEStructuralFeatures().get(1); + } + + /** + * + * + * @generated + */ + public EClass getStatechart() { + return statechartEClass; + } + + /** + * + * + * @generated + */ + public EClass getEntry() { + return entryEClass; + } + + /** + * + * + * @generated + */ + public EClass getSynchronization() { + return synchronizationEClass; + } + + /** + * + * + * @generated + */ + public EClass getState() { + return stateEClass; + } + + /** + * + * + * @generated + */ + public EClass getRegularState() { + return regularStateEClass; + } + + /** + * + * + * @generated + */ + public EClass getCompositeElement() { + return compositeElementEClass; + } + + /** + * + * + * @generated + */ + public EReference getCompositeElement_Regions() { + return (EReference)compositeElementEClass.getEStructuralFeatures().get(0); + } + + /** + * + * + * @generated + */ + public EClass getChoice() { + return choiceEClass; + } + + /** + * + * + * @generated + */ + public EClass getExit() { + return exitEClass; + } + + /** + * + * + * @generated + */ + public EClass getFinalState() { + return finalStateEClass; + } + + /** + * + * + * @generated + */ + public YakinduFactory getYakinduFactory() { + return (YakinduFactory)getEFactoryInstance(); + } + + /** + * + * + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void createPackageContents() { + if (isCreated) return; + isCreated = true; + + // Create classes and their features + pseudostateEClass = createEClass(PSEUDOSTATE); + + vertexEClass = createEClass(VERTEX); + createEReference(vertexEClass, VERTEX__INCOMING_TRANSITIONS); + createEReference(vertexEClass, VERTEX__OUTGOING_TRANSITIONS); + + regionEClass = createEClass(REGION); + createEReference(regionEClass, REGION__VERTICES); + + transitionEClass = createEClass(TRANSITION); + createEReference(transitionEClass, TRANSITION__TARGET); + createEReference(transitionEClass, TRANSITION__SOURCE); + + statechartEClass = createEClass(STATECHART); + + entryEClass = createEClass(ENTRY); + + synchronizationEClass = createEClass(SYNCHRONIZATION); + + stateEClass = createEClass(STATE); + + regularStateEClass = createEClass(REGULAR_STATE); + + compositeElementEClass = createEClass(COMPOSITE_ELEMENT); + createEReference(compositeElementEClass, COMPOSITE_ELEMENT__REGIONS); + + choiceEClass = createEClass(CHOICE); + + exitEClass = createEClass(EXIT); + + finalStateEClass = createEClass(FINAL_STATE); + } + + /** + * + * + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * + * + * @generated + */ + public void initializePackageContents() { + if (isInitialized) return; + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + pseudostateEClass.getESuperTypes().add(this.getVertex()); + statechartEClass.getESuperTypes().add(this.getCompositeElement()); + entryEClass.getESuperTypes().add(this.getPseudostate()); + synchronizationEClass.getESuperTypes().add(this.getPseudostate()); + stateEClass.getESuperTypes().add(this.getRegularState()); + stateEClass.getESuperTypes().add(this.getCompositeElement()); + regularStateEClass.getESuperTypes().add(this.getVertex()); + choiceEClass.getESuperTypes().add(this.getPseudostate()); + exitEClass.getESuperTypes().add(this.getPseudostate()); + finalStateEClass.getESuperTypes().add(this.getRegularState()); + + // Initialize classes, features, and operations; add parameters + initEClass(pseudostateEClass, Pseudostate.class, "Pseudostate", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(vertexEClass, Vertex.class, "Vertex", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getVertex_IncomingTransitions(), this.getTransition(), this.getTransition_Target(), "incomingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getVertex_OutgoingTransitions(), this.getTransition(), this.getTransition_Source(), "outgoingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(regionEClass, Region.class, "Region", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getRegion_Vertices(), this.getVertex(), null, "vertices", null, 0, -1, Region.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(transitionEClass, Transition.class, "Transition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getTransition_Target(), this.getVertex(), this.getVertex_IncomingTransitions(), "target", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + initEReference(getTransition_Source(), this.getVertex(), this.getVertex_OutgoingTransitions(), "source", null, 0, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); + + initEClass(statechartEClass, Statechart.class, "Statechart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(entryEClass, Entry.class, "Entry", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(synchronizationEClass, Synchronization.class, "Synchronization", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(stateEClass, State.class, "State", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(regularStateEClass, RegularState.class, "RegularState", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(compositeElementEClass, CompositeElement.class, "CompositeElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getCompositeElement_Regions(), this.getRegion(), null, "regions", null, 0, -1, CompositeElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + + initEClass(choiceEClass, Choice.class, "Choice", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(exitEClass, Exit.class, "Exit", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + initEClass(finalStateEClass, FinalState.class, "FinalState", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + + // Create resource + createResource(eNS_URI); + } + +} //YakinduPackageImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java deleted file mode 100644 index 5d004565..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduFactoryImpl.java +++ /dev/null @@ -1,183 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.impl.EFactoryImpl; - -import org.eclipse.emf.ecore.plugin.EcorePlugin; - -/** - * - * An implementation of the model Factory. - * - * @generated - */ -public class yakinduFactoryImpl extends EFactoryImpl implements yakinduFactory { - /** - * Creates the default factory implementation. - * - * - * @generated - */ - public static yakinduFactory init() { - try { - yakinduFactory theyakinduFactory = (yakinduFactory)EPackage.Registry.INSTANCE.getEFactory(yakinduPackage.eNS_URI); - if (theyakinduFactory != null) { - return theyakinduFactory; - } - } - catch (Exception exception) { - EcorePlugin.INSTANCE.log(exception); - } - return new yakinduFactoryImpl(); - } - - /** - * Creates an instance of the factory. - * - * - * @generated - */ - public yakinduFactoryImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - public EObject create(EClass eClass) { - switch (eClass.getClassifierID()) { - case yakinduPackage.REGION: return createRegion(); - case yakinduPackage.TRANSITION: return createTransition(); - case yakinduPackage.STATECHART: return createStatechart(); - case yakinduPackage.ENTRY: return createEntry(); - case yakinduPackage.SYNCHRONIZATION: return createSynchronization(); - case yakinduPackage.STATE: return createState(); - case yakinduPackage.CHOICE: return createChoice(); - case yakinduPackage.EXIT: return createExit(); - case yakinduPackage.FINAL_STATE: return createFinalState(); - default: - throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); - } - } - - /** - * - * - * @generated - */ - public Region createRegion() { - RegionImpl region = new RegionImpl(); - return region; - } - - /** - * - * - * @generated - */ - public Transition createTransition() { - TransitionImpl transition = new TransitionImpl(); - return transition; - } - - /** - * - * - * @generated - */ - public Statechart createStatechart() { - StatechartImpl statechart = new StatechartImpl(); - return statechart; - } - - /** - * - * - * @generated - */ - public Entry createEntry() { - EntryImpl entry = new EntryImpl(); - return entry; - } - - /** - * - * - * @generated - */ - public Synchronization createSynchronization() { - SynchronizationImpl synchronization = new SynchronizationImpl(); - return synchronization; - } - - /** - * - * - * @generated - */ - public State createState() { - StateImpl state = new StateImpl(); - return state; - } - - /** - * - * - * @generated - */ - public Choice createChoice() { - ChoiceImpl choice = new ChoiceImpl(); - return choice; - } - - /** - * - * - * @generated - */ - public Exit createExit() { - ExitImpl exit = new ExitImpl(); - return exit; - } - - /** - * - * - * @generated - */ - public FinalState createFinalState() { - FinalStateImpl finalState = new FinalStateImpl(); - return finalState; - } - - /** - * - * - * @generated - */ - public yakinduPackage getyakinduPackage() { - return (yakinduPackage)getEPackage(); - } - - /** - * - * - * @deprecated - * @generated - */ - @Deprecated - public static yakinduPackage getPackage() { - return yakinduPackage.eINSTANCE; - } - -} //yakinduFactoryImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java deleted file mode 100644 index 2213e07f..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/impl/yakinduPackageImpl.java +++ /dev/null @@ -1,494 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduFactory; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -import org.eclipse.emf.ecore.impl.EPackageImpl; - -/** - * - * An implementation of the model Package. - * - * @generated - */ -public class yakinduPackageImpl extends EPackageImpl implements yakinduPackage { - /** - * - * - * @generated - */ - private EClass pseudostateEClass = null; - - /** - * - * - * @generated - */ - private EClass vertexEClass = null; - - /** - * - * - * @generated - */ - private EClass regionEClass = null; - - /** - * - * - * @generated - */ - private EClass transitionEClass = null; - - /** - * - * - * @generated - */ - private EClass statechartEClass = null; - - /** - * - * - * @generated - */ - private EClass entryEClass = null; - - /** - * - * - * @generated - */ - private EClass synchronizationEClass = null; - - /** - * - * - * @generated - */ - private EClass stateEClass = null; - - /** - * - * - * @generated - */ - private EClass regularStateEClass = null; - - /** - * - * - * @generated - */ - private EClass compositeElementEClass = null; - - /** - * - * - * @generated - */ - private EClass choiceEClass = null; - - /** - * - * - * @generated - */ - private EClass exitEClass = null; - - /** - * - * - * @generated - */ - private EClass finalStateEClass = null; - - /** - * Creates an instance of the model Package, registered with - * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package - * package URI value. - *

    Note: the correct way to create the package is via the static - * factory method {@link #init init()}, which also performs - * initialization of the package, or returns the registered package, - * if one already exists. - * - * - * @see org.eclipse.emf.ecore.EPackage.Registry - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage#eNS_URI - * @see #init() - * @generated - */ - private yakinduPackageImpl() { - super(eNS_URI, yakinduFactory.eINSTANCE); - } - - /** - * - * - * @generated - */ - private static boolean isInited = false; - - /** - * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * - *

    This method is used to initialize {@link yakinduPackage#eINSTANCE} when that field is accessed. - * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. - * - * - * @see #eNS_URI - * @see #createPackageContents() - * @see #initializePackageContents() - * @generated - */ - public static yakinduPackage init() { - if (isInited) return (yakinduPackage)EPackage.Registry.INSTANCE.getEPackage(yakinduPackage.eNS_URI); - - // Obtain or create and register package - yakinduPackageImpl theyakinduPackage = (yakinduPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof yakinduPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new yakinduPackageImpl()); - - isInited = true; - - // Create package meta-data objects - theyakinduPackage.createPackageContents(); - - // Initialize created meta-data - theyakinduPackage.initializePackageContents(); - - // Mark meta-data to indicate it can't be changed - theyakinduPackage.freeze(); - - - // Update the registry and return the package - EPackage.Registry.INSTANCE.put(yakinduPackage.eNS_URI, theyakinduPackage); - return theyakinduPackage; - } - - /** - * - * - * @generated - */ - public EClass getPseudostate() { - return pseudostateEClass; - } - - /** - * - * - * @generated - */ - public EClass getVertex() { - return vertexEClass; - } - - /** - * - * - * @generated - */ - public EReference getVertex_IncomingTransitions() { - return (EReference)vertexEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getVertex_OutgoingTransitions() { - return (EReference)vertexEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getRegion() { - return regionEClass; - } - - /** - * - * - * @generated - */ - public EReference getRegion_Vertices() { - return (EReference)regionEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getTransition() { - return transitionEClass; - } - - /** - * - * - * @generated - */ - public EReference getTransition_Target() { - return (EReference)transitionEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EReference getTransition_Source() { - return (EReference)transitionEClass.getEStructuralFeatures().get(1); - } - - /** - * - * - * @generated - */ - public EClass getStatechart() { - return statechartEClass; - } - - /** - * - * - * @generated - */ - public EClass getEntry() { - return entryEClass; - } - - /** - * - * - * @generated - */ - public EClass getSynchronization() { - return synchronizationEClass; - } - - /** - * - * - * @generated - */ - public EClass getState() { - return stateEClass; - } - - /** - * - * - * @generated - */ - public EClass getRegularState() { - return regularStateEClass; - } - - /** - * - * - * @generated - */ - public EClass getCompositeElement() { - return compositeElementEClass; - } - - /** - * - * - * @generated - */ - public EReference getCompositeElement_Regions() { - return (EReference)compositeElementEClass.getEStructuralFeatures().get(0); - } - - /** - * - * - * @generated - */ - public EClass getChoice() { - return choiceEClass; - } - - /** - * - * - * @generated - */ - public EClass getExit() { - return exitEClass; - } - - /** - * - * - * @generated - */ - public EClass getFinalState() { - return finalStateEClass; - } - - /** - * - * - * @generated - */ - public yakinduFactory getyakinduFactory() { - return (yakinduFactory)getEFactoryInstance(); - } - - /** - * - * - * @generated - */ - private boolean isCreated = false; - - /** - * Creates the meta-model objects for the package. This method is - * guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void createPackageContents() { - if (isCreated) return; - isCreated = true; - - // Create classes and their features - pseudostateEClass = createEClass(PSEUDOSTATE); - - vertexEClass = createEClass(VERTEX); - createEReference(vertexEClass, VERTEX__INCOMING_TRANSITIONS); - createEReference(vertexEClass, VERTEX__OUTGOING_TRANSITIONS); - - regionEClass = createEClass(REGION); - createEReference(regionEClass, REGION__VERTICES); - - transitionEClass = createEClass(TRANSITION); - createEReference(transitionEClass, TRANSITION__TARGET); - createEReference(transitionEClass, TRANSITION__SOURCE); - - statechartEClass = createEClass(STATECHART); - - entryEClass = createEClass(ENTRY); - - synchronizationEClass = createEClass(SYNCHRONIZATION); - - stateEClass = createEClass(STATE); - - regularStateEClass = createEClass(REGULAR_STATE); - - compositeElementEClass = createEClass(COMPOSITE_ELEMENT); - createEReference(compositeElementEClass, COMPOSITE_ELEMENT__REGIONS); - - choiceEClass = createEClass(CHOICE); - - exitEClass = createEClass(EXIT); - - finalStateEClass = createEClass(FINAL_STATE); - } - - /** - * - * - * @generated - */ - private boolean isInitialized = false; - - /** - * Complete the initialization of the package and its meta-model. This - * method is guarded to have no affect on any invocation but its first. - * - * - * @generated - */ - public void initializePackageContents() { - if (isInitialized) return; - isInitialized = true; - - // Initialize package - setName(eNAME); - setNsPrefix(eNS_PREFIX); - setNsURI(eNS_URI); - - // Create type parameters - - // Set bounds for type parameters - - // Add supertypes to classes - pseudostateEClass.getESuperTypes().add(this.getVertex()); - statechartEClass.getESuperTypes().add(this.getCompositeElement()); - entryEClass.getESuperTypes().add(this.getPseudostate()); - synchronizationEClass.getESuperTypes().add(this.getPseudostate()); - stateEClass.getESuperTypes().add(this.getRegularState()); - stateEClass.getESuperTypes().add(this.getCompositeElement()); - regularStateEClass.getESuperTypes().add(this.getVertex()); - choiceEClass.getESuperTypes().add(this.getPseudostate()); - exitEClass.getESuperTypes().add(this.getPseudostate()); - finalStateEClass.getESuperTypes().add(this.getRegularState()); - - // Initialize classes, features, and operations; add parameters - initEClass(pseudostateEClass, Pseudostate.class, "Pseudostate", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(vertexEClass, Vertex.class, "Vertex", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getVertex_IncomingTransitions(), this.getTransition(), this.getTransition_Target(), "incomingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEReference(getVertex_OutgoingTransitions(), this.getTransition(), this.getTransition_Source(), "outgoingTransitions", null, 0, -1, Vertex.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - initEClass(regionEClass, Region.class, "Region", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getRegion_Vertices(), this.getVertex(), null, "vertices", null, 0, -1, Region.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - initEClass(transitionEClass, Transition.class, "Transition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getTransition_Target(), this.getVertex(), this.getVertex_IncomingTransitions(), "target", null, 1, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - initEReference(getTransition_Source(), this.getVertex(), this.getVertex_OutgoingTransitions(), "source", null, 0, 1, Transition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, !IS_ORDERED); - - initEClass(statechartEClass, Statechart.class, "Statechart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(entryEClass, Entry.class, "Entry", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(synchronizationEClass, Synchronization.class, "Synchronization", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(stateEClass, State.class, "State", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(regularStateEClass, RegularState.class, "RegularState", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(compositeElementEClass, CompositeElement.class, "CompositeElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getCompositeElement_Regions(), this.getRegion(), null, "regions", null, 0, -1, CompositeElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - - initEClass(choiceEClass, Choice.class, "Choice", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(exitEClass, Exit.class, "Exit", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - initEClass(finalStateEClass, FinalState.class, "FinalState", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - - // Create resource - createResource(eNS_URI); - } - -} //yakinduPackageImpl diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduAdapterFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduAdapterFactory.java new file mode 100644 index 00000000..566f01e5 --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduAdapterFactory.java @@ -0,0 +1,336 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; + +import org.eclipse.emf.ecore.EObject; + +/** + * + * The Adapter Factory for the model. + * It provides an adapter createXXX method for each class of the model. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage + * @generated + */ +public class YakinduAdapterFactory extends AdapterFactoryImpl { + /** + * The cached model package. + * + * + * @generated + */ + protected static YakinduPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * + * + * @generated + */ + public YakinduAdapterFactory() { + if (modelPackage == null) { + modelPackage = YakinduPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * + * This implementation returns true if the object is either the model's package or is an instance object of the model. + * + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) { + if (object == modelPackage) { + return true; + } + if (object instanceof EObject) { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the createXXX methods. + * + * + * @generated + */ + protected YakinduSwitch modelSwitch = + new YakinduSwitch() { + @Override + public Adapter casePseudostate(Pseudostate object) { + return createPseudostateAdapter(); + } + @Override + public Adapter caseVertex(Vertex object) { + return createVertexAdapter(); + } + @Override + public Adapter caseRegion(Region object) { + return createRegionAdapter(); + } + @Override + public Adapter caseTransition(Transition object) { + return createTransitionAdapter(); + } + @Override + public Adapter caseStatechart(Statechart object) { + return createStatechartAdapter(); + } + @Override + public Adapter caseEntry(Entry object) { + return createEntryAdapter(); + } + @Override + public Adapter caseSynchronization(Synchronization object) { + return createSynchronizationAdapter(); + } + @Override + public Adapter caseState(State object) { + return createStateAdapter(); + } + @Override + public Adapter caseRegularState(RegularState object) { + return createRegularStateAdapter(); + } + @Override + public Adapter caseCompositeElement(CompositeElement object) { + return createCompositeElementAdapter(); + } + @Override + public Adapter caseChoice(Choice object) { + return createChoiceAdapter(); + } + @Override + public Adapter caseExit(Exit object) { + return createExitAdapter(); + } + @Override + public Adapter caseFinalState(FinalState object) { + return createFinalStateAdapter(); + } + @Override + public Adapter defaultCase(EObject object) { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the target. + * + * + * @param target the object to adapt. + * @return the adapter for the target. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) { + return modelSwitch.doSwitch((EObject)target); + } + + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate + * @generated + */ + public Adapter createPseudostateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex + * @generated + */ + public Adapter createVertexAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region + * @generated + */ + public Adapter createRegionAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition + * @generated + */ + public Adapter createTransitionAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart + * @generated + */ + public Adapter createStatechartAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry + * @generated + */ + public Adapter createEntryAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization + * @generated + */ + public Adapter createSynchronizationAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State + * @generated + */ + public Adapter createStateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState + * @generated + */ + public Adapter createRegularStateAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement + * @generated + */ + public Adapter createCompositeElementAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice + * @generated + */ + public Adapter createChoiceAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit + * @generated + */ + public Adapter createExitAdapter() { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. + * + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * + * @return the new adapter. + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState + * @generated + */ + public Adapter createFinalStateAdapter() { + return null; + } + + /** + * Creates a new adapter for the default case. + * + * This default implementation returns null. + * + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() { + return null; + } + +} //YakinduAdapterFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduSwitch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduSwitch.java new file mode 100644 index 00000000..fdaff54d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/YakinduSwitch.java @@ -0,0 +1,378 @@ +/** + */ +package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; + +import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; + +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; + +import org.eclipse.emf.ecore.util.Switch; + +/** + * + * The Switch for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the caseXXX method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * + * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.YakinduPackage + * @generated + */ +public class YakinduSwitch extends Switch { + /** + * The cached model package + * + * + * @generated + */ + protected static YakinduPackage modelPackage; + + /** + * Creates an instance of the switch. + * + * + * @generated + */ + public YakinduSwitch() { + if (modelPackage == null) { + modelPackage = YakinduPackage.eINSTANCE; + } + } + + /** + * Checks whether this is a switch for the given package. + * + * + * @param ePackage the package in question. + * @return whether this is a switch for the given package. + * @generated + */ + @Override + protected boolean isSwitchFor(EPackage ePackage) { + return ePackage == modelPackage; + } + + /** + * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. + * + * + * @return the first non-null result returned by a caseXXX call. + * @generated + */ + @Override + protected T doSwitch(int classifierID, EObject theEObject) { + switch (classifierID) { + case YakinduPackage.PSEUDOSTATE: { + Pseudostate pseudostate = (Pseudostate)theEObject; + T result = casePseudostate(pseudostate); + if (result == null) result = caseVertex(pseudostate); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.VERTEX: { + Vertex vertex = (Vertex)theEObject; + T result = caseVertex(vertex); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.REGION: { + Region region = (Region)theEObject; + T result = caseRegion(region); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.TRANSITION: { + Transition transition = (Transition)theEObject; + T result = caseTransition(transition); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.STATECHART: { + Statechart statechart = (Statechart)theEObject; + T result = caseStatechart(statechart); + if (result == null) result = caseCompositeElement(statechart); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.ENTRY: { + Entry entry = (Entry)theEObject; + T result = caseEntry(entry); + if (result == null) result = casePseudostate(entry); + if (result == null) result = caseVertex(entry); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.SYNCHRONIZATION: { + Synchronization synchronization = (Synchronization)theEObject; + T result = caseSynchronization(synchronization); + if (result == null) result = casePseudostate(synchronization); + if (result == null) result = caseVertex(synchronization); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.STATE: { + State state = (State)theEObject; + T result = caseState(state); + if (result == null) result = caseRegularState(state); + if (result == null) result = caseCompositeElement(state); + if (result == null) result = caseVertex(state); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.REGULAR_STATE: { + RegularState regularState = (RegularState)theEObject; + T result = caseRegularState(regularState); + if (result == null) result = caseVertex(regularState); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.COMPOSITE_ELEMENT: { + CompositeElement compositeElement = (CompositeElement)theEObject; + T result = caseCompositeElement(compositeElement); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.CHOICE: { + Choice choice = (Choice)theEObject; + T result = caseChoice(choice); + if (result == null) result = casePseudostate(choice); + if (result == null) result = caseVertex(choice); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.EXIT: { + Exit exit = (Exit)theEObject; + T result = caseExit(exit); + if (result == null) result = casePseudostate(exit); + if (result == null) result = caseVertex(exit); + if (result == null) result = defaultCase(theEObject); + return result; + } + case YakinduPackage.FINAL_STATE: { + FinalState finalState = (FinalState)theEObject; + T result = caseFinalState(finalState); + if (result == null) result = caseRegularState(finalState); + if (result == null) result = caseVertex(finalState); + if (result == null) result = defaultCase(theEObject); + return result; + } + default: return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of 'Pseudostate'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Pseudostate'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T casePseudostate(Pseudostate object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Vertex'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Vertex'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseVertex(Vertex object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Region'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Region'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRegion(Region object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Transition'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Transition'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseTransition(Transition object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Statechart'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Statechart'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseStatechart(Statechart object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Entry'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Entry'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseEntry(Entry object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Synchronization'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Synchronization'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseSynchronization(Synchronization object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseState(State object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Regular State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Regular State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRegularState(RegularState object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Composite Element'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Composite Element'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseCompositeElement(CompositeElement object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Choice'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Choice'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseChoice(Choice object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Exit'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Exit'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseExit(Exit object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'Final State'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'Final State'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseFinalState(FinalState object) { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of 'EObject'. + * + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of 'EObject'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + @Override + public T defaultCase(EObject object) { + return null; + } + +} //YakinduSwitch diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java deleted file mode 100644 index b8fafb35..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduAdapterFactory.java +++ /dev/null @@ -1,336 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; - -import org.eclipse.emf.common.notify.Adapter; -import org.eclipse.emf.common.notify.Notifier; - -import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; - -import org.eclipse.emf.ecore.EObject; - -/** - * - * The Adapter Factory for the model. - * It provides an adapter createXXX method for each class of the model. - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage - * @generated - */ -public class yakinduAdapterFactory extends AdapterFactoryImpl { - /** - * The cached model package. - * - * - * @generated - */ - protected static yakinduPackage modelPackage; - - /** - * Creates an instance of the adapter factory. - * - * - * @generated - */ - public yakinduAdapterFactory() { - if (modelPackage == null) { - modelPackage = yakinduPackage.eINSTANCE; - } - } - - /** - * Returns whether this factory is applicable for the type of the object. - * - * This implementation returns true if the object is either the model's package or is an instance object of the model. - * - * @return whether this factory is applicable for the type of the object. - * @generated - */ - @Override - public boolean isFactoryForType(Object object) { - if (object == modelPackage) { - return true; - } - if (object instanceof EObject) { - return ((EObject)object).eClass().getEPackage() == modelPackage; - } - return false; - } - - /** - * The switch that delegates to the createXXX methods. - * - * - * @generated - */ - protected yakinduSwitch modelSwitch = - new yakinduSwitch() { - @Override - public Adapter casePseudostate(Pseudostate object) { - return createPseudostateAdapter(); - } - @Override - public Adapter caseVertex(Vertex object) { - return createVertexAdapter(); - } - @Override - public Adapter caseRegion(Region object) { - return createRegionAdapter(); - } - @Override - public Adapter caseTransition(Transition object) { - return createTransitionAdapter(); - } - @Override - public Adapter caseStatechart(Statechart object) { - return createStatechartAdapter(); - } - @Override - public Adapter caseEntry(Entry object) { - return createEntryAdapter(); - } - @Override - public Adapter caseSynchronization(Synchronization object) { - return createSynchronizationAdapter(); - } - @Override - public Adapter caseState(State object) { - return createStateAdapter(); - } - @Override - public Adapter caseRegularState(RegularState object) { - return createRegularStateAdapter(); - } - @Override - public Adapter caseCompositeElement(CompositeElement object) { - return createCompositeElementAdapter(); - } - @Override - public Adapter caseChoice(Choice object) { - return createChoiceAdapter(); - } - @Override - public Adapter caseExit(Exit object) { - return createExitAdapter(); - } - @Override - public Adapter caseFinalState(FinalState object) { - return createFinalStateAdapter(); - } - @Override - public Adapter defaultCase(EObject object) { - return createEObjectAdapter(); - } - }; - - /** - * Creates an adapter for the target. - * - * - * @param target the object to adapt. - * @return the adapter for the target. - * @generated - */ - @Override - public Adapter createAdapter(Notifier target) { - return modelSwitch.doSwitch((EObject)target); - } - - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate - * @generated - */ - public Adapter createPseudostateAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex - * @generated - */ - public Adapter createVertexAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region - * @generated - */ - public Adapter createRegionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition - * @generated - */ - public Adapter createTransitionAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart - * @generated - */ - public Adapter createStatechartAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry - * @generated - */ - public Adapter createEntryAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization - * @generated - */ - public Adapter createSynchronizationAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State - * @generated - */ - public Adapter createStateAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState - * @generated - */ - public Adapter createRegularStateAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement - * @generated - */ - public Adapter createCompositeElementAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice - * @generated - */ - public Adapter createChoiceAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit - * @generated - */ - public Adapter createExitAdapter() { - return null; - } - - /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. - * - * This default implementation returns null so that we can easily ignore cases; - * it's useful to ignore a case when inheritance will catch all the cases anyway. - * - * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState - * @generated - */ - public Adapter createFinalStateAdapter() { - return null; - } - - /** - * Creates a new adapter for the default case. - * - * This default implementation returns null. - * - * @return the new adapter. - * @generated - */ - public Adapter createEObjectAdapter() { - return null; - } - -} //yakinduAdapterFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java deleted file mode 100644 index fbc6f821..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/util/yakinduSwitch.java +++ /dev/null @@ -1,378 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util; - -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.*; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.EPackage; - -import org.eclipse.emf.ecore.util.Switch; - -/** - * - * The Switch for the model's inheritance hierarchy. - * It supports the call {@link #doSwitch(EObject) doSwitch(object)} - * to invoke the caseXXX method for each class of the model, - * starting with the actual class of the object - * and proceeding up the inheritance hierarchy - * until a non-null result is returned, - * which is the result of the switch. - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage - * @generated - */ -public class yakinduSwitch extends Switch { - /** - * The cached model package - * - * - * @generated - */ - protected static yakinduPackage modelPackage; - - /** - * Creates an instance of the switch. - * - * - * @generated - */ - public yakinduSwitch() { - if (modelPackage == null) { - modelPackage = yakinduPackage.eINSTANCE; - } - } - - /** - * Checks whether this is a switch for the given package. - * - * - * @param ePackage the package in question. - * @return whether this is a switch for the given package. - * @generated - */ - @Override - protected boolean isSwitchFor(EPackage ePackage) { - return ePackage == modelPackage; - } - - /** - * Calls caseXXX for each class of the model until one returns a non null result; it yields that result. - * - * - * @return the first non-null result returned by a caseXXX call. - * @generated - */ - @Override - protected T doSwitch(int classifierID, EObject theEObject) { - switch (classifierID) { - case yakinduPackage.PSEUDOSTATE: { - Pseudostate pseudostate = (Pseudostate)theEObject; - T result = casePseudostate(pseudostate); - if (result == null) result = caseVertex(pseudostate); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.VERTEX: { - Vertex vertex = (Vertex)theEObject; - T result = caseVertex(vertex); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.REGION: { - Region region = (Region)theEObject; - T result = caseRegion(region); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.TRANSITION: { - Transition transition = (Transition)theEObject; - T result = caseTransition(transition); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.STATECHART: { - Statechart statechart = (Statechart)theEObject; - T result = caseStatechart(statechart); - if (result == null) result = caseCompositeElement(statechart); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.ENTRY: { - Entry entry = (Entry)theEObject; - T result = caseEntry(entry); - if (result == null) result = casePseudostate(entry); - if (result == null) result = caseVertex(entry); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.SYNCHRONIZATION: { - Synchronization synchronization = (Synchronization)theEObject; - T result = caseSynchronization(synchronization); - if (result == null) result = casePseudostate(synchronization); - if (result == null) result = caseVertex(synchronization); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.STATE: { - State state = (State)theEObject; - T result = caseState(state); - if (result == null) result = caseRegularState(state); - if (result == null) result = caseCompositeElement(state); - if (result == null) result = caseVertex(state); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.REGULAR_STATE: { - RegularState regularState = (RegularState)theEObject; - T result = caseRegularState(regularState); - if (result == null) result = caseVertex(regularState); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.COMPOSITE_ELEMENT: { - CompositeElement compositeElement = (CompositeElement)theEObject; - T result = caseCompositeElement(compositeElement); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.CHOICE: { - Choice choice = (Choice)theEObject; - T result = caseChoice(choice); - if (result == null) result = casePseudostate(choice); - if (result == null) result = caseVertex(choice); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.EXIT: { - Exit exit = (Exit)theEObject; - T result = caseExit(exit); - if (result == null) result = casePseudostate(exit); - if (result == null) result = caseVertex(exit); - if (result == null) result = defaultCase(theEObject); - return result; - } - case yakinduPackage.FINAL_STATE: { - FinalState finalState = (FinalState)theEObject; - T result = caseFinalState(finalState); - if (result == null) result = caseRegularState(finalState); - if (result == null) result = caseVertex(finalState); - if (result == null) result = defaultCase(theEObject); - return result; - } - default: return defaultCase(theEObject); - } - } - - /** - * Returns the result of interpreting the object as an instance of 'Pseudostate'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Pseudostate'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T casePseudostate(Pseudostate object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Vertex'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Vertex'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseVertex(Vertex object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Region'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Region'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseRegion(Region object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Transition'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Transition'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseTransition(Transition object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Statechart'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Statechart'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseStatechart(Statechart object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Entry'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Entry'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseEntry(Entry object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Synchronization'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Synchronization'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseSynchronization(Synchronization object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'State'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'State'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseState(State object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Regular State'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Regular State'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseRegularState(RegularState object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Composite Element'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Composite Element'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseCompositeElement(CompositeElement object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Choice'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Choice'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseChoice(Choice object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Exit'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Exit'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseExit(Exit object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'Final State'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'Final State'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) - * @generated - */ - public T caseFinalState(FinalState object) { - return null; - } - - /** - * Returns the result of interpreting the object as an instance of 'EObject'. - * - * This implementation returns null; - * returning a non-null result will terminate the switch, but this is the last case anyway. - * - * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'EObject'. - * @see #doSwitch(org.eclipse.emf.ecore.EObject) - * @generated - */ - @Override - public T defaultCase(EObject object) { - return null; - } - -} //yakinduSwitch diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java deleted file mode 100644 index 6d437ecb..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduFactory.java +++ /dev/null @@ -1,114 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; - -import org.eclipse.emf.ecore.EFactory; - -/** - * - * The Factory for the model. - * It provides a create method for each non-abstract class of the model. - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage - * @generated - */ -public interface yakinduFactory extends EFactory { - /** - * The singleton instance of the factory. - * - * - * @generated - */ - yakinduFactory eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduFactoryImpl.init(); - - /** - * Returns a new object of class 'Region'. - * - * - * @return a new object of class 'Region'. - * @generated - */ - Region createRegion(); - - /** - * Returns a new object of class 'Transition'. - * - * - * @return a new object of class 'Transition'. - * @generated - */ - Transition createTransition(); - - /** - * Returns a new object of class 'Statechart'. - * - * - * @return a new object of class 'Statechart'. - * @generated - */ - Statechart createStatechart(); - - /** - * Returns a new object of class 'Entry'. - * - * - * @return a new object of class 'Entry'. - * @generated - */ - Entry createEntry(); - - /** - * Returns a new object of class 'Synchronization'. - * - * - * @return a new object of class 'Synchronization'. - * @generated - */ - Synchronization createSynchronization(); - - /** - * Returns a new object of class 'State'. - * - * - * @return a new object of class 'State'. - * @generated - */ - State createState(); - - /** - * Returns a new object of class 'Choice'. - * - * - * @return a new object of class 'Choice'. - * @generated - */ - Choice createChoice(); - - /** - * Returns a new object of class 'Exit'. - * - * - * @return a new object of class 'Exit'. - * @generated - */ - Exit createExit(); - - /** - * Returns a new object of class 'Final State'. - * - * - * @return a new object of class 'Final State'. - * @generated - */ - FinalState createFinalState(); - - /** - * Returns the package supported by this factory. - * - * - * @return the package supported by this factory. - * @generated - */ - yakinduPackage getyakinduPackage(); - -} //yakinduFactory diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java deleted file mode 100644 index b3b14944..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/src/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/yakinduPackage.java +++ /dev/null @@ -1,1038 +0,0 @@ -/** - */ -package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu; - -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EPackage; -import org.eclipse.emf.ecore.EReference; - -/** - * - * The Package for the model. - * It contains accessors for the meta objects to represent - *

      - *
    • each class,
    • - *
    • each feature of each class,
    • - *
    • each operation of each class,
    • - *
    • each enum,
    • - *
    • and each data type
    • - *
    - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduFactory - * @model kind="package" - * @generated - */ -public interface yakinduPackage extends EPackage { - /** - * The package name. - * - * - * @generated - */ - String eNAME = "yakindu"; - - /** - * The package namespace URI. - * - * - * @generated - */ - String eNS_URI = "YakinduMetamodel"; - - /** - * The package namespace name. - * - * - * @generated - */ - String eNS_PREFIX = "yakindu"; - - /** - * The singleton instance of the package. - * - * - * @generated - */ - yakinduPackage eINSTANCE = ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl.init(); - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getVertex() - * @generated - */ - int VERTEX = 1; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int VERTEX__INCOMING_TRANSITIONS = 0; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int VERTEX__OUTGOING_TRANSITIONS = 1; - - /** - * The number of structural features of the 'Vertex' class. - * - * - * @generated - * @ordered - */ - int VERTEX_FEATURE_COUNT = 2; - - /** - * The number of operations of the 'Vertex' class. - * - * - * @generated - * @ordered - */ - int VERTEX_OPERATION_COUNT = 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getPseudostate() - * @generated - */ - int PSEUDOSTATE = 0; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int PSEUDOSTATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int PSEUDOSTATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Pseudostate' class. - * - * - * @generated - * @ordered - */ - int PSEUDOSTATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Pseudostate' class. - * - * - * @generated - * @ordered - */ - int PSEUDOSTATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegion() - * @generated - */ - int REGION = 2; - - /** - * The feature id for the 'Vertices' containment reference list. - * - * - * @generated - * @ordered - */ - int REGION__VERTICES = 0; - - /** - * The number of structural features of the 'Region' class. - * - * - * @generated - * @ordered - */ - int REGION_FEATURE_COUNT = 1; - - /** - * The number of operations of the 'Region' class. - * - * - * @generated - * @ordered - */ - int REGION_OPERATION_COUNT = 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getTransition() - * @generated - */ - int TRANSITION = 3; - - /** - * The feature id for the 'Target' reference. - * - * - * @generated - * @ordered - */ - int TRANSITION__TARGET = 0; - - /** - * The feature id for the 'Source' container reference. - * - * - * @generated - * @ordered - */ - int TRANSITION__SOURCE = 1; - - /** - * The number of structural features of the 'Transition' class. - * - * - * @generated - * @ordered - */ - int TRANSITION_FEATURE_COUNT = 2; - - /** - * The number of operations of the 'Transition' class. - * - * - * @generated - * @ordered - */ - int TRANSITION_OPERATION_COUNT = 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getCompositeElement() - * @generated - */ - int COMPOSITE_ELEMENT = 9; - - /** - * The feature id for the 'Regions' containment reference list. - * - * - * @generated - * @ordered - */ - int COMPOSITE_ELEMENT__REGIONS = 0; - - /** - * The number of structural features of the 'Composite Element' class. - * - * - * @generated - * @ordered - */ - int COMPOSITE_ELEMENT_FEATURE_COUNT = 1; - - /** - * The number of operations of the 'Composite Element' class. - * - * - * @generated - * @ordered - */ - int COMPOSITE_ELEMENT_OPERATION_COUNT = 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getStatechart() - * @generated - */ - int STATECHART = 4; - - /** - * The feature id for the 'Regions' containment reference list. - * - * - * @generated - * @ordered - */ - int STATECHART__REGIONS = COMPOSITE_ELEMENT__REGIONS; - - /** - * The number of structural features of the 'Statechart' class. - * - * - * @generated - * @ordered - */ - int STATECHART_FEATURE_COUNT = COMPOSITE_ELEMENT_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Statechart' class. - * - * - * @generated - * @ordered - */ - int STATECHART_OPERATION_COUNT = COMPOSITE_ELEMENT_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getEntry() - * @generated - */ - int ENTRY = 5; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int ENTRY__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int ENTRY__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Entry' class. - * - * - * @generated - * @ordered - */ - int ENTRY_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Entry' class. - * - * - * @generated - * @ordered - */ - int ENTRY_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getSynchronization() - * @generated - */ - int SYNCHRONIZATION = 6; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int SYNCHRONIZATION__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int SYNCHRONIZATION__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Synchronization' class. - * - * - * @generated - * @ordered - */ - int SYNCHRONIZATION_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Synchronization' class. - * - * - * @generated - * @ordered - */ - int SYNCHRONIZATION_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegularState() - * @generated - */ - int REGULAR_STATE = 8; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int REGULAR_STATE__INCOMING_TRANSITIONS = VERTEX__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int REGULAR_STATE__OUTGOING_TRANSITIONS = VERTEX__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Regular State' class. - * - * - * @generated - * @ordered - */ - int REGULAR_STATE_FEATURE_COUNT = VERTEX_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Regular State' class. - * - * - * @generated - * @ordered - */ - int REGULAR_STATE_OPERATION_COUNT = VERTEX_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getState() - * @generated - */ - int STATE = 7; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; - - /** - * The feature id for the 'Regions' containment reference list. - * - * - * @generated - * @ordered - */ - int STATE__REGIONS = REGULAR_STATE_FEATURE_COUNT + 0; - - /** - * The number of structural features of the 'State' class. - * - * - * @generated - * @ordered - */ - int STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 1; - - /** - * The number of operations of the 'State' class. - * - * - * @generated - * @ordered - */ - int STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getChoice() - * @generated - */ - int CHOICE = 10; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int CHOICE__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int CHOICE__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Choice' class. - * - * - * @generated - * @ordered - */ - int CHOICE_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Choice' class. - * - * - * @generated - * @ordered - */ - int CHOICE_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getExit() - * @generated - */ - int EXIT = 11; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int EXIT__INCOMING_TRANSITIONS = PSEUDOSTATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int EXIT__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Exit' class. - * - * - * @generated - * @ordered - */ - int EXIT_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Exit' class. - * - * - * @generated - * @ordered - */ - int EXIT_OPERATION_COUNT = PSEUDOSTATE_OPERATION_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getFinalState() - * @generated - */ - int FINAL_STATE = 12; - - /** - * The feature id for the 'Incoming Transitions' reference list. - * - * - * @generated - * @ordered - */ - int FINAL_STATE__INCOMING_TRANSITIONS = REGULAR_STATE__INCOMING_TRANSITIONS; - - /** - * The feature id for the 'Outgoing Transitions' containment reference list. - * - * - * @generated - * @ordered - */ - int FINAL_STATE__OUTGOING_TRANSITIONS = REGULAR_STATE__OUTGOING_TRANSITIONS; - - /** - * The number of structural features of the 'Final State' class. - * - * - * @generated - * @ordered - */ - int FINAL_STATE_FEATURE_COUNT = REGULAR_STATE_FEATURE_COUNT + 0; - - /** - * The number of operations of the 'Final State' class. - * - * - * @generated - * @ordered - */ - int FINAL_STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; - - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate Pseudostate}'. - * - * - * @return the meta object for class 'Pseudostate'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Pseudostate - * @generated - */ - EClass getPseudostate(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex Vertex}'. - * - * - * @return the meta object for class 'Vertex'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex - * @generated - */ - EClass getVertex(); - - /** - * Returns the meta object for the reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions Incoming Transitions}'. - * - * - * @return the meta object for the reference list 'Incoming Transitions'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getIncomingTransitions() - * @see #getVertex() - * @generated - */ - EReference getVertex_IncomingTransitions(); - - /** - * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions Outgoing Transitions}'. - * - * - * @return the meta object for the containment reference list 'Outgoing Transitions'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Vertex#getOutgoingTransitions() - * @see #getVertex() - * @generated - */ - EReference getVertex_OutgoingTransitions(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region Region}'. - * - * - * @return the meta object for class 'Region'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region - * @generated - */ - EClass getRegion(); - - /** - * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices Vertices}'. - * - * - * @return the meta object for the containment reference list 'Vertices'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region#getVertices() - * @see #getRegion() - * @generated - */ - EReference getRegion_Vertices(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition Transition}'. - * - * - * @return the meta object for class 'Transition'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition - * @generated - */ - EClass getTransition(); - - /** - * Returns the meta object for the reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget Target}'. - * - * - * @return the meta object for the reference 'Target'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getTarget() - * @see #getTransition() - * @generated - */ - EReference getTransition_Target(); - - /** - * Returns the meta object for the container reference '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource Source}'. - * - * - * @return the meta object for the container reference 'Source'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition#getSource() - * @see #getTransition() - * @generated - */ - EReference getTransition_Source(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart Statechart}'. - * - * - * @return the meta object for class 'Statechart'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Statechart - * @generated - */ - EClass getStatechart(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry Entry}'. - * - * - * @return the meta object for class 'Entry'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Entry - * @generated - */ - EClass getEntry(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization Synchronization}'. - * - * - * @return the meta object for class 'Synchronization'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization - * @generated - */ - EClass getSynchronization(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State State}'. - * - * - * @return the meta object for class 'State'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.State - * @generated - */ - EClass getState(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState Regular State}'. - * - * - * @return the meta object for class 'Regular State'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.RegularState - * @generated - */ - EClass getRegularState(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement Composite Element}'. - * - * - * @return the meta object for class 'Composite Element'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement - * @generated - */ - EClass getCompositeElement(); - - /** - * Returns the meta object for the containment reference list '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions Regions}'. - * - * - * @return the meta object for the containment reference list 'Regions'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement#getRegions() - * @see #getCompositeElement() - * @generated - */ - EReference getCompositeElement_Regions(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice Choice}'. - * - * - * @return the meta object for class 'Choice'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Choice - * @generated - */ - EClass getChoice(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit Exit}'. - * - * - * @return the meta object for class 'Exit'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Exit - * @generated - */ - EClass getExit(); - - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState Final State}'. - * - * - * @return the meta object for class 'Final State'. - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.FinalState - * @generated - */ - EClass getFinalState(); - - /** - * Returns the factory that creates the instances of the model. - * - * - * @return the factory that creates the instances of the model. - * @generated - */ - yakinduFactory getyakinduFactory(); - - /** - * - * Defines literals for the meta objects that represent - *
      - *
    • each class,
    • - *
    • each feature of each class,
    • - *
    • each operation of each class,
    • - *
    • each enum,
    • - *
    • and each data type
    • - *
    - * - * @generated - */ - interface Literals { - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl Pseudostate}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.PseudostateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getPseudostate() - * @generated - */ - EClass PSEUDOSTATE = eINSTANCE.getPseudostate(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl Vertex}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.VertexImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getVertex() - * @generated - */ - EClass VERTEX = eINSTANCE.getVertex(); - - /** - * The meta object literal for the 'Incoming Transitions' reference list feature. - * - * - * @generated - */ - EReference VERTEX__INCOMING_TRANSITIONS = eINSTANCE.getVertex_IncomingTransitions(); - - /** - * The meta object literal for the 'Outgoing Transitions' containment reference list feature. - * - * - * @generated - */ - EReference VERTEX__OUTGOING_TRANSITIONS = eINSTANCE.getVertex_OutgoingTransitions(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl Region}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegionImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegion() - * @generated - */ - EClass REGION = eINSTANCE.getRegion(); - - /** - * The meta object literal for the 'Vertices' containment reference list feature. - * - * - * @generated - */ - EReference REGION__VERTICES = eINSTANCE.getRegion_Vertices(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl Transition}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.TransitionImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getTransition() - * @generated - */ - EClass TRANSITION = eINSTANCE.getTransition(); - - /** - * The meta object literal for the 'Target' reference feature. - * - * - * @generated - */ - EReference TRANSITION__TARGET = eINSTANCE.getTransition_Target(); - - /** - * The meta object literal for the 'Source' container reference feature. - * - * - * @generated - */ - EReference TRANSITION__SOURCE = eINSTANCE.getTransition_Source(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl Statechart}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StatechartImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getStatechart() - * @generated - */ - EClass STATECHART = eINSTANCE.getStatechart(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl Entry}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.EntryImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getEntry() - * @generated - */ - EClass ENTRY = eINSTANCE.getEntry(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl Synchronization}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.SynchronizationImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getSynchronization() - * @generated - */ - EClass SYNCHRONIZATION = eINSTANCE.getSynchronization(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.StateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getState() - * @generated - */ - EClass STATE = eINSTANCE.getState(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl Regular State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.RegularStateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getRegularState() - * @generated - */ - EClass REGULAR_STATE = eINSTANCE.getRegularState(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl Composite Element}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.CompositeElementImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getCompositeElement() - * @generated - */ - EClass COMPOSITE_ELEMENT = eINSTANCE.getCompositeElement(); - - /** - * The meta object literal for the 'Regions' containment reference list feature. - * - * - * @generated - */ - EReference COMPOSITE_ELEMENT__REGIONS = eINSTANCE.getCompositeElement_Regions(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl Choice}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ChoiceImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getChoice() - * @generated - */ - EClass CHOICE = eINSTANCE.getChoice(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl Exit}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.ExitImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getExit() - * @generated - */ - EClass EXIT = eINSTANCE.getExit(); - - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl Final State}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.FinalStateImpl - * @see ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl.yakinduPackageImpl#getFinalState() - * @generated - */ - EClass FINAL_STATE = eINSTANCE.getFinalState(); - - } - -} //yakinduPackage diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index f8fc4d59..33dc7485 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -236,7 +236,4 @@ - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 7e2c1f12..890872ea 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 9ef2b1a0..8d7947e1 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index 468a5b6f..91741fb2 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index ecbaed63..e1fba1c4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index bed2786b..22b54964 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java index f0d7d924..f8502439 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java @@ -1,112 +1,10 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.CompositeElement; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Region; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Synchronization; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.Transition; -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage; -import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; -import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; -import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; -import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; -import java.util.HashMap; -import java.util.Map; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; -import org.eclipse.xtend2.lib.StringConcatenation; -import org.eclipse.xtext.xbase.lib.Exceptions; -import org.eclipse.xtext.xbase.lib.InputOutput; -import org.eclipse.xtext.xbase.lib.ObjectExtensions; -import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; - @SuppressWarnings("all") public class YakinduTest { public static void main(final String[] args) { - try { - final Ecore2Logic ecore2Logic = new Ecore2Logic(); - final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); - final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/YakinduTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; - final Map map = reg.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - map.put("logicproblem", _xMIResourceFactoryImpl); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(yakinduPackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/yakinduinstance.xmi"); - final Object queries = null; - InputOutput.println("DSL loaded"); - Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); - final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); - LogicProblem problem = modelGenerationProblem.getOutput(); - problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); - workspace.writeModel(problem, "Yakindu.logicproblem"); - InputOutput.println("Problem created"); - long startTime = System.currentTimeMillis(); - LogicReasoner reasoner = null; - VampireSolver _vampireSolver = new VampireSolver(); - reasoner = _vampireSolver; - final HashMap classMapMin = new HashMap(); - classMapMin.put(Region.class, Integer.valueOf(1)); - classMapMin.put(Transition.class, Integer.valueOf(2)); - classMapMin.put(CompositeElement.class, Integer.valueOf(3)); - final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); - final HashMap classMapMax = new HashMap(); - classMapMax.put(Region.class, Integer.valueOf(5)); - classMapMax.put(Transition.class, Integer.valueOf(2)); - classMapMax.put(Synchronization.class, Integer.valueOf(4)); - final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); - VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); - final Procedure1 _function = (VampireSolverConfiguration it) -> { - it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 20; - it.typeScopes.maxNewElements = 30; - int _size = typeMapMin.size(); - boolean _notEquals = (_size != 0); - if (_notEquals) { - it.typeScopes.minNewElementsByType = typeMapMin; - } - int _size_1 = typeMapMin.size(); - boolean _notEquals_1 = (_size_1 != 0); - if (_notEquals_1) { - it.typeScopes.maxNewElementsByType = typeMapMax; - } - it.contCycleLevel = 5; - it.uniquenessDuplicates = false; - }; - final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); - LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); - long _currentTimeMillis = System.currentTimeMillis(); - long _minus = (_currentTimeMillis - startTime); - long totalTimeMin = (_minus / 60000); - long _currentTimeMillis_1 = System.currentTimeMillis(); - long _minus_1 = (_currentTimeMillis_1 - startTime); - long _divide = (_minus_1 / 1000); - long totalTimeSec = (_divide % 60); - InputOutput.println("Problem solved"); - InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); - } catch (Throwable _e) { - throw Exceptions.sneakyThrow(_e); - } + throw new Error("Unresolved compilation problems:" + + "\nThe method or field yakinduPackage is undefined" + + "\neINSTANCE cannot be resolved"); } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 1bcd0a44..c33ed958 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 6272497d..9fecf93f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 2f327d75..7b5be981 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 6b70878a56052e1c254ba8c66485f217d22db3f8 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Wed, 28 Aug 2019 05:56:34 -0400 Subject: VAMPIRE: integrate local Vampire executeable #32 --- .../metrics/calculator/app/.Domain.java._trace | Bin 0 -> 164 bytes .../metrics/calculator/app/.Domain.xtendbin | Bin 0 -> 1885 bytes .../metrics/calculator/app/.Main.java._trace | Bin 0 -> 6539 bytes .../metrics/calculator/app/.Main.xtendbin | Bin 0 -> 8247 bytes .../app/.MetricDistanceGroup.java._trace | Bin 0 -> 2918 bytes .../app/.PartialInterpretationMetric.java._trace | Bin 0 -> 2152 bytes .../app/.PartialInterpretationMetric.xtendbin | Bin 0 -> 6658 bytes ...PartialInterpretationMetricDistance.java._trace | Bin 0 -> 12333 bytes .../.PartialInterpretationMetricDistance.xtendbin | Bin 0 -> 12384 bytes .../realistic/metrics/calculator/app/Domain.java | 10 + .../realistic/metrics/calculator/app/Main.java | 99 +++++++++ .../calculator/app/MetricDistanceGroup.java | 49 +++++ .../app/PartialInterpretationMetric.java | 54 +++++ .../app/PartialInterpretationMetricDistance.java | 180 ++++++++++++++++ .../calculator/distance/.CostDistance.java._trace | Bin 0 -> 1591 bytes .../calculator/distance/.CostDistance.xtendbin | Bin 0 -> 4755 bytes .../distance/.EuclideanDistance.java._trace | Bin 0 -> 6400 bytes .../distance/.EuclideanDistance.xtendbin | Bin 0 -> 6373 bytes .../calculator/distance/.JSDistance.java._trace | Bin 0 -> 10274 bytes .../calculator/distance/.JSDistance.xtendbin | Bin 0 -> 7080 bytes .../calculator/distance/.KSDistance.java._trace | Bin 0 -> 5179 bytes .../calculator/distance/.KSDistance.xtendbin | Bin 0 -> 7053 bytes .../calculator/distance/.StateData.java._trace | Bin 0 -> 1071 bytes .../metrics/calculator/distance/CostDistance.java | 26 +++ .../calculator/distance/EuclideanDistance.java | 91 ++++++++ .../metrics/calculator/distance/JSDistance.java | 136 ++++++++++++ .../metrics/calculator/distance/KSDistance.java | 93 +++++++++ .../metrics/calculator/distance/StateData.java | 38 ++++ .../metrics/calculator/graph/.EMFGraph.java._trace | Bin 0 -> 10303 bytes .../metrics/calculator/graph/.EMFGraph.xtendbin | Bin 0 -> 7659 bytes .../metrics/calculator/graph/.Graph.java._trace | Bin 0 -> 5380 bytes .../metrics/calculator/graph/.Graph.xtendbin | Bin 0 -> 5215 bytes .../calculator/graph/.GraphStatistic.java._trace | Bin 0 -> 14346 bytes .../calculator/graph/.GraphStatistic.xtendbin | Bin 0 -> 8393 bytes .../graph/.PartialInterpretationGraph.java._trace | Bin 0 -> 10923 bytes .../graph/.PartialInterpretationGraph.xtendbin | Bin 0 -> 8678 bytes .../metrics/calculator/graph/EMFGraph.java | 140 +++++++++++++ .../realistic/metrics/calculator/graph/Graph.java | 96 +++++++++ .../metrics/calculator/graph/GraphStatistic.java | 201 ++++++++++++++++++ .../graph/PartialInterpretationGraph.java | 162 +++++++++++++++ .../calculator/io/.CsvFileWriter.java._trace | Bin 0 -> 4046 bytes .../metrics/calculator/io/.CsvFileWriter.xtendbin | Bin 0 -> 4364 bytes .../metrics/calculator/io/.DataName.java._trace | Bin 0 -> 395 bytes .../metrics/calculator/io/.GraphReader.java._trace | Bin 0 -> 8762 bytes .../metrics/calculator/io/.GraphReader.xtendbin | Bin 0 -> 7536 bytes .../calculator/io/.RepMetricsReader.java._trace | Bin 0 -> 2611 bytes .../calculator/io/.RepMetricsReader.xtendbin | Bin 0 -> 7213 bytes .../metrics/calculator/io/CsvFileWriter.java | 75 +++++++ .../realistic/metrics/calculator/io/DataName.java | 12 ++ .../metrics/calculator/io/GraphReader.java | 138 +++++++++++++ .../metrics/calculator/io/RepMetricsReader.java | 49 +++++ .../calculator/metrics/.EdgeTypeMetric.java._trace | Bin 0 -> 3341 bytes .../calculator/metrics/.EdgeTypeMetric.xtendbin | Bin 0 -> 3968 bytes .../metrics/calculator/metrics/.Metric.java._trace | Bin 0 -> 381 bytes .../metrics/calculator/metrics/.Metric.xtendbin | Bin 0 -> 2472 bytes .../metrics/.MetricSampleGroup.java._trace | Bin 0 -> 756 bytes .../calculator/metrics/.MetricSampleGroup.xtendbin | Bin 0 -> 2822 bytes ...iplexParticipationCoefficientMetric.java._trace | Bin 0 -> 3277 bytes ...ultiplexParticipationCoefficientMetric.xtendbin | Bin 0 -> 6315 bytes .../metrics/.NodeActivityMetric.java._trace | Bin 0 -> 1066 bytes .../metrics/.NodeActivityMetric.xtendbin | Bin 0 -> 4941 bytes .../calculator/metrics/.NodeTypeMetric.java._trace | Bin 0 -> 2658 bytes .../calculator/metrics/.NodeTypeMetric.xtendbin | Bin 0 -> 3676 bytes .../metrics/.OutDegreeMetric.java._trace | Bin 0 -> 1063 bytes .../calculator/metrics/.OutDegreeMetric.xtendbin | Bin 0 -> 4940 bytes .../.TypedClusteringCoefficientMetric.java._trace | Bin 0 -> 4325 bytes .../.TypedClusteringCoefficientMetric.xtendbin | Bin 0 -> 6380 bytes .../calculator/metrics/.TypedOutDegree.java._trace | Bin 0 -> 4081 bytes .../calculator/metrics/.TypedOutDegree.xtendbin | Bin 0 -> 4458 bytes .../metrics/calculator/metrics/EdgeTypeMetric.java | 65 ++++++ .../metrics/calculator/metrics/Metric.java | 10 + .../calculator/metrics/MetricSampleGroup.java | 19 ++ .../MultiplexParticipationCoefficientMetric.java | 59 ++++++ .../calculator/metrics/NodeActivityMetric.java | 31 +++ .../metrics/calculator/metrics/NodeTypeMetric.java | 54 +++++ .../calculator/metrics/OutDegreeMetric.java | 31 +++ .../metrics/TypedClusteringCoefficientMetric.java | 74 +++++++ .../metrics/calculator/metrics/TypedOutDegree.java | 73 +++++++ .../calculator/predictor/.LinearModel.java._trace | Bin 0 -> 4597 bytes .../calculator/predictor/.LinearModel.xtendbin | Bin 0 -> 6307 bytes .../metrics/calculator/predictor/LinearModel.java | 90 ++++++++ .../validation/.ConstraintCollection.java._trace | Bin 0 -> 1968 bytes .../validation/.ConstraintCollection.xtendbin | Bin 0 -> 6940 bytes .../validation/.ViolationCheck.java._trace | Bin 0 -> 607 bytes .../calculator/validation/.ViolationCheck.xtendbin | Bin 0 -> 5275 bytes .../validation/ConstraintCollection.java | 79 +++++++ .../calculator/validation/ViolationCheck.java | 34 +++ .../metrics/calculations/.CalcC.java._trace | Bin 0 -> 5637 bytes .../metrics/calculations/.CalcEDA.java._trace | Bin 0 -> 13288 bytes .../metrics/calculations/.CalcMPC.java._trace | Bin 0 -> 24403 bytes .../metrics/calculations/.CalcMetric.java._trace | Bin 0 -> 522 bytes .../metrics/calculations/.CalcMetric2.java._trace | Bin 0 -> 608 bytes .../metrics/calculations/.CalcNA.java._trace | Bin 0 -> 13672 bytes .../metrics/calculations/.CalcNDA.java._trace | Bin 0 -> 10147 bytes .../metrics/calculations/.CalcNDC.java._trace | Bin 0 -> 7235 bytes .../metrics/calculations/.CalcSQRCNT.java._trace | Bin 0 -> 7671 bytes .../metrics/calculations/.CalcSQRNUM.java._trace | Bin 0 -> 15830 bytes .../metrics/calculations/.CalcSQROSZ.java._trace | Bin 0 -> 3437 bytes .../metrics/calculations/.CalcSQRTOT.java._trace | Bin 0 -> 13017 bytes .../metrics/examples/.CSERposterSample.xtendbin | Bin 0 -> 7750 bytes .../metrics/examples/.CalculationsNA.java._trace | Bin 0 -> 12572 bytes .../metrics/examples/.FixModelURIs.java._trace | Bin 0 -> 3743 bytes .../.MetricsCalculationUsingShapes.java._trace | Bin 0 -> 19842 bytes .../realistic/metrics/examples/.Util.java._trace | Bin 0 -> 32376 bytes .../realistic/metrics/examples/.gitignore | 1 + .../metrics/examples/.CSERposterSample.java._trace | Bin 0 -> 6221 bytes .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 4130 -> 4130 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../lib/putVampireHere | 2 + .../lib/vampire.exe | Bin 0 -> 11727673 bytes .../vampire/reasoner/VampireSolver.xtend | 42 ++-- .../vampire/reasoner/builder/VampireHandler.xtend | 72 +++++-- .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 5892 -> 6386 bytes .../vampire/reasoner/VampireSolver.java | 22 +- .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18149 -> 18150 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 4656 -> 4656 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 11904 -> 11904 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 6454 -> 6454 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 10667 -> 10667 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13046 -> 13048 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 11136 -> 11136 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 1720 -> 1720 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 4908 -> 6553 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../vampire/reasoner/builder/VampireHandler.java | 53 ++++- .../metamodels/filesystem.ecore | 2 +- .../.classpath | 1 - .../META-INF/MANIFEST.MF | 6 +- .../build.properties | 1 - .../plugin.xml | 229 --------------------- .../ecse/dslreasoner/vampire/icse/EcoreTest.xtend | 2 +- .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 2 +- .../dslreasoner/vampire/icse/FileSystemTest.xtend | 11 +- .../dslreasoner/vampire/icse/YakinduTest.xtend | 4 +- .../vampire.exe | Bin 0 -> 11727673 bytes .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4545 -> 4554 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6314 -> 6316 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 7116 -> 6204 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6456 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 7025 -> 7055 bytes .../ecse/dslreasoner/vampire/icse/EcoreTest.java | 63 +----- .../ecse/dslreasoner/vampire/icse/FAMTest.java | 3 +- .../dslreasoner/vampire/icse/FileSystemTest.java | 139 ++++++------- .../vampire/test/.MedicalSystem.xtendbin | Bin 4997 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6500 -> 6500 bytes 161 files changed, 2503 insertions(+), 420 deletions(-) create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.MetricDistanceGroup.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Domain.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Main.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/MetricDistanceGroup.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetricDistance.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.StateData.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/CostDistance.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/EuclideanDistance.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/JSDistance.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/KSDistance.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/StateData.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/EMFGraph.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/Graph.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/GraphStatistic.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/PartialInterpretationGraph.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.DataName.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/CsvFileWriter.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/DataName.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/GraphReader.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/RepMetricsReader.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/EdgeTypeMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/Metric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MetricSampleGroup.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MultiplexParticipationCoefficientMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeActivityMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeTypeMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/OutDegreeMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedClusteringCoefficientMetric.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedOutDegree.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/LinearModel.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.java._trace create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.xtendbin create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ConstraintCollection.java create mode 100644 Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ViolationCheck.java create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQROSZ.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CalculationsNA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.gitignore create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.java._trace create mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/putVampireHere create mode 100644 Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/vampire.exe create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/vampire.exe (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.java._trace new file mode 100644 index 00000000..8ab43fde Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.xtendbin new file mode 100644 index 00000000..f502d04e Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Domain.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.java._trace new file mode 100644 index 00000000..7096f9db Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.xtendbin new file mode 100644 index 00000000..2362ebad Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.Main.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.MetricDistanceGroup.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.MetricDistanceGroup.java._trace new file mode 100644 index 00000000..f6505088 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.MetricDistanceGroup.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.java._trace new file mode 100644 index 00000000..8708c793 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.xtendbin new file mode 100644 index 00000000..d9e88699 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.java._trace new file mode 100644 index 00000000..3e381b10 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.xtendbin new file mode 100644 index 00000000..5071eb03 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/.PartialInterpretationMetricDistance.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Domain.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Domain.java new file mode 100644 index 00000000..9b626001 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Domain.java @@ -0,0 +1,10 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app; + +@SuppressWarnings("all") +public enum Domain { + Yakindumm, + + Ecore, + + Github; +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Main.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Main.java new file mode 100644 index 00000000..dbb3bdd1 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/Main.java @@ -0,0 +1,99 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app.Domain; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.EMFGraph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io.CsvFileWriter; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io.GraphReader; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.validation.ViolationCheck; +import com.google.common.base.Objects; +import com.google.common.collect.Iterators; +import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl.YakindummPackageImpl; +import java.io.File; +import java.util.ArrayList; +import java.util.Iterator; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.emf.ecore.impl.EcorePackageImpl; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; +import org.eclipse.xtext.xbase.lib.Functions.Function1; +import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.IteratorExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; + +@SuppressWarnings("all") +public class Main { + public static class RWInformation { + public String inputFolder; + + public String outputFolder; + + public int numRuns; + + public RWInformation(final String inputFolder, final String outputFolder, final int numRuns) { + this.inputFolder = inputFolder; + this.outputFolder = outputFolder; + this.numRuns = numRuns; + } + } + + private static Domain d = Domain.Yakindumm; + + private final static String suffix = ".xmi"; + + private final static String OUTPUT_FOLDER = "Inputs/measurement2/yakindu/Alloy/"; + + private final static String INPUT_FOLDER = "outputs/measurement2/yakindu/Alloy/"; + + private final static int NUM_RUNS = 1; + + public static void main(final String[] args) { + throw new Error("Unresolved compilation problems:" + + "\nThe method or field ReteEngine is undefined" + + "\ngetClass cannot be resolved"); + } + + public static String calculateAllModels(final String inputFolder, final String outputFolder, final int numRuns, final GraphReader reader) { + String _xblockexpression = null; + { + new File(outputFolder).mkdir(); + for (int i = 1; (i <= numRuns); i++) { + { + final ArrayList models = new ArrayList(); + models.addAll(reader.readModels(((inputFolder + "run") + Integer.valueOf(i)))); + for (final EMFGraph model : models) { + String _name = model.getName(); + String _plus = (outputFolder + _name); + String _plus_1 = (_plus + "_run_"); + String _plus_2 = (_plus_1 + Integer.valueOf(i)); + String _plus_3 = (_plus_2 + ".csv"); + Main.calculateAndOutputMetrics(model, YakindummPackageImpl.eNAME, _plus_3); + } + } + } + _xblockexpression = InputOutput.println(("output results Ended for: " + outputFolder)); + } + return _xblockexpression; + } + + public static void calculateAndOutputMetrics(final EMFGraph model, final String metaModel, final String fileName) { + model.setMetaModel(metaModel); + boolean _equals = Objects.equal(Main.d, Domain.Ecore); + if (_equals) { + final Function1 _function = (EReference it) -> { + return Boolean.valueOf((((((it.getName().equals("eGenericType") || it.getName().equals("eGenericSuperTypes")) || it.getName().equals("eFactoryInstance")) || + it.getName().equals("eGenericExceptions")) || it.getName().equals("references")) || it.getName().equals("contents"))); + }; + Iterator refsToRemove = IteratorExtensions.filter(Iterators.filter(EcorePackageImpl.eINSTANCE.eAllContents(), EReference.class), _function); + final Procedure1 _function_1 = (EReference it) -> { + model.removeReference(it); + }; + IteratorExtensions.forEach(refsToRemove, _function_1); + } + ArrayList> outputs = model.evaluateAllMetrics(); + int violations = ViolationCheck.calculateViolationCounts(model.getRoot(), Main.d); + InputOutput.println(Integer.valueOf(violations)); + String _plus = (Integer.valueOf(violations) + ""); + ArrayList violationsOutput = CollectionLiterals.newArrayList("violations", _plus); + outputs.add(violationsOutput); + CsvFileWriter.write(outputs, fileName); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/MetricDistanceGroup.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/MetricDistanceGroup.java new file mode 100644 index 00000000..bb0e3ffb --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/MetricDistanceGroup.java @@ -0,0 +1,49 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app; + +import java.util.HashMap; + +@SuppressWarnings("all") +public class MetricDistanceGroup { + private double mpcDistance; + + private double naDistance; + + private double outDegreeDistance; + + private double nodeTypeDistance; + + protected HashMap nodeTypeInfo; + + public MetricDistanceGroup(final double mpcDistance, final double naDistance, final double outDegreeDistance, final double nodeTypeDistance) { + this.mpcDistance = mpcDistance; + this.naDistance = naDistance; + this.outDegreeDistance = outDegreeDistance; + this.nodeTypeDistance = nodeTypeDistance; + } + + public MetricDistanceGroup(final double mpcDistance, final double naDistance, final double outDegreeDistance) { + this.mpcDistance = mpcDistance; + this.naDistance = naDistance; + this.outDegreeDistance = outDegreeDistance; + } + + public double getNodeTypeDistance() { + return this.nodeTypeDistance; + } + + public double getMPCDistance() { + return this.mpcDistance; + } + + public double getNADistance() { + return this.naDistance; + } + + public double getOutDegreeDistance() { + return this.outDegreeDistance; + } + + public double getNodeTypePercentage(final String typeName) { + return (this.nodeTypeInfo.getOrDefault(typeName, Double.valueOf(0.0))).doubleValue(); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetric.java new file mode 100644 index 00000000..d1d75d0d --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetric.java @@ -0,0 +1,54 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.JSDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.KSDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.PartialInterpretationGraph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io.CsvFileWriter; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MultiplexParticipationCoefficientMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeActivityMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.OutDegreeMetric; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialInterpretation; +import java.io.File; +import java.util.ArrayList; +import java.util.List; + +@SuppressWarnings("all") +public class PartialInterpretationMetric { + private static KSDistance ks; + + private static JSDistance js; + + public static void initPaths() { + new File("debug/metric/").mkdir(); + new File("debug/metric/trajectories/").mkdir(); + } + + public static void calculateMetric(final PartialInterpretation partial, final String path, final String currentStateId, final Integer counter) { + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + new File(path).mkdir(); + final String filename = (((((path + "/state_") + currentStateId) + "-") + counter) + ".csv"); + final PartialInterpretationGraph metricCalculator = new PartialInterpretationGraph(partial, metrics, currentStateId); + CsvFileWriter.write(metricCalculator.evaluateAllMetrics(), filename); + } + + public static void outputTrajectories(final PartialInterpretation empty, final /* List */Object solutions) { + throw new Error("Unresolved compilation problems:" + + "\nshortestTrajectory cannot be resolved" + + "\nmodel cannot be resolved" + + "\ndoNextTransformation cannot be resolved" + + "\nstateCoder cannot be resolved" + + "\ncreateStateCode cannot be resolved" + + "\ntoString cannot be resolved" + + "\ngetModel cannot be resolved" + + "\nstateCoder cannot be resolved" + + "\ncreateStateCode cannot be resolved" + + "\ntoString cannot be resolved"); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetricDistance.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetricDistance.java new file mode 100644 index 00000000..c98cbeea --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/app/PartialInterpretationMetricDistance.java @@ -0,0 +1,180 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app.Domain; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app.MetricDistanceGroup; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.EuclideanDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.JSDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.KSDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.StateData; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.PartialInterpretationGraph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MultiplexParticipationCoefficientMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeActivityMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeTypeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.OutDegreeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.predictor.LinearModel; +import com.google.common.base.Objects; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialInterpretation; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import org.eclipse.xtend.lib.annotations.AccessorType; +import org.eclipse.xtend.lib.annotations.Accessors; +import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.Pure; + +@SuppressWarnings("all") +public class PartialInterpretationMetricDistance { + private KSDistance ks; + + private JSDistance js; + + private EuclideanDistance ed; + + private Map stateAndHistory; + + private /* OLSMultipleLinearRegression */Object regression; + + private List samples; + + private MetricSampleGroup g; + + @Accessors(AccessorType.PUBLIC_GETTER) + private LinearModel linearModel; + + public PartialInterpretationMetricDistance(final Domain d) { + throw new Error("Unresolved compilation problems:" + + "\nOLSMultipleLinearRegression cannot be resolved." + + "\nThe field PartialInterpretationMetricDistance.regression refers to the missing type OLSMultipleLinearRegression" + + "\nThe field PartialInterpretationMetricDistance.regression refers to the missing type OLSMultipleLinearRegression" + + "\nnoIntercept cannot be resolved"); + } + + public MetricDistanceGroup calculateMetricDistanceKS(final PartialInterpretation partial) { + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + NodeTypeMetric _nodeTypeMetric = new NodeTypeMetric(); + metrics.add(_nodeTypeMetric); + final PartialInterpretationGraph metricCalculator = new PartialInterpretationGraph(partial, metrics, null); + MetricSampleGroup metricSamples = metricCalculator.evaluateAllMetricsToSamples(); + double mpc = this.ks.mpcDistance(metricSamples.mpcSamples); + double na = this.ks.naDistance(metricSamples.naSamples); + double outDegree = this.ks.outDegreeDistance(metricSamples.outDegreeSamples); + double nodeType = this.ks.nodeTypeDistance(metricSamples.nodeTypeSamples); + MetricDistanceGroup distance = new MetricDistanceGroup(mpc, na, outDegree, nodeType); + distance.nodeTypeInfo = metricSamples.nodeTypeSamples; + return distance; + } + + public MetricDistanceGroup calculateMetricEuclidean(final PartialInterpretation partial) { + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + final PartialInterpretationGraph metricCalculator = new PartialInterpretationGraph(partial, metrics, null); + MetricSampleGroup metricSamples = metricCalculator.evaluateAllMetricsToSamples(); + double mpc = this.ed.mpcDistance(metricSamples.mpcSamples); + double na = this.ed.naDistance(metricSamples.naSamples); + double outDegree = this.ed.outDegreeDistance(metricSamples.outDegreeSamples); + return new MetricDistanceGroup(mpc, na, outDegree); + } + + public MetricDistanceGroup calculateMetricDistance(final PartialInterpretation partial) { + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + final PartialInterpretationGraph metricCalculator = new PartialInterpretationGraph(partial, metrics, null); + MetricSampleGroup metricSamples = metricCalculator.evaluateAllMetricsToSamples(); + double mpc = this.js.mpcDistance(metricSamples.mpcSamples); + double na = this.js.naDistance(metricSamples.naSamples); + double outDegree = this.js.outDegreeDistance(metricSamples.outDegreeSamples); + return new MetricDistanceGroup(mpc, na, outDegree); + } + + public String resetRegression(final Object state) { + String _xblockexpression = null; + { + this.samples.clear(); + boolean _containsKey = this.stateAndHistory.containsKey(state); + if (_containsKey) { + StateData data = this.stateAndHistory.get(state); + Object curState = state; + this.samples.add(data); + while ((this.stateAndHistory.containsKey(data.getLastState()) && (!Objects.equal(data.getLastState(), curState)))) { + { + curState = data.getLastState(); + data = this.stateAndHistory.get(data.getLastState()); + this.samples.add(data); + } + } + int _size = this.samples.size(); + boolean _equals = (_size == 0); + if (_equals) { + InputOutput.println(("state: " + state)); + Object _lastState = data.getLastState(); + String _plus = ("last state: " + _lastState); + InputOutput.println(_plus); + } + } + int _size_1 = this.samples.size(); + String _plus_1 = ("trajectory sample size:" + Integer.valueOf(_size_1)); + _xblockexpression = InputOutput.println(_plus_1); + } + return _xblockexpression; + } + + public boolean feedData(final Object state, final double[] features, final double value, final Object lastState) { + boolean _xblockexpression = false; + { + StateData data = new StateData(features, value, lastState); + this.stateAndHistory.put(state, data); + _xblockexpression = this.samples.add(data); + } + return _xblockexpression; + } + + public Object getPredictionForNextDataSample(final double[] features, final double value, final double[] featuresToPredict) { + throw new Error("Unresolved compilation problems:" + + "\nThe field PartialInterpretationMetricDistance.regression refers to the missing type OLSMultipleLinearRegression" + + "\nThe method predict(double[]) from the type PartialInterpretationMetricDistance refers to the missing type Object" + + "\nnewSampleData cannot be resolved"); + } + + private Object predict(final double[] featuresToPredict) { + throw new Error("Unresolved compilation problems:" + + "\nThe field PartialInterpretationMetricDistance.regression refers to the missing type OLSMultipleLinearRegression" + + "\nestimateRegressionParameters cannot be resolved" + + "\nget cannot be resolved" + + "\n+= cannot be resolved" + + "\nget cannot be resolved" + + "\n* cannot be resolved"); + } + + public double[] calculateFeature(final int step, final int violations) { + double[] features = new double[2]; + features[0] = 1; + double _sqrt = Math.sqrt(step); + double _plus = (_sqrt + 30); + features[0] = _plus; + features[1] = (1.0 / (step + 30)); + return features; + } + + @Pure + public LinearModel getLinearModel() { + return this.linearModel; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.java._trace new file mode 100644 index 00000000..b7325732 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.xtendbin new file mode 100644 index 00000000..1b30d47a Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.CostDistance.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.java._trace new file mode 100644 index 00000000..fa849d42 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.xtendbin new file mode 100644 index 00000000..e7be4117 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.EuclideanDistance.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.java._trace new file mode 100644 index 00000000..66b1b229 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.xtendbin new file mode 100644 index 00000000..7a08f8e5 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.JSDistance.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.java._trace new file mode 100644 index 00000000..c7256d9a Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.xtendbin new file mode 100644 index 00000000..309066cc Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.KSDistance.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.StateData.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.StateData.java._trace new file mode 100644 index 00000000..d4cde029 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/.StateData.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/CostDistance.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/CostDistance.java new file mode 100644 index 00000000..cb366f64 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/CostDistance.java @@ -0,0 +1,26 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance; + +import java.text.DecimalFormat; +import java.util.HashMap; +import java.util.List; + +@SuppressWarnings("all") +public abstract class CostDistance { + public abstract double naDistance(final List samples); + + public abstract double mpcDistance(final List samples); + + public abstract double outDegreeDistance(final List samples); + + protected HashMap pmfFromSamples(final double[] samples, final DecimalFormat formatter) { + int length = samples.length; + HashMap pmfMap = new HashMap(); + for (final double sample : samples) { + String _format = formatter.format(sample); + Double _orDefault = pmfMap.getOrDefault(formatter.format(sample), Double.valueOf(0.0)); + double _plus = ((_orDefault).doubleValue() + (1.0 / length)); + pmfMap.put(_format, Double.valueOf(_plus)); + } + return pmfMap; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/EuclideanDistance.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/EuclideanDistance.java new file mode 100644 index 00000000..6a80d750 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/EuclideanDistance.java @@ -0,0 +1,91 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.CostDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import com.google.common.collect.Sets; +import java.text.DecimalFormat; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.function.ToDoubleFunction; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.DoubleExtensions; + +@SuppressWarnings("all") +public class EuclideanDistance extends CostDistance { + private MetricSampleGroup g; + + private HashMap mpcPMF; + + private HashMap naPMF; + + private HashMap outDegreePMF; + + private DecimalFormat formatter; + + public EuclideanDistance(final MetricSampleGroup g) { + this.g = g; + List mpcSamples = g.mpcSamples; + final ToDoubleFunction _function = (Double it) -> { + return (it).doubleValue(); + }; + double[] naSamples = g.naSamples.stream().mapToDouble(_function).toArray(); + final ToDoubleFunction _function_1 = (Double it) -> { + return (it).doubleValue(); + }; + double[] outDegreeSamples = g.outDegreeSamples.stream().mapToDouble(_function_1).toArray(); + DecimalFormat _decimalFormat = new DecimalFormat("#0.00000"); + this.formatter = _decimalFormat; + final List _converted_mpcSamples = (List)mpcSamples; + this.mpcPMF = this.pmfFromSamples(((double[])Conversions.unwrapArray(_converted_mpcSamples, double.class)), this.formatter); + this.naPMF = this.pmfFromSamples(naSamples, this.formatter); + this.outDegreePMF = this.pmfFromSamples(outDegreeSamples, this.formatter); + } + + @Override + public double naDistance(final List samples) { + HashMap pmfMap = this.pmfFromSamples(((double[])Conversions.unwrapArray(samples, double.class)), this.formatter); + return this.euclideanDistance(pmfMap, this.naPMF); + } + + @Override + public double mpcDistance(final List samples) { + HashMap pmfMap = this.pmfFromSamples(((double[])Conversions.unwrapArray(samples, double.class)), this.formatter); + return this.euclideanDistance(pmfMap, this.mpcPMF); + } + + @Override + public double outDegreeDistance(final List samples) { + HashMap pmfMap = this.pmfFromSamples(((double[])Conversions.unwrapArray(samples, double.class)), this.formatter); + return this.euclideanDistance(pmfMap, this.outDegreePMF); + } + + private double euclideanDistance(final HashMap pmf1, final HashMap pmf2) { + Sets.SetView keys = Sets.union(pmf1.keySet(), pmf2.keySet()); + ArrayList pmfList1 = this.pmfMapToList(pmf1, keys); + ArrayList pmfList2 = this.pmfMapToList(pmf2, keys); + double distance = 0.0; + for (int i = 0; (i < pmfList1.size()); i++) { + double _distance = distance; + Double _get = pmfList1.get(i); + Double _get_1 = pmfList2.get(i); + double _plus = DoubleExtensions.operator_plus(_get, _get_1); + double _pow = Math.pow(_plus, 2); + distance = (_distance + _pow); + } + return Math.sqrt(distance); + } + + private ArrayList pmfMapToList(final Map map, final Set keys) { + ArrayList list = new ArrayList(); + for (final String key : keys) { + { + Double value = map.getOrDefault(key, Double.valueOf(0.0)); + list.add(value); + } + } + return list; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/JSDistance.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/JSDistance.java new file mode 100644 index 00000000..d3e7e3ad --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/JSDistance.java @@ -0,0 +1,136 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.CostDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import com.google.common.collect.Sets; +import java.text.DecimalFormat; +import java.util.HashMap; +import java.util.List; +import java.util.Set; +import java.util.function.ToDoubleFunction; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.DoubleExtensions; + +@SuppressWarnings("all") +public class JSDistance extends CostDistance { + private HashMap mpcPMF; + + private HashMap naPMF; + + private HashMap outDegreePMF; + + private HashMap nodeTypesPMF; + + private DecimalFormat formatter; + + public JSDistance(final MetricSampleGroup g) { + List mpcSamples = g.mpcSamples; + final ToDoubleFunction _function = (Double it) -> { + return (it).doubleValue(); + }; + double[] naSamples = g.naSamples.stream().mapToDouble(_function).toArray(); + final ToDoubleFunction _function_1 = (Double it) -> { + return (it).doubleValue(); + }; + double[] outDegreeSamples = g.outDegreeSamples.stream().mapToDouble(_function_1).toArray(); + DecimalFormat _decimalFormat = new DecimalFormat("#0.00000"); + this.formatter = _decimalFormat; + final List _converted_mpcSamples = (List)mpcSamples; + this.mpcPMF = this.pmfFromSamples(((double[])Conversions.unwrapArray(_converted_mpcSamples, double.class)), this.formatter); + this.naPMF = this.pmfFromSamples(naSamples, this.formatter); + this.outDegreePMF = this.pmfFromSamples(outDegreeSamples, this.formatter); + this.nodeTypesPMF = g.nodeTypeSamples; + } + + private HashMap combinePMF(final HashMap pmf1, final HashMap pmf2) { + HashMap pmfMap = new HashMap(); + Sets.SetView union = Sets.union(pmf1.keySet(), pmf2.keySet()); + for (final String key : union) { + { + Double _orDefault = pmf1.getOrDefault(key, Double.valueOf(0.0)); + Double _orDefault_1 = pmf2.getOrDefault(key, Double.valueOf(0.0)); + double _plus = DoubleExtensions.operator_plus(_orDefault, _orDefault_1); + double value = ((1.0 / 2) * _plus); + pmfMap.put(key, Double.valueOf(value)); + } + } + return pmfMap; + } + + private double jsDivergence(final HashMap p, final HashMap q) { + final HashMap m = this.combinePMF(q, p); + double _klDivergence = this.klDivergence(p, m); + double _multiply = ((1.0 / 2) * _klDivergence); + double _klDivergence_1 = this.klDivergence(q, m); + double _multiply_1 = ((1.0 / 2) * _klDivergence_1); + double distance = (_multiply + _multiply_1); + return distance; + } + + public double klDivergence(final HashMap p, final HashMap q) { + double distance = 0.0; + Set _keySet = q.keySet(); + for (final String key : _keySet) { + boolean _containsKey = p.containsKey(key); + if (_containsKey) { + double _distance = distance; + Double _get = p.get(key); + Double _get_1 = q.get(key); + Double _get_2 = p.get(key); + double _divide = DoubleExtensions.operator_divide(_get_1, _get_2); + double _log = Math.log(_divide); + double _multiply = ((_get).doubleValue() * _log); + double _log_1 = Math.log(2); + double _divide_1 = (_multiply / _log_1); + distance = (_distance - _divide_1); + } + } + return distance; + } + + @Override + public double mpcDistance(final List samples) { + final ToDoubleFunction _function = (Double it) -> { + return (it).doubleValue(); + }; + HashMap map = this.pmfFromSamples(samples.stream().mapToDouble(_function).toArray(), this.formatter); + int _size = map.size(); + boolean _lessThan = (_size < 2); + if (_lessThan) { + return 1; + } + return this.jsDivergence(map, this.mpcPMF); + } + + @Override + public double naDistance(final List samples) { + final ToDoubleFunction _function = (Double it) -> { + return (it).doubleValue(); + }; + HashMap map = this.pmfFromSamples(samples.stream().mapToDouble(_function).toArray(), this.formatter); + int _size = map.size(); + boolean _lessThan = (_size < 2); + if (_lessThan) { + return 1; + } + return this.jsDivergence(map, this.naPMF); + } + + @Override + public double outDegreeDistance(final List samples) { + final ToDoubleFunction _function = (Double it) -> { + return (it).doubleValue(); + }; + HashMap map = this.pmfFromSamples(samples.stream().mapToDouble(_function).toArray(), this.formatter); + int _size = map.size(); + boolean _lessThan = (_size < 2); + if (_lessThan) { + return 1; + } + return this.jsDivergence(map, this.outDegreePMF); + } + + public double nodeTypeDistance(final HashMap samples) { + return this.klDivergence(samples, this.nodeTypesPMF); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/KSDistance.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/KSDistance.java new file mode 100644 index 00000000..638ff332 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/KSDistance.java @@ -0,0 +1,93 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.CostDistance; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Set; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; + +@SuppressWarnings("all") +public class KSDistance extends CostDistance { + private static Object ksTester /* Skipped initializer because of errors */; + + private MetricSampleGroup g; + + public KSDistance(final MetricSampleGroup g) { + this.g = g; + } + + @Override + public double mpcDistance(final List samples) { + throw new Error("Unresolved compilation problems:" + + "\nThe field KSDistance.ksTester refers to the missing type Object" + + "\nkolmogorovSmirnovStatistic cannot be resolved"); + } + + @Override + public double naDistance(final List samples) { + throw new Error("Unresolved compilation problems:" + + "\nThe field KSDistance.ksTester refers to the missing type Object" + + "\nkolmogorovSmirnovStatistic cannot be resolved"); + } + + @Override + public double outDegreeDistance(final List samples) { + throw new Error("Unresolved compilation problems:" + + "\nThe field KSDistance.ksTester refers to the missing type Object" + + "\nkolmogorovSmirnovStatistic cannot be resolved"); + } + + public double typedOutDegreeDistance(final HashMap> map) { + throw new Error("Unresolved compilation problems:" + + "\nThe field KSDistance.ksTester refers to the missing type Object" + + "\nkolmogorovSmirnovStatistic cannot be resolved"); + } + + public double nodeTypeDistance(final HashMap samples) { + HashMap typesDistMap = this.g.nodeTypeSamples; + ArrayList sourceDist = CollectionLiterals.newArrayList(); + ArrayList instanceDist = CollectionLiterals.newArrayList(); + Set _keySet = typesDistMap.keySet(); + for (final String key : _keySet) { + { + sourceDist.add(typesDistMap.get(key)); + instanceDist.add(samples.getOrDefault(key, Double.valueOf(0.0))); + } + } + return this.ks_distance_two_dist(sourceDist, instanceDist); + } + + public double edgeTypeDistance(final HashMap samples) { + HashMap typesDistMap = this.g.edgeTypeSamples; + ArrayList sourceDist = CollectionLiterals.newArrayList(); + ArrayList instanceDist = CollectionLiterals.newArrayList(); + Set _keySet = typesDistMap.keySet(); + for (final String key : _keySet) { + { + sourceDist.add(typesDistMap.get(key)); + instanceDist.add(samples.getOrDefault(key, Double.valueOf(0.0))); + } + } + return this.ks_distance_two_dist(sourceDist, instanceDist); + } + + public double ks_distance_two_dist(final List dist1, final List dist2) { + double ksStatistics = 0.0; + double sum1 = 0.0; + double sum2 = 0.0; + for (int i = 0; (i < dist1.size()); i++) { + { + double _sum1 = sum1; + Double _get = dist1.get(i); + sum1 = (_sum1 + (_get).doubleValue()); + double _sum2 = sum2; + Double _get_1 = dist2.get(i); + sum2 = (_sum2 + (_get_1).doubleValue()); + ksStatistics = Math.max(ksStatistics, Math.abs((sum1 - sum2))); + } + } + return ksStatistics; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/StateData.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/StateData.java new file mode 100644 index 00000000..29a310f4 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/distance/StateData.java @@ -0,0 +1,38 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance; + +import org.eclipse.xtend.lib.annotations.AccessorType; +import org.eclipse.xtend.lib.annotations.Accessors; +import org.eclipse.xtext.xbase.lib.Pure; + +@SuppressWarnings("all") +public class StateData { + @Accessors(AccessorType.PUBLIC_GETTER) + private double[] features; + + @Accessors(AccessorType.PUBLIC_GETTER) + private double value; + + @Accessors(AccessorType.PUBLIC_GETTER) + private Object lastState; + + public StateData(final double[] features, final double value, final Object lastState) { + this.features = features; + this.value = value; + this.lastState = lastState; + } + + @Pure + public double[] getFeatures() { + return this.features; + } + + @Pure + public double getValue() { + return this.value; + } + + @Pure + public Object getLastState() { + return this.lastState; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.java._trace new file mode 100644 index 00000000..6e2ea420 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.xtendbin new file mode 100644 index 00000000..e949bb11 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.EMFGraph.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.java._trace new file mode 100644 index 00000000..e1d021fd Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.xtendbin new file mode 100644 index 00000000..547fdc38 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.Graph.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.java._trace new file mode 100644 index 00000000..5928ed9d Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.xtendbin new file mode 100644 index 00000000..e9269f16 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.GraphStatistic.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.java._trace new file mode 100644 index 00000000..f19eb46c Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.xtendbin new file mode 100644 index 00000000..c634ef10 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/.PartialInterpretationGraph.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/EMFGraph.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/EMFGraph.java new file mode 100644 index 00000000..8a9aa8d3 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/EMFGraph.java @@ -0,0 +1,140 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.Graph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import java.util.ArrayList; +import java.util.HashSet; +import java.util.List; +import java.util.function.Consumer; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.xtend.lib.annotations.AccessorType; +import org.eclipse.xtend.lib.annotations.Accessors; +import org.eclipse.xtext.xbase.lib.IteratorExtensions; +import org.eclipse.xtext.xbase.lib.Pure; + +@SuppressWarnings("all") +public class EMFGraph extends Graph { + @Accessors(AccessorType.PUBLIC_GETTER) + private EObject root; + + public void init(final EObject root, final List metrics, final String name, final List referenceTypes) { + final List otherContents = IteratorExtensions.toList(root.eAllContents()); + this.root = root; + otherContents.add(root); + this.init(otherContents, metrics, name, referenceTypes); + } + + /** + * init the graph with all nodes and reference types in the meta model + * @param objects: objects in the instance model (exclude root) + * @param metrics: metrics to be evaluated + * @param name: name of the instance model + * @param ReferenceTypes: reference types defined in the meta model + */ + public void init(final List objects, final List metrics, final String name, final List referenceTypes) { + final Consumer _function = (EObject it) -> { + HashSet types = new HashSet(); + types.add(it.eClass().getName()); + this.statistic.addNodeWithAllTypes(it, types); + }; + objects.forEach(_function); + final Consumer _function_1 = (EReference it) -> { + boolean _isDerived = it.isDerived(); + boolean _not = (!_isDerived); + if (_not) { + this.statistic.addEdgeType(it.getName()); + } + }; + referenceTypes.forEach(_function_1); + final Consumer _function_2 = (EObject source) -> { + final Consumer _function_3 = (EReference r) -> { + boolean _isMany = r.isMany(); + if (_isMany) { + final Consumer _function_4 = (EObject target) -> { + this.addEdge(source, target, r); + }; + this.getNeighbours(source, r).forEach(_function_4); + } else { + Object _eGet = source.eGet(r); + final EObject target = ((EObject) _eGet); + this.addEdge(source, target, r); + } + }; + source.eClass().getEAllReferences().forEach(_function_3); + }; + objects.forEach(_function_2); + this.metrics = metrics; + this.name = name; + } + + public void removeReference(final EReference r) { + boolean _containsEdgeType = this.statistic.containsEdgeType(r.getName()); + if (_containsEdgeType) { + this.statistic.removeReference(r.getName(), r.isContainment()); + } + } + + /** + * Set basic information for the output + */ + @Override + public void setBasicInformation(final ArrayList> output) { + final ArrayList metaInfo = new ArrayList(); + metaInfo.add(Graph.META_MODEL_HEADER); + metaInfo.add(this.metaModel); + final ArrayList edgeInfo = new ArrayList(); + edgeInfo.add(Graph.NUM_EDGE_TYPE_HEADER); + int _size = this.statistic.getAllTypes().size(); + String _plus = (Integer.valueOf(_size) + ""); + edgeInfo.add(_plus); + final ArrayList nodeInfo = new ArrayList(); + nodeInfo.add(Graph.NUM_NODE_HEADER); + int _size_1 = this.statistic.getAllNodes().size(); + String _plus_1 = (Integer.valueOf(_size_1) + ""); + nodeInfo.add(_plus_1); + final ArrayList stateInfo = new ArrayList(); + stateInfo.add(Graph.STATE_ID_HEADER); + stateInfo.add(this.name); + output.add(metaInfo); + output.add(edgeInfo); + output.add(nodeInfo); + output.add(stateInfo); + } + + public EList getNeighbours(final EObject o, final EReference r) { + Object _eGet = o.eGet(r, true); + return ((EList) _eGet); + } + + public void addEdge(final EObject source, final EObject target, final EReference r) { + if ((((target != null) && (r != null)) && (!r.isDerived()))) { + this.statistic.addEdge(source, target, r.getName()); + } + } + + @Override + public GraphStatistic getStatistic() { + return this.statistic; + } + + @Override + public String getName() { + return this.name; + } + + public void setMetaModel(final String model) { + this.metaModel = model; + } + + public String getMetaModel() { + return this.metaModel; + } + + @Pure + public EObject getRoot() { + return this.root; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/Graph.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/Graph.java new file mode 100644 index 00000000..f9923a63 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/Graph.java @@ -0,0 +1,96 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.EdgeTypeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MultiplexParticipationCoefficientMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeActivityMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeTypeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.OutDegreeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.TypedOutDegree; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.List; +import org.eclipse.xtext.xbase.lib.Conversions; + +@SuppressWarnings("all") +public abstract class Graph { + protected final static String META_MODEL_HEADER = "Meta Mode"; + + protected final static String NUM_NODE_HEADER = "Number Of Nodes"; + + protected final static String NUM_EDGE_TYPE_HEADER = "Number of Edge types"; + + protected final static String STATE_ID_HEADER = "State Id"; + + protected final GraphStatistic statistic = new GraphStatistic(); + + protected List metrics; + + protected String name = ""; + + protected String metaModel = ""; + + /** + * evaluate all metrics for this model + * return the result as a two dimentional list + */ + public ArrayList> evaluateAllMetrics() { + final ArrayList> result = new ArrayList>(); + this.setBasicInformation(result); + for (final Metric metric : this.metrics) { + { + final String[][] datas = metric.evaluate(this.statistic); + for (final String[] row : datas) { + ArrayList _arrayList = new ArrayList((Collection)Conversions.doWrapArray(row)); + result.add(_arrayList); + } + } + } + return result; + } + + public MetricSampleGroup evaluateAllMetricsToSamples() { + MetricSampleGroup sample = new MetricSampleGroup(); + for (final Metric metric : this.metrics) { + if ((metric instanceof MultiplexParticipationCoefficientMetric)) { + Object _evaluateSamples = ((MultiplexParticipationCoefficientMetric)metric).evaluateSamples(this.statistic); + sample.mpcSamples = ((ArrayList) _evaluateSamples); + } else { + if ((metric instanceof NodeActivityMetric)) { + Object _evaluateSamples_1 = ((NodeActivityMetric)metric).evaluateSamples(this.statistic); + sample.naSamples = ((ArrayList) _evaluateSamples_1); + } else { + if ((metric instanceof OutDegreeMetric)) { + Object _evaluateSamples_2 = ((OutDegreeMetric)metric).evaluateSamples(this.statistic); + sample.outDegreeSamples = ((ArrayList) _evaluateSamples_2); + } else { + if ((metric instanceof TypedOutDegree)) { + Object _evaluateSamples_3 = ((TypedOutDegree)metric).evaluateSamples(this.statistic); + sample.typedOutDegreeSamples = ((HashMap>) _evaluateSamples_3); + } else { + if ((metric instanceof NodeTypeMetric)) { + Object _evaluateSamples_4 = ((NodeTypeMetric)metric).evaluateSamples(this.statistic); + sample.nodeTypeSamples = ((HashMap) _evaluateSamples_4); + } else { + if ((metric instanceof EdgeTypeMetric)) { + Object _evaluateSamples_5 = ((EdgeTypeMetric)metric).evaluateSamples(this.statistic); + sample.edgeTypeSamples = ((HashMap) _evaluateSamples_5); + } + } + } + } + } + } + } + return sample; + } + + public abstract void setBasicInformation(final ArrayList> result); + + public abstract GraphStatistic getStatistic(); + + public abstract String getName(); +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/GraphStatistic.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/GraphStatistic.java new file mode 100644 index 00000000..7bd1d899 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/GraphStatistic.java @@ -0,0 +1,201 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph; + +import com.google.common.collect.ArrayListMultimap; +import com.google.common.collect.Multimap; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.function.Consumer; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.xtext.xbase.lib.IterableExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; + +@SuppressWarnings("all") +public class GraphStatistic { + private final HashMap> incomingEdges = new HashMap>(); + + private final HashMap> outgoingEdges = new HashMap>(); + + private final HashSet edgeTypes = new HashSet(); + + private final HashMap> nodeToType = new HashMap>(); + + /** + * Add an edge type to to the graph + * @param type: type to add + */ + public void addEdgeType(final String type) { + boolean _contains = this.edgeTypes.contains(type); + if (_contains) { + return; + } + this.edgeTypes.add(type); + this.incomingEdges.put(type, ArrayListMultimap.create()); + this.outgoingEdges.put(type, ArrayListMultimap.create()); + } + + /** + * Add a node to the graph with one type in its type hierarchy + * @param node: node to add + */ + public void addNodeWithType(final EObject n, final String Type) { + HashSet _hashSet = new HashSet(); + Set types = this.nodeToType.getOrDefault(n, _hashSet); + types.add(Type); + this.nodeToType.put(n, types); + } + + public boolean containsNode(final EObject o) { + return this.nodeToType.containsKey(o); + } + + public Set getTypesForNode(final EObject o) { + HashSet _hashSet = new HashSet(); + return this.nodeToType.getOrDefault(o, _hashSet); + } + + public void overwriteCurrentType(final EObject o, final String type) { + HashSet _hashSet = new HashSet(); + Set typeSet = this.nodeToType.getOrDefault(o, _hashSet); + typeSet.clear(); + typeSet.add(type); + this.nodeToType.put(o, typeSet); + } + + /** + * Add a node to the graph with all types in its type hierarchy + */ + public void addNodeWithAllTypes(final EObject n, final Set types) { + this.nodeToType.put(n, types); + } + + /** + * Add an edge to the graph + * @param source: source node + * @param target: target node + * @param type: type of the reference + */ + public void addEdge(final EObject source, final EObject target, final String type) { + this.outgoingEdges.get(type).put(source, target); + this.incomingEdges.get(type).put(target, source); + } + + /** + * check if this graph contains a specific edge type + */ + public boolean containsEdgeType(final String typeName) { + if ((this.outgoingEdges.containsKey(typeName) && this.incomingEdges.containsKey(typeName))) { + return true; + } + return false; + } + + /** + * remove references from the statistics, potentially remove the nodes associated with it + * @Param name: name of the reference + * @Param isContainment: if true then the corresponding nodes on the incoming side will also be removed + */ + public void removeReference(final String name, final boolean isContainment) { + boolean _contains = this.edgeTypes.contains(name); + boolean _not = (!_contains); + if (_not) { + return; + } + this.edgeTypes.remove(name); + Multimap incomingSet = this.incomingEdges.remove(name); + this.outgoingEdges.remove(name); + if ((!isContainment)) { + return; + } + final Set nodesToRemove = incomingSet.keySet(); + final Consumer _function = (EObject it) -> { + this.nodeToType.remove(it); + }; + nodesToRemove.forEach(_function); + final Procedure1> _function_1 = (Multimap refMap) -> { + final Consumer _function_2 = (EObject it) -> { + refMap.removeAll(it); + }; + nodesToRemove.forEach(_function_2); + Collection values = refMap.values(); + values.removeAll(nodesToRemove); + return; + }; + final Procedure1> removeForMultimap = _function_1; + IterableExtensions.>forEach(this.incomingEdges.values(), removeForMultimap); + IterableExtensions.>forEach(this.outgoingEdges.values(), removeForMultimap); + } + + /** + * calculate the out degree for an object + */ + public int outDegree(final EObject o) { + int count = 0; + for (final String type : this.edgeTypes) { + int _count = count; + int _size = this.outgoingEdges.get(type).get(o).size(); + count = (_count + _size); + } + return count; + } + + /** + * calculate the in degree of an object + */ + public int inDegree(final EObject o) { + int count = 0; + for (final String type : this.edgeTypes) { + int _count = count; + int _size = this.incomingEdges.get(type).get(o).size(); + count = (_count + _size); + } + return count; + } + + /** + * calculate the dimentional degree of a node + */ + public int dimentionalDegree(final EObject o, final String type) { + int _size = this.incomingEdges.get(type).get(o).size(); + int _size_1 = this.outgoingEdges.get(type).get(o).size(); + return (_size + _size_1); + } + + /** + * calculate the number of edge types for a given node. + */ + public int numOfEdgeTypes(final EObject o) { + int count = 0; + for (final String type : this.edgeTypes) { + int _dimentionalDegree = this.dimentionalDegree(o, type); + boolean _greaterThan = (_dimentionalDegree > 0); + if (_greaterThan) { + count++; + } + } + return count; + } + + public List getAllTypes() { + return IterableExtensions.toList(this.edgeTypes); + } + + public Map> getNodeToTypesMap() { + return this.nodeToType; + } + + public List getAllNodes() { + return IterableExtensions.toList(this.nodeToType.keySet()); + } + + public HashMap> getOutgoingEdges() { + return this.outgoingEdges; + } + + public HashMap> incomingEdges() { + return this.incomingEdges; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/PartialInterpretationGraph.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/PartialInterpretationGraph.java new file mode 100644 index 00000000..83bb92ca --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/graph/PartialInterpretationGraph.java @@ -0,0 +1,162 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.Graph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import com.google.common.collect.Iterables; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.DefinedElement; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.RelationDeclaration; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; +import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.TypeDefinition; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.BinaryElementRelationLink; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialInterpretation; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialRelationInterpretation; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.impl.PartialComplexTypeInterpretationImpl; +import java.util.ArrayList; +import java.util.List; +import java.util.function.Consumer; +import org.eclipse.emf.common.util.EList; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.Functions.Function1; +import org.eclipse.xtext.xbase.lib.IterableExtensions; +import org.eclipse.xtext.xbase.lib.ListExtensions; + +@SuppressWarnings("all") +public class PartialInterpretationGraph extends Graph { + private final String typeToExclude = "undefinedpart"; + + private final String classSuffix = " class"; + + /** + * Define a new PartialInterpretationGraph by parse every element from a PartialInterpretation + */ + public PartialInterpretationGraph(final PartialInterpretation partial, final List metrics, final String name) { + final Consumer _function = (RelationDeclaration it) -> { + String n = it.getName().split(" ")[0]; + this.statistic.addEdgeType(n); + }; + Iterables.filter(partial.getProblem().getRelations(), RelationDeclaration.class).forEach(_function); + final Iterable typeInterpretations = this.getTypes(partial); + for (final PartialComplexTypeInterpretationImpl type : typeInterpretations) { + boolean _isConcreteType = this.isConcreteType(type.getInterpretationOf()); + if (_isConcreteType) { + String typeName = type.getInterpretationOf().getName().replace(this.classSuffix, ""); + EList _elements = type.getElements(); + for (final DefinedElement node : _elements) { + boolean _containsNode = this.statistic.containsNode(node); + boolean _not = (!_containsNode); + if (_not) { + this.statistic.addNodeWithType(node, typeName); + } else { + String currentType = ((String[])Conversions.unwrapArray(this.statistic.getTypesForNode(node), String.class))[0]; + boolean _isSuperType = this.isSuperType(currentType, type.getInterpretationOf()); + if (_isSuperType) { + this.statistic.overwriteCurrentType(node, typeName); + } + } + } + } + } + EList _partialrelationinterpretation = partial.getPartialrelationinterpretation(); + for (final PartialRelationInterpretation relationInterpretation : _partialrelationinterpretation) { + { + final String type_1 = relationInterpretation.getInterpretationOf().getName().split(" ")[0]; + Iterable _filter = Iterables.filter(relationInterpretation.getRelationlinks(), BinaryElementRelationLink.class); + for (final BinaryElementRelationLink edge : _filter) { + this.statistic.addEdge(edge.getParam1(), edge.getParam2(), type_1); + } + } + } + this.name = name; + this.metrics = metrics; + } + + /** + * recursively check if a type is the super type of another + */ + public boolean isSuperType(final String typeName, final Type subtypeToCheck) { + EList superTypes = subtypeToCheck.getSupertypes(); + int _size = superTypes.size(); + boolean _equals = (_size == 0); + if (_equals) { + return false; + } else { + final Function1 _function = (Type it) -> { + return it.getName().replace(this.classSuffix, ""); + }; + boolean _contains = ListExtensions.map(subtypeToCheck.getSupertypes(), _function).contains(typeName); + if (_contains) { + return true; + } else { + for (final Type superType : superTypes) { + boolean _isSuperType = this.isSuperType(typeName, superType); + if (_isSuperType) { + return true; + } + } + return false; + } + } + } + + /** + * Check if a Type object is the class that we want to consider + * A type object is to be considered if it satisfy one of the following: + * 1. if it is not abstract + * 2. if it is abstract but has a subclass of type TypeDefinition (This means the generation is + * started with nodes in this type) + */ + public boolean isConcreteType(final Type t) { + if (((!t.isIsAbstract()) || (IterableExtensions.findFirst(t.getSubtypes(), ((Function1) (Type it) -> { + return Boolean.valueOf((it instanceof TypeDefinition)); + })) != null))) { + return true; + } + return false; + } + + /** + * Set basic information for the output + */ + @Override + public void setBasicInformation(final ArrayList> output) { + final ArrayList metaInfo = new ArrayList(); + metaInfo.add(Graph.META_MODEL_HEADER); + metaInfo.add(this.metaModel); + final ArrayList edgeInfo = new ArrayList(); + edgeInfo.add(Graph.NUM_EDGE_TYPE_HEADER); + int _size = this.statistic.getAllTypes().size(); + String _plus = (Integer.valueOf(_size) + ""); + edgeInfo.add(_plus); + final ArrayList nodeInfo = new ArrayList(); + nodeInfo.add(Graph.NUM_NODE_HEADER); + int _size_1 = this.statistic.getAllNodes().size(); + String _plus_1 = (Integer.valueOf(_size_1) + ""); + nodeInfo.add(_plus_1); + final ArrayList stateInfo = new ArrayList(); + stateInfo.add(Graph.STATE_ID_HEADER); + stateInfo.add(this.name); + output.add(metaInfo); + output.add(edgeInfo); + output.add(nodeInfo); + output.add(stateInfo); + } + + private Iterable getTypes(final PartialInterpretation partial) { + final Function1 _function = (PartialComplexTypeInterpretationImpl it) -> { + boolean _contains = it.getInterpretationOf().getName().toLowerCase().contains(this.typeToExclude); + return Boolean.valueOf((!_contains)); + }; + return IterableExtensions.filter(Iterables.filter(partial.getPartialtypeinterpratation(), PartialComplexTypeInterpretationImpl.class), _function); + } + + @Override + public GraphStatistic getStatistic() { + throw new UnsupportedOperationException("TODO: auto-generated method stub"); + } + + @Override + public String getName() { + return this.name; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.java._trace new file mode 100644 index 00000000..983bd97e Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.xtendbin new file mode 100644 index 00000000..daf9b285 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.CsvFileWriter.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.DataName.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.DataName.java._trace new file mode 100644 index 00000000..7a93f65a Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.DataName.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.java._trace new file mode 100644 index 00000000..2ee37cec Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.xtendbin new file mode 100644 index 00000000..8dda7d21 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.GraphReader.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.java._trace new file mode 100644 index 00000000..e7945d8c Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.xtendbin new file mode 100644 index 00000000..74675aec Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/.RepMetricsReader.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/CsvFileWriter.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/CsvFileWriter.java new file mode 100644 index 00000000..d166e31b --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/CsvFileWriter.java @@ -0,0 +1,75 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io; + +import java.io.File; +import java.io.FileNotFoundException; +import java.io.FileOutputStream; +import java.io.PrintWriter; +import java.util.ArrayList; +import java.util.List; +import org.eclipse.xtext.xbase.lib.Exceptions; + +@SuppressWarnings("all") +public class CsvFileWriter { + public static void write(final ArrayList> datas, final String uri) { + try { + int _size = datas.size(); + boolean _lessEqualsThan = (_size <= 0); + if (_lessEqualsThan) { + return; + } + File _file = new File(uri); + final PrintWriter writer = new PrintWriter(_file); + CsvFileWriter.output(writer, datas, uri); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } + } + + public static void append(final ArrayList> datas, final String uri) { + try { + int _size = datas.size(); + boolean _lessEqualsThan = (_size <= 0); + if (_lessEqualsThan) { + return; + } + File _file = new File(uri); + FileOutputStream _fileOutputStream = new FileOutputStream(_file, true); + final PrintWriter writer = new PrintWriter(_fileOutputStream); + CsvFileWriter.output(writer, datas, uri); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } + } + + private static void output(final PrintWriter writer, final ArrayList> datas, final String uri) { + try { + final StringBuilder output = new StringBuilder(); + for (final List datarow : datas) { + { + for (int i = 0; (i < (datarow.size() - 1)); i++) { + String _get = datarow.get(i); + String _plus = (_get + ","); + output.append(_plus); + } + int _size = datarow.size(); + boolean _greaterEqualsThan = (_size >= 1); + if (_greaterEqualsThan) { + int _size_1 = datarow.size(); + int _minus = (_size_1 - 1); + output.append(datarow.get(_minus)); + output.append("\n"); + } + } + } + writer.write(output.toString()); + writer.close(); + } catch (final Throwable _t) { + if (_t instanceof FileNotFoundException) { + final FileNotFoundException e = (FileNotFoundException)_t; + e.printStackTrace(); + } else { + throw Exceptions.sneakyThrow(_t); + } + } + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/DataName.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/DataName.java new file mode 100644 index 00000000..9e2c9c86 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/DataName.java @@ -0,0 +1,12 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io; + +@SuppressWarnings("all") +public class DataName { + public final static String REP_PATH = "data/"; + + public final static String MPC_REP = "mpc_rep"; + + public final static String NA_REP = "na_rep"; + + public final static String OUT_D_REP = "out_d_rep"; +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/GraphReader.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/GraphReader.java new file mode 100644 index 00000000..0299fc0c --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/GraphReader.java @@ -0,0 +1,138 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.EMFGraph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.EdgeTypeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MultiplexParticipationCoefficientMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeActivityMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.NodeTypeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.OutDegreeMetric; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.TypedOutDegree; +import java.io.File; +import java.io.FileNotFoundException; +import java.util.ArrayList; +import java.util.List; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.resource.ResourceSet; +import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.Exceptions; +import org.eclipse.xtext.xbase.lib.Functions.Function1; +import org.eclipse.xtext.xbase.lib.IterableExtensions; + +@SuppressWarnings("all") +public class GraphReader { + private final ResourceSet resSet = new ResourceSetImpl(); + + private final ArrayList referenceTypes = new ArrayList(); + + private String suffix; + + public GraphReader(final EPackage metaModel, final String suffix) { + throw new Error("Unresolved compilation problems:" + + "\nXMIResourceFactoryImpl cannot be resolved."); + } + + public List readModels(final String path) { + try { + final File dir = new File(path); + boolean _isDirectory = dir.isDirectory(); + boolean _not = (!_isDirectory); + if (_not) { + throw new Exception("expecting a directory"); + } + final ArrayList graphs = new ArrayList(); + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + TypedOutDegree _typedOutDegree = new TypedOutDegree(); + metrics.add(_typedOutDegree); + NodeTypeMetric _nodeTypeMetric = new NodeTypeMetric(); + metrics.add(_nodeTypeMetric); + EdgeTypeMetric _edgeTypeMetric = new EdgeTypeMetric(); + metrics.add(_edgeTypeMetric); + int count = 1; + final Function1 _function = (String it) -> { + return Boolean.valueOf(it.endsWith(this.suffix)); + }; + Iterable _filter = IterableExtensions.filter(((Iterable)Conversions.doWrapArray(dir.list())), _function); + for (final String name : _filter) { + { + final File file = new File(name); + final List roots = this.readModel(EObject.class, path, file.getName()); + final EMFGraph g = new EMFGraph(); + for (final EObject root : roots) { + g.init(root, metrics, name.replaceFirst(this.suffix, ""), this.referenceTypes); + } + count++; + graphs.add(g); + } + } + return graphs; + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } + } + + public EMFGraph readModel(final String path, final String filename) { + final ArrayList metrics = new ArrayList(); + OutDegreeMetric _outDegreeMetric = new OutDegreeMetric(); + metrics.add(_outDegreeMetric); + NodeActivityMetric _nodeActivityMetric = new NodeActivityMetric(); + metrics.add(_nodeActivityMetric); + MultiplexParticipationCoefficientMetric _multiplexParticipationCoefficientMetric = new MultiplexParticipationCoefficientMetric(); + metrics.add(_multiplexParticipationCoefficientMetric); + TypedOutDegree _typedOutDegree = new TypedOutDegree(); + metrics.add(_typedOutDegree); + NodeTypeMetric _nodeTypeMetric = new NodeTypeMetric(); + metrics.add(_nodeTypeMetric); + EdgeTypeMetric _edgeTypeMetric = new EdgeTypeMetric(); + metrics.add(_edgeTypeMetric); + final File file = new File(filename); + final List roots = this.readModel(EObject.class, path, file.getName()); + final EMFGraph g = new EMFGraph(); + for (final EObject root : roots) { + g.init(root, metrics, filename.replaceFirst(this.suffix, ""), this.referenceTypes); + } + return g; + } + + public List readModel(final Class type, final String path, final String name) { + try { + try { + final Resource resource = this.resSet.getResource(GraphReader.getURI(path, name), true); + if ((resource == null)) { + String _string = GraphReader.getURI(path, name).toString(); + throw new FileNotFoundException(_string); + } else { + EList _contents = resource.getContents(); + return ((List) _contents); + } + } catch (final Throwable _t) { + if (_t instanceof Exception) { + final Exception e = (Exception)_t; + e.printStackTrace(); + String _string_1 = GraphReader.getURI(path, name).toString(); + throw new Exception(_string_1); + } else { + throw Exceptions.sneakyThrow(_t); + } + } + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } + } + + public static URI getURI(final String path, final String name) { + return URI.createFileURI(((path + "/") + name)); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/RepMetricsReader.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/RepMetricsReader.java new file mode 100644 index 00000000..2486cf83 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/io/RepMetricsReader.java @@ -0,0 +1,49 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app.Domain; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.EMFGraph; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.io.GraphReader; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.MetricSampleGroup; +import com.google.common.base.Objects; +import com.google.common.collect.Iterators; +import java.util.Iterator; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.emf.ecore.impl.EcorePackageImpl; +import org.eclipse.xtext.xbase.lib.Functions.Function1; +import org.eclipse.xtext.xbase.lib.IterableExtensions; +import org.eclipse.xtext.xbase.lib.IteratorExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; + +/** + * Read the sample of the distribution of a metric provided the csv file of the metric + */ +@SuppressWarnings("all") +public class RepMetricsReader { + private static Domain domain; + + public static MetricSampleGroup read(final Domain d) { + throw new Error("Unresolved compilation problems:" + + "\nThe method or field GithubPackageImpl is undefined" + + "\neINSTANCE cannot be resolved"); + } + + /** + * Read representative model + */ + private static MetricSampleGroup readMetrics(final GraphReader r, final String path) { + final EMFGraph model = IterableExtensions.head(r.readModels(path)); + boolean _equals = Objects.equal(RepMetricsReader.domain, Domain.Ecore); + if (_equals) { + final Function1 _function = (EReference it) -> { + return Boolean.valueOf((((((it.getName().equals("eGenericType") || it.getName().equals("eGenericSuperTypes")) || it.getName().equals("eFactoryInstance")) || + it.getName().equals("eGenericExceptions")) || it.getName().equals("references")) || it.getName().equals("contents"))); + }; + Iterator refsToRemove = IteratorExtensions.filter(Iterators.filter(EcorePackageImpl.eINSTANCE.eAllContents(), EReference.class), _function); + final Procedure1 _function_1 = (EReference it) -> { + model.removeReference(it); + }; + IteratorExtensions.forEach(refsToRemove, _function_1); + } + return model.evaluateAllMetricsToSamples(); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.java._trace new file mode 100644 index 00000000..6f941f84 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.xtendbin new file mode 100644 index 00000000..97674c9e Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.EdgeTypeMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.java._trace new file mode 100644 index 00000000..4feb0150 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.xtendbin new file mode 100644 index 00000000..ffe985d4 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.Metric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.java._trace new file mode 100644 index 00000000..e206794e Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.xtendbin new file mode 100644 index 00000000..478004db Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MetricSampleGroup.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.java._trace new file mode 100644 index 00000000..7e322646 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.xtendbin new file mode 100644 index 00000000..14cb7ae5 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.MultiplexParticipationCoefficientMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.java._trace new file mode 100644 index 00000000..b6cf817f Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.xtendbin new file mode 100644 index 00000000..074a8167 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeActivityMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.java._trace new file mode 100644 index 00000000..fbf9468d Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.xtendbin new file mode 100644 index 00000000..38aa72c1 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.NodeTypeMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.java._trace new file mode 100644 index 00000000..bfec1ccd Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.xtendbin new file mode 100644 index 00000000..eeed0bd4 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.OutDegreeMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.java._trace new file mode 100644 index 00000000..5cc35d7c Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.xtendbin new file mode 100644 index 00000000..3d9fe56e Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedClusteringCoefficientMetric.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.java._trace new file mode 100644 index 00000000..0b3e6e4f Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.xtendbin new file mode 100644 index 00000000..5f61f506 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/.TypedOutDegree.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/EdgeTypeMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/EdgeTypeMetric.java new file mode 100644 index 00000000..58dea567 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/EdgeTypeMetric.java @@ -0,0 +1,65 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import com.google.common.collect.Multimap; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.Set; +import java.util.function.BiConsumer; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.Functions.Function2; +import org.eclipse.xtext.xbase.lib.IterableExtensions; + +@SuppressWarnings("all") +public class EdgeTypeMetric extends Metric { + @Override + public String[][] evaluate(final GraphStatistic g) { + Object _evaluateSamples = this.evaluateSamples(g); + HashMap map = ((HashMap) _evaluateSamples); + ArrayList output = new ArrayList(); + output.add(((String[])Conversions.unwrapArray(CollectionLiterals.newArrayList("Edge Type"), String.class))); + Set keys = map.keySet(); + ArrayList values = CollectionLiterals.newArrayList(); + for (final String key : keys) { + Double _get = map.get(key); + String _plus = (_get + ""); + values.add(_plus); + } + final Set _converted_keys = (Set)keys; + output.add(((String[])Conversions.unwrapArray(_converted_keys, String.class))); + final ArrayList _converted_values = (ArrayList)values; + output.add(((String[])Conversions.unwrapArray(_converted_values, String.class))); + return ((String[][])Conversions.unwrapArray(output, String[].class)); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + final HashMap map = new HashMap(); + HashMap> outgoingEdges = g.getOutgoingEdges(); + final Function2, Integer> _function = (Integer r, Multimap t) -> { + final Function2, Integer> _function_1 = (Integer r1, Collection t1) -> { + int _size = t1.size(); + return Integer.valueOf(((r1).intValue() + _size)); + }; + Integer _fold = IterableExtensions., Integer>fold(t.asMap().values(), Integer.valueOf(0), _function_1); + return Integer.valueOf(((r).intValue() + (_fold).intValue())); + }; + Integer _fold = IterableExtensions., Integer>fold(outgoingEdges.values(), Integer.valueOf(0), _function); + final double edgeCount = ((double) (int) _fold); + final BiConsumer> _function_1 = (String k, Multimap v) -> { + final Function2, Integer> _function_2 = (Integer r, Collection t) -> { + int _size = t.size(); + return Integer.valueOf(((r).intValue() + _size)); + }; + Integer _fold_1 = IterableExtensions., Integer>fold(v.asMap().values(), Integer.valueOf(0), _function_2); + double value = ((_fold_1).intValue() / edgeCount); + map.put(k, Double.valueOf(value)); + }; + outgoingEdges.forEach(_function_1); + return map; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/Metric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/Metric.java new file mode 100644 index 00000000..be6353a2 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/Metric.java @@ -0,0 +1,10 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; + +@SuppressWarnings("all") +public abstract class Metric { + public abstract String[][] evaluate(final GraphStatistic g); + + public abstract Object evaluateSamples(final GraphStatistic g); +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MetricSampleGroup.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MetricSampleGroup.java new file mode 100644 index 00000000..6db61944 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MetricSampleGroup.java @@ -0,0 +1,19 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import java.util.HashMap; +import java.util.List; + +@SuppressWarnings("all") +public class MetricSampleGroup { + public List mpcSamples; + + public List naSamples; + + public List outDegreeSamples; + + public HashMap> typedOutDegreeSamples; + + public HashMap nodeTypeSamples; + + public HashMap edgeTypeSamples; +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MultiplexParticipationCoefficientMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MultiplexParticipationCoefficientMetric.java new file mode 100644 index 00000000..660a5978 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/MultiplexParticipationCoefficientMetric.java @@ -0,0 +1,59 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import java.text.DecimalFormat; +import java.util.ArrayList; +import java.util.List; +import java.util.function.Consumer; +import org.eclipse.emf.ecore.EObject; + +@SuppressWarnings("all") +public class MultiplexParticipationCoefficientMetric extends Metric { + public final static String countName = "MPCCount"; + + public final static String valueName = "MPCValue"; + + private final DecimalFormat formatter = new DecimalFormat("#0.00000"); + + @Override + public String[][] evaluate(final GraphStatistic g) { + throw new Error("Unresolved compilation problems:" + + "\nInvalid number of arguments. The method newArrayOfSize(int) is not applicable for the arguments (int,int)"); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + final ArrayList samples = new ArrayList(); + final int typeCounts = g.getAllTypes().size(); + final Consumer _function = (EObject it) -> { + samples.add(Double.valueOf(this.calculateMPC(it, g, typeCounts))); + }; + g.getAllNodes().forEach(_function); + return samples; + } + + public double calculateMPC(final EObject n, final GraphStatistic g, final int typeCounts) { + int _outDegree = g.outDegree(n); + int _inDegree = g.inDegree(n); + final int edgeCounts = (_outDegree + _inDegree); + double coef = 0.0; + List _allTypes = g.getAllTypes(); + for (final String type : _allTypes) { + { + int _dimentionalDegree = g.dimentionalDegree(n, type); + final double degree = ((double) _dimentionalDegree); + double _coef = coef; + double _pow = Math.pow((degree / edgeCounts), 2); + coef = (_coef + _pow); + } + } + coef = (1 - coef); + coef = ((coef * typeCounts) / (typeCounts - 1)); + boolean _isNaN = Double.isNaN(coef); + if (_isNaN) { + coef = 0; + } + return Double.parseDouble(this.formatter.format(coef)); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeActivityMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeActivityMetric.java new file mode 100644 index 00000000..12bec460 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeActivityMetric.java @@ -0,0 +1,31 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import java.util.ArrayList; +import java.util.function.Consumer; +import org.eclipse.emf.ecore.EObject; + +@SuppressWarnings("all") +public class NodeActivityMetric extends Metric { + public final static String countName = "NACount"; + + public final static String valueName = "NAValue"; + + @Override + public String[][] evaluate(final GraphStatistic g) { + throw new Error("Unresolved compilation problems:" + + "\nInvalid number of arguments. The method newArrayOfSize(int) is not applicable for the arguments (int,int)"); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + final ArrayList samples = new ArrayList(); + final Consumer _function = (EObject it) -> { + int _numOfEdgeTypes = g.numOfEdgeTypes(it); + samples.add(Double.valueOf(((double) _numOfEdgeTypes))); + }; + g.getAllNodes().forEach(_function); + return samples; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeTypeMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeTypeMetric.java new file mode 100644 index 00000000..75c2cfef --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/NodeTypeMetric.java @@ -0,0 +1,54 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; +import org.eclipse.xtext.xbase.lib.Conversions; + +@SuppressWarnings("all") +public class NodeTypeMetric extends Metric { + @Override + public String[][] evaluate(final GraphStatistic g) { + Object _evaluateSamples = this.evaluateSamples(g); + HashMap map = ((HashMap) _evaluateSamples); + ArrayList output = new ArrayList(); + output.add(((String[])Conversions.unwrapArray(CollectionLiterals.newArrayList("Node Type"), String.class))); + Set keys = map.keySet(); + ArrayList values = CollectionLiterals.newArrayList(); + for (final String key : keys) { + Double _get = map.get(key); + String _plus = (_get + ""); + values.add(_plus); + } + final Set _converted_keys = (Set)keys; + output.add(((String[])Conversions.unwrapArray(_converted_keys, String.class))); + final ArrayList _converted_values = (ArrayList)values; + output.add(((String[])Conversions.unwrapArray(_converted_values, String.class))); + return ((String[][])Conversions.unwrapArray(output, String[].class)); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + HashMap map = new HashMap(); + List nodes = g.getAllNodes(); + int _size = nodes.size(); + double single = (1.0 / _size); + Map> nodeToType = g.getNodeToTypesMap(); + for (final EObject node : nodes) { + Set _get = nodeToType.get(node); + for (final String cl : _get) { + { + Double value = map.getOrDefault(cl, Double.valueOf(0.0)); + map.put(cl, Double.valueOf(((value).doubleValue() + single))); + } + } + } + return map; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/OutDegreeMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/OutDegreeMetric.java new file mode 100644 index 00000000..67e4be0d --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/OutDegreeMetric.java @@ -0,0 +1,31 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import java.util.ArrayList; +import java.util.function.Consumer; +import org.eclipse.emf.ecore.EObject; + +@SuppressWarnings("all") +public class OutDegreeMetric extends Metric { + public final static String countName = "OutDegreeCount"; + + public final static String valueName = "OutDegreeValue"; + + @Override + public String[][] evaluate(final GraphStatistic g) { + throw new Error("Unresolved compilation problems:" + + "\nInvalid number of arguments. The method newArrayOfSize(int) is not applicable for the arguments (int,int)"); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + final ArrayList samples = new ArrayList(); + final Consumer _function = (EObject it) -> { + int _outDegree = g.outDegree(it); + samples.add(Double.valueOf(((double) _outDegree))); + }; + g.getAllNodes().forEach(_function); + return samples; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedClusteringCoefficientMetric.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedClusteringCoefficientMetric.java new file mode 100644 index 00000000..042af5c3 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedClusteringCoefficientMetric.java @@ -0,0 +1,74 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import com.google.common.base.Objects; +import java.text.DecimalFormat; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashSet; +import java.util.List; +import java.util.function.Consumer; +import org.eclipse.emf.ecore.EObject; + +@SuppressWarnings("all") +public class TypedClusteringCoefficientMetric extends Metric { + public final static String countName = "TCCCount"; + + public final static String valueName = "TCCValue"; + + private final DecimalFormat formatter = new DecimalFormat("#0.00000"); + + @Override + public String[][] evaluate(final GraphStatistic g) { + throw new Error("Unresolved compilation problems:" + + "\nInvalid number of arguments. The method newArrayOfSize(int) is not applicable for the arguments (int,int)"); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + final ArrayList samples = new ArrayList(); + final Consumer _function = (EObject it) -> { + samples.add(Double.valueOf(this.calculateTCC1(it, g))); + }; + g.getAllNodes().forEach(_function); + return samples; + } + + /** + * Compute TCC1 metric for node n + */ + public double calculateTCC1(final EObject n, final GraphStatistic g) { + int wedges = 0; + int triangles = 0; + List _allTypes = g.getAllTypes(); + for (final String type1 : _allTypes) { + { + Collection _get = g.getOutgoingEdges().get(type1).get(n); + final HashSet typed1RelatedOfN = new HashSet(_get); + Collection _get_1 = g.incomingEdges().get(type1).get(n); + final HashSet type1EdgeSourceNodesOfN = new HashSet(_get_1); + typed1RelatedOfN.addAll(type1EdgeSourceNodesOfN); + final int d = typed1RelatedOfN.size(); + int _wedges = wedges; + wedges = (_wedges + (d * (d - 1))); + for (final EObject n1 : typed1RelatedOfN) { + for (final EObject n2 : typed1RelatedOfN) { + List _allTypes_1 = g.getAllTypes(); + for (final String type2 : _allTypes_1) { + if (((!Objects.equal(type1, type2)) && (g.getOutgoingEdges().get(type2).containsEntry(n1, n2) || + g.getOutgoingEdges().get(type2).containsEntry(n2, n1)))) { + triangles++; + } + } + } + } + } + } + if ((wedges == 0.0)) { + return 0.0; + } else { + return (((double) triangles) / wedges); + } + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedOutDegree.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedOutDegree.java new file mode 100644 index 00000000..dce80389 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/metrics/TypedOutDegree.java @@ -0,0 +1,73 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.graph.GraphStatistic; +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.metrics.Metric; +import com.google.common.collect.Multimap; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; +import org.eclipse.xtext.xbase.lib.Conversions; + +@SuppressWarnings("all") +public class TypedOutDegree extends Metric { + private HashMap> calculateMetric(final GraphStatistic g) { + HashMap> outgoingEdges = g.getOutgoingEdges(); + HashMap> metric = new HashMap>(); + Map> nodeToTypes = g.getNodeToTypesMap(); + Set _keySet = outgoingEdges.keySet(); + for (final String edgeType : _keySet) { + Set _keySet_1 = outgoingEdges.get(edgeType).keySet(); + for (final EObject node : _keySet_1) { + { + Set classes = nodeToTypes.get(node); + for (final String cl : classes) { + { + String key = ((cl + " ") + edgeType); + List typeCount = metric.get(key); + if ((typeCount == null)) { + ArrayList _arrayList = new ArrayList(); + typeCount = _arrayList; + metric.put(key, typeCount); + } + typeCount.add(Integer.valueOf(outgoingEdges.get(edgeType).get(node).size())); + } + } + } + } + } + return metric; + } + + @Override + public String[][] evaluate(final GraphStatistic g) { + HashMap> metric = this.calculateMetric(g); + ArrayList output = new ArrayList(); + output.add(((String[])Conversions.unwrapArray(CollectionLiterals.newArrayList("Typed Out Degree"), String.class))); + Set _keySet = metric.keySet(); + for (final String key : _keySet) { + { + List samples = metric.get(key); + int _size = samples.size(); + int _plus = (_size + 1); + String[] outputForOnePair = new String[_plus]; + outputForOnePair[0] = key; + for (int i = 0; (i < samples.size()); i++) { + Integer _get = samples.get(i); + String _plus_1 = (_get + ""); + outputForOnePair[(i + 1)] = _plus_1; + } + output.add(outputForOnePair); + } + } + return ((String[][])Conversions.unwrapArray(output, String[].class)); + } + + @Override + public Object evaluateSamples(final GraphStatistic g) { + return this.calculateMetric(g); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.java._trace new file mode 100644 index 00000000..906a396a Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.xtendbin new file mode 100644 index 00000000..06925afd Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/.LinearModel.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/LinearModel.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/LinearModel.java new file mode 100644 index 00000000..6a7f8497 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/predictor/LinearModel.java @@ -0,0 +1,90 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.predictor; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.distance.StateData; +import com.google.common.base.Objects; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +@SuppressWarnings("all") +public class LinearModel { + private double ridge; + + private Map stateAndHistory; + + private List samples; + + public LinearModel(final double ridge) { + this.ridge = ridge; + HashMap _hashMap = new HashMap(); + this.stateAndHistory = _hashMap; + ArrayList _arrayList = new ArrayList(); + this.samples = _arrayList; + } + + /** + * reset the current train data for regression to a new trajectory + * @param state: the last state of the trajectory + */ + public void resetRegression(final Object state) { + this.samples.clear(); + boolean _containsKey = this.stateAndHistory.containsKey(state); + if (_containsKey) { + StateData data = this.stateAndHistory.get(state); + Object curState = state; + this.samples.add(data); + while ((this.stateAndHistory.containsKey(data.getLastState()) && (!Objects.equal(data.getLastState(), curState)))) { + { + curState = data.getLastState(); + data = this.stateAndHistory.get(data.getLastState()); + this.samples.add(data); + } + } + } + } + + /** + * Add a new data point to the current training set + * @param state: the state on which the new data point is calculated + * @param features: the set of feature value(x) + * @param value: the value of the state (y) + * @param lastState: the state which transformed to current state, used to record the trajectory + */ + public boolean feedData(final Object state, final double[] features, final double value, final Object lastState) { + boolean _xblockexpression = false; + { + StateData data = new StateData(features, value, lastState); + this.stateAndHistory.put(state, data); + _xblockexpression = this.samples.add(data); + } + return _xblockexpression; + } + + /** + * get prediction for next state, without storing the data point into the training set + * @param features: the feature values of current state + * @param value: the value of the current state + * @param: featuresToPredict: the features of the state wanted to be predected + * @return the value of the state to be predicted + */ + public double getPredictionForNextDataSample(final double[] features, final double value, final double[] featuresToPredict) { + throw new Error("Unresolved compilation problems:" + + "\nMatrix cannot be resolved." + + "\nMatrix cannot be resolved." + + "\nLinearRegression cannot be resolved." + + "\ncoefficients cannot be resolved"); + } + + private double predict(final double[] parameters, final double[] featuresToPredict) { + double result = parameters[0]; + for (int i = 0; (i < featuresToPredict.length); i++) { + double _result = result; + double _get = parameters[i]; + double _get_1 = featuresToPredict[i]; + double _multiply = (_get * _get_1); + result = (_result + _multiply); + } + return result; + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.java._trace new file mode 100644 index 00000000..1756f86a Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.xtendbin new file mode 100644 index 00000000..708955a4 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ConstraintCollection.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.java._trace b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.java._trace new file mode 100644 index 00000000..0cb68ca8 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.java._trace differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.xtendbin b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.xtendbin new file mode 100644 index 00000000..63721784 Binary files /dev/null and b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/.ViolationCheck.xtendbin differ diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ConstraintCollection.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ConstraintCollection.java new file mode 100644 index 00000000..92c69bea --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ConstraintCollection.java @@ -0,0 +1,79 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.validation; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import org.eclipse.emf.common.notify.Notifier; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; +import org.eclipse.xtext.xbase.lib.InputOutput; + +@SuppressWarnings("all") +public class ConstraintCollection { + private final /* ArrayList */Object constraints /* Skipped initializer because of errors */; + + private /* BaseGeneratedPatternGroup */Object patterns; + + private List resources = new ArrayList(); + + public ConstraintCollection(final /* List */Object constraints, final List uris, final /* BaseGeneratedPatternGroup */Object patterns) { + throw new Error("Unresolved compilation problems:" + + "\nThe field ConstraintCollection.constraints refers to the missing type IConstraintSpecification" + + "\nThe field ConstraintCollection.patterns refers to the missing type BaseGeneratedPatternGroup"); + } + + public ConstraintCollection(final /* List */Object constraints, final /* BaseGeneratedPatternGroup */Object patterns) { + throw new Error("Unresolved compilation problems:" + + "\nThe field ConstraintCollection.constraints refers to the missing type IConstraintSpecification" + + "\nThe field ConstraintCollection.patterns refers to the missing type BaseGeneratedPatternGroup"); + } + + public boolean addModel(final Notifier n) { + return this.resources.add(n); + } + + public String setURIs(final List uris) { + String _xblockexpression = null; + { + final ResourceSetImpl resSet = new ResourceSetImpl(); + for (final String uri : uris) { + { + Resource resource = resSet.getResource(URI.createURI(uri), true); + this.resources.add(resource); + } + } + _xblockexpression = InputOutput.println("reading model finished"); + } + return _xblockexpression; + } + + public List calculateViolations() { + throw new Error("Unresolved compilation problems:" + + "\nThe method or field querySpecification is undefined for the type Object" + + "\nThe method initEngine(Notifier) from the type ConstraintCollection refers to the missing type Object" + + "\nThe field ConstraintCollection.constraints refers to the missing type IConstraintSpecification" + + "\ngetMatcher cannot be resolved" + + "\ncountMatches cannot be resolved"); + } + + public ArrayList> calculateViolationMaps() { + throw new Error("Unresolved compilation problems:" + + "\nThe method or field querySpecification is undefined for the type Object" + + "\nThe method or field querySpecification is undefined for the type Object" + + "\nThe method initEngine(Notifier) from the type ConstraintCollection refers to the missing type Object" + + "\nThe field ConstraintCollection.constraints refers to the missing type IConstraintSpecification" + + "\ngetMatcher cannot be resolved" + + "\ncountMatches cannot be resolved" + + "\nsimpleName cannot be resolved"); + } + + private Object initEngine(final Notifier r) { + throw new Error("Unresolved compilation problems:" + + "\nThe method or field ViatraQueryEngine is undefined" + + "\nEMFScope cannot be resolved." + + "\nThe field ConstraintCollection.patterns refers to the missing type BaseGeneratedPatternGroup" + + "\non cannot be resolved" + + "\nprepare cannot be resolved"); + } +} diff --git a/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ViolationCheck.java b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ViolationCheck.java new file mode 100644 index 00000000..7eb3ec77 --- /dev/null +++ b/Metrics/Metrics-Calculation/ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculator/validation/ViolationCheck.java @@ -0,0 +1,34 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.validation; + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.calculator.app.Domain; +import java.util.ArrayList; +import java.util.Map; +import org.eclipse.emf.ecore.EObject; + +@SuppressWarnings("all") +public class ViolationCheck { + /** + * Return the total number of violations + */ + public static int calculateViolationCounts(final EObject root, final Domain d) { + throw new Error("Unresolved compilation problems:" + + "\nThe method loadConstraints(String) from the type ViolationCheck refers to the missing type IConstraintSpecification" + + "\nThe constructor ConstraintCollection(List, BaseGeneratedPatternGroup) refers to the missing type IConstraintSpecification"); + } + + /** + * return a map contain the count for each type of violation + */ + public static Map violationMaps(final EObject root) { + throw new Error("Unresolved compilation problems:" + + "\nThe method loadConstraints(String) from the type ViolationCheck refers to the missing type IConstraintSpecification" + + "\nThe constructor ConstraintCollection(List, BaseGeneratedPatternGroup) refers to the missing type IConstraintSpecification"); + } + + public static /* ArrayList */Object loadConstraints(final String packageName) { + throw new Error("Unresolved compilation problems:" + + "\nIConstraintSpecification cannot be resolved to a type." + + "\nIConstraintSpecification cannot be resolved to a type." + + "\nThe method or field IConstraintSpecification is undefined"); + } +} diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace new file mode 100644 index 00000000..5ab4c0fb Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace new file mode 100644 index 00000000..605b2480 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace new file mode 100644 index 00000000..16ded94b Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace new file mode 100644 index 00000000..bd23cb35 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace new file mode 100644 index 00000000..71d80e38 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace new file mode 100644 index 00000000..b423786d Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace new file mode 100644 index 00000000..cce23aec Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace new file mode 100644 index 00000000..e46f9600 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace new file mode 100644 index 00000000..9ce2edb2 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace new file mode 100644 index 00000000..cdfcef6e Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQROSZ.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQROSZ.java._trace new file mode 100644 index 00000000..787e63c7 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQROSZ.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace new file mode 100644 index 00000000..0c8cc5d0 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.xtendbin new file mode 100644 index 00000000..e826d04b Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CalculationsNA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CalculationsNA.java._trace new file mode 100644 index 00000000..76aa59b0 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CalculationsNA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace new file mode 100644 index 00000000..edd88562 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace new file mode 100644 index 00000000..fc92b1d3 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace new file mode 100644 index 00000000..306c1361 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.gitignore b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.gitignore new file mode 100644 index 00000000..b5da4aad --- /dev/null +++ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.gitignore @@ -0,0 +1 @@ +/.CSERposterSample.java._trace diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.java._trace new file mode 100644 index 00000000..08d35ce0 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.CSERposterSample.java._trace differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index ec6f2b5e..d5047e35 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 142268cc..0fd042a4 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 83816584..ac318322 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index ef0e981f..7710f730 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 7ec5c9c6..310033e1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 0efc1f64..ede1ce7d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 35e9ce12..78fbafbe 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 90005e11..df5e592d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 8e4e1612..4a78ac13 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index cc1180a8..9d31c774 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index 8a562c45..e925e4e1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index fb30c8b3..42ffb9cd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index bc26963e..3f95e60a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index d83995ca..9bb44e75 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/putVampireHere b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/putVampireHere new file mode 100644 index 00000000..cc0bca68 --- /dev/null +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/putVampireHere @@ -0,0 +1,2 @@ +put the Vampire executeable in this folder. +rename it to "vampire.exe" diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/vampire.exe b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/vampire.exe new file mode 100644 index 00000000..51b44f82 Binary files /dev/null and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/lib/vampire.exe differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend index 1d56892e..6bb49080 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend @@ -27,7 +27,12 @@ class VampireSolver extends LogicReasoner { val Vampire2LogicMapper backwardMapper = new Vampire2LogicMapper val VampireHandler handler = new VampireHandler - val fileName = "vampireProblem.tptp" + var fileName = "problem.tptp" + + def solve(LogicProblem problem, LogicSolverConfiguration config, ReasonerWorkspace workspace, String location) { + fileName = location + fileName + solve(problem, config, workspace) + } override solve(LogicProblem problem, LogicSolverConfiguration config, ReasonerWorkspace workspace) throws LogicReasonerException { @@ -54,26 +59,21 @@ class VampireSolver extends LogicReasoner { // Result as String val transformationTime = System.currentTimeMillis - transformationStart // Finish: Logic -> Vampire mapping - /* - * // Start: Solving Alloy problem - * val solverStart = System.currentTimeMillis - * //Calling Solver (Currently Manually) - * val result2 = handler.callSolver(vampireProblem,workspace,vampireConfig,vampireCode) - * // val result2 = null - * //TODO - * //Backwards Mapper - * val logicResult = backwardMapper.transformOutput(problem,config.solutionScope.numberOfRequiredSolution,result2,forwardTrace,transformationTime) - * - * val solverFinish = System.currentTimeMillis-solverStart - * // Finish: Solving Alloy problem - * - * if(vampireConfig.writeToFile) workspace.deactivateModel(fileName) - * - * return logicResult - * - /*/ - return null // for now - // */ + // Start: Solving .tptp problem + val solverStart = System.currentTimeMillis + // Calling Solver (Currently Manually) + val result2 = handler.callSolver(vampireProblem, workspace, vampireConfig) + // val result2 = null + val solvingTime = System.currentTimeMillis - solverStart + // TODO +// val backTransformationStart = System.currentTimeMillis +// // Backwards Mapper +// val logicResult = backwardMapper.transformOutput(problem, config.solutionScope.numberOfRequiredSolution, +// result2, forwardTrace, transformationTime) +// +// val backTransformationTime = System.currentTimeMillis - backTransformationStart + // Finish: Solving Alloy problem + return null } def asConfig(LogicSolverConfiguration configuration) { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.xtend index aefa1a7e..274396ee 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.xtend @@ -1,21 +1,14 @@ package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireBackendSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel -import com.google.common.util.concurrent.SimpleTimeLimiter -import com.google.common.util.concurrent.UncheckedTimeoutException -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicSolverConfiguration import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace -import java.util.ArrayList -import java.util.HashMap -import java.util.LinkedList +import java.io.BufferedReader +import java.io.InputStreamReader import java.util.List -import java.util.Map -import java.util.concurrent.Callable -import java.util.concurrent.TimeUnit -import org.eclipse.emf.common.command.Command +import org.eclipse.emf.ecore.resource.Resource import org.eclipse.xtend.lib.annotations.Data +import ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguageFactoryImpl class VampireSolverException extends Exception{ new(String s) { super(s) } @@ -39,7 +32,62 @@ class VampireHandler { //val fileName = "problem.als" - public def callSolver(VampireModel problem, ReasonerWorkspace workspace, VampireSolverConfiguration configuration,String vampireCode) { + public def callSolver(VampireModel problem, ReasonerWorkspace workspace, VampireSolverConfiguration configuration) { + + val CMD = "cmd /c " + val VAMPDIR = "..\\..\\Solvers\\Vampire-Solver\\ca.mcgill.ecse.dslreasoner.vampire.reasoner\\lib\\" + val VAMPNAME = "vampire.exe" + val TEMPNAME = "TEMP.tptp" + val OPTION = " --mode casc_sat " + val SOLNNAME = "solution.tptp" + val PATH = "C:/cygwin64/bin" + + val wsURI = workspace.workspaceURI + val tempLoc = wsURI + TEMPNAME + val solnLoc = wsURI + SOLNNAME + " " + val vampLoc = VAMPDIR + VAMPNAME + + + //1. create temp file for vampire problem + var tempURI = workspace.writeModel(problem, TEMPNAME).toFileString + + //2. run command and save to + //need to have cygwin downloaded + + + + + val p = Runtime.runtime.exec(CMD + vampLoc + OPTION + tempLoc + " > " + solnLoc, newArrayList("Path=" + PATH)) + //2.1 determine time left + p.waitFor + + //2.2 store output into local variable + val BufferedReader reader = new BufferedReader(new InputStreamReader(p.getInputStream())); + val List output = newArrayList + + var line = ""; + while ((line = reader.readLine())!= null) { + output.add(line + "\n"); + } + +// println(output.toString()) + + //4. delete temp file + workspace.getFile(TEMPNAME).delete + + //5. determine and return whether or not finite model was found + + //6. save solution as a .tptp model + Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap().put("*", new VampireLanguageFactoryImpl) + workspace.readModel(VampireModel, SOLNNAME).eResource.contents + + + + + + + + /* //Prepare val warnings = new LinkedList diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index 43712734..b9600616 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index b395b0c5..a7942958 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java index d9d75887..410b47ed 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java @@ -20,7 +20,10 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult; import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace; import java.util.List; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EObject; import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; @SuppressWarnings("all") public class VampireSolver extends LogicReasoner { @@ -36,7 +39,20 @@ public class VampireSolver extends LogicReasoner { private final VampireHandler handler = new VampireHandler(); - private final String fileName = "vampireProblem.tptp"; + private String fileName = "problem.tptp"; + + public LogicResult solve(final LogicProblem problem, final LogicSolverConfiguration config, final ReasonerWorkspace workspace, final String location) { + try { + LogicResult _xblockexpression = null; + { + this.fileName = (location + this.fileName); + _xblockexpression = this.solve(problem, config, workspace); + } + return _xblockexpression; + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } + } @Override public LogicResult solve(final LogicProblem problem, final LogicSolverConfiguration config, final ReasonerWorkspace workspace) throws LogicReasonerException { @@ -55,6 +71,10 @@ public class VampireSolver extends LogicReasoner { } long _currentTimeMillis = System.currentTimeMillis(); final long transformationTime = (_currentTimeMillis - transformationStart); + final long solverStart = System.currentTimeMillis(); + final EList result2 = this.handler.callSolver(vampireProblem, workspace, vampireConfig); + long _currentTimeMillis_1 = System.currentTimeMillis(); + final long solvingTime = (_currentTimeMillis_1 - solverStart); return null; } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 3e571f5b..487f9569 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 6c116851..bd61b874 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 7ba8f303..2e58cecd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index ad62b1f9..1b894303 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 150ac835..4b7fd4bf 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index c181e53c..6626adf4 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 68d8cfb3..339baea9 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index 1bef8bd1..868f30e7 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index 9c4555e0..f8b35528 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 7bd6797c..08ffcb3b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 6a10d85a..ffd37ea3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 26460f68..9ddc7bd0 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java index 1cac2633..1479e6b7 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java @@ -2,11 +2,60 @@ package ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel; +import ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguageFactoryImpl; +import com.google.common.base.Objects; import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace; +import java.io.BufferedReader; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.util.List; +import java.util.Map; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.xtext.xbase.lib.CollectionLiterals; +import org.eclipse.xtext.xbase.lib.Conversions; +import org.eclipse.xtext.xbase.lib.Exceptions; @SuppressWarnings("all") public class VampireHandler { - public Object callSolver(final VampireModel problem, final ReasonerWorkspace workspace, final VampireSolverConfiguration configuration, final String vampireCode) { - return null; + public EList callSolver(final VampireModel problem, final ReasonerWorkspace workspace, final VampireSolverConfiguration configuration) { + try { + EList _xblockexpression = null; + { + final String CMD = "cmd /c "; + final String VAMPDIR = "..\\..\\Solvers\\Vampire-Solver\\ca.mcgill.ecse.dslreasoner.vampire.reasoner\\lib\\"; + final String VAMPNAME = "vampire.exe"; + final String TEMPNAME = "TEMP.tptp"; + final String OPTION = " --mode casc_sat "; + final String SOLNNAME = "solution.tptp"; + final String PATH = "C:/cygwin64/bin"; + final URI wsURI = workspace.getWorkspaceURI(); + final String tempLoc = (wsURI + TEMPNAME); + String _plus = (wsURI + SOLNNAME); + final String solnLoc = (_plus + " "); + final String vampLoc = (VAMPDIR + VAMPNAME); + String tempURI = workspace.writeModel(problem, TEMPNAME).toFileString(); + final Process p = Runtime.getRuntime().exec((((((CMD + vampLoc) + OPTION) + tempLoc) + " > ") + solnLoc), ((String[])Conversions.unwrapArray(CollectionLiterals.newArrayList(("Path=" + PATH)), String.class))); + p.waitFor(); + InputStream _inputStream = p.getInputStream(); + InputStreamReader _inputStreamReader = new InputStreamReader(_inputStream); + final BufferedReader reader = new BufferedReader(_inputStreamReader); + final List output = CollectionLiterals.newArrayList(); + String line = ""; + while ((!Objects.equal((line = reader.readLine()), null))) { + output.add((line + "\n")); + } + workspace.getFile(TEMPNAME).delete(); + Map _extensionToFactoryMap = Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap(); + VampireLanguageFactoryImpl _vampireLanguageFactoryImpl = new VampireLanguageFactoryImpl(); + _extensionToFactoryMap.put("*", _vampireLanguageFactoryImpl); + _xblockexpression = workspace.readModel(VampireModel.class, SOLNNAME).eResource().getContents(); + } + return _xblockexpression; + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore index bbd4af35..8952cfb5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/filesystem.ecore @@ -10,7 +10,7 @@ -
    +
    diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath index f03a6d83..3f0838b6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/.classpath @@ -5,6 +5,5 @@ - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF index 8b69d9a8..2ea274a4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF @@ -3,11 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: Test Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.test;singleton:=true Bundle-Version: 1.0.0.qualifier -Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries, - ca.mcgill.ecse.dslreasoner.vampire.test.queries.ecore, - ca.mcgill.ecse.dslreasoner.vampire.test.queries.fam, - ca.mcgill.ecse.dslreasoner.vampire.test.queries.filesystem, - ca.mcgill.ecse.dslreasoner.vampire.test.queries.yakindu +Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, org.eclipse.emf.ecore, org.eclipse.viatra.query.runtime.rete, diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/build.properties b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/build.properties index efae4b07..aed85a48 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/build.properties +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/build.properties @@ -1,6 +1,5 @@ bin.includes = META-INF/,\ . source.. = src/,\ - src-gen/,\ src-gen/ output.. = bin/ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index 33dc7485..b0735f37 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -1,238 +1,9 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend index 35b76350..70ded02d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend @@ -50,7 +50,7 @@ class EcoreTest { it.documentationLevel = DocumentationLevel::FULL ] - solution = reasoner.solve(logicProblem, vampireConfig, workspace) + solution = reasoner.solve(logicProblem, vampireConfig, workspace, "ECO") println("Problem solved") 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 3c24abf9..4625bfbf 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 @@ -56,7 +56,7 @@ class FAMTest { //Start Time var startTime = System.currentTimeMillis - var LogicReasoner reasoner + var VampireSolver reasoner // * reasoner = new VampireSolver diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend index ba7ff028..2495ab77 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.xtend @@ -1,13 +1,13 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage -import ca.mcgill.ecse.dslreasoner.vampire.queries.FileSystemPatterns import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic @@ -15,7 +15,6 @@ import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace import java.util.HashMap import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl -import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.* class FileSystemTest { def static void main(String[] args) { @@ -38,7 +37,7 @@ class FileSystemTest { val metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE) val partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi") - val queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance) +// val queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance) println("DSL loaded") @@ -53,7 +52,7 @@ class FileSystemTest { // Start Time var startTime = System.currentTimeMillis - var LogicReasoner reasoner + var VampireSolver reasoner // * reasoner = new VampireSolver @@ -87,7 +86,7 @@ class FileSystemTest { it.uniquenessDuplicates = false ] - var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) + var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace, "FS") /*/ * diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend index 76ac727a..fb1bdb59 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend @@ -53,7 +53,7 @@ class YakinduTest { // Start Time var startTime = System.currentTimeMillis - var LogicReasoner reasoner + var VampireSolver reasoner // * reasoner = new VampireSolver @@ -85,7 +85,7 @@ class YakinduTest { it.uniquenessDuplicates = false ] - var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) + var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace, "YAK") /*/ * diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/vampire.exe b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/vampire.exe new file mode 100644 index 00000000..51b44f82 Binary files /dev/null and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/vampire.exe differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 890872ea..1bf1d5cb 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 8d7947e1..43e916e8 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index 91741fb2..8da3064a 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index e1fba1c4..241e8efd 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 22b54964..e6e6bbf4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java index 7019f162..01503783 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java @@ -1,68 +1,9 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; -import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; -import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; -import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; -import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; -import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; -import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; -import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; -import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; -import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.xtend2.lib.StringConcatenation; -import org.eclipse.xtext.xbase.lib.Exceptions; -import org.eclipse.xtext.xbase.lib.InputOutput; -import org.eclipse.xtext.xbase.lib.ObjectExtensions; -import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; - @SuppressWarnings("all") public class EcoreTest { public static void main(final String[] args) { - try { - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FEcoreTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); - final Object queries = null; - InputOutput.println("DSL loaded"); - final Ecore2Logic ecore2Logic = new Ecore2Logic(); - final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); - final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); - final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); - Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); - final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); - final TracedOutput modelExtensionProblem = instanceModel2Logic.transform(modelGenerationProblem, partialModel); - final LogicProblem logicProblem = modelGenerationProblem.getOutput(); - InputOutput.println("Problem created"); - LogicResult solution = null; - LogicReasoner reasoner = null; - VampireSolver _vampireSolver = new VampireSolver(); - reasoner = _vampireSolver; - VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); - final Procedure1 _function = (VampireSolverConfiguration it) -> { - it.documentationLevel = DocumentationLevel.FULL; - }; - final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); - solution = reasoner.solve(logicProblem, vampireConfig, workspace); - InputOutput.println("Problem solved"); - } catch (Throwable _e) { - throw Exceptions.sneakyThrow(_e); - } + throw new Error("Unresolved compilation problems:" + + "\nInvalid number of arguments. The method solve(LogicProblem, LogicSolverConfiguration, ReasonerWorkspace) is not applicable for the arguments (LogicProblem,VampireSolverConfiguration,FileSystemWorkspace,String)"); } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index ddbe05d7..ac49a9aa 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -12,7 +12,6 @@ import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; @@ -62,7 +61,7 @@ public class FAMTest { workspace.writeModel(problem, "Fam.logicproblem"); InputOutput.println("Problem created"); long startTime = System.currentTimeMillis(); - LogicReasoner reasoner = null; + VampireSolver reasoner = null; VampireSolver _vampireSolver = new VampireSolver(); reasoner = _vampireSolver; final HashMap classMapMin = new HashMap(); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java index 4a971fd6..7579bd98 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FileSystemTest.java @@ -4,7 +4,6 @@ import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.Dir; import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.File; import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; -import ca.mcgill.ecse.dslreasoner.vampire.queries.FileSystemPatterns; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; @@ -12,13 +11,11 @@ import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Type; import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; import java.util.HashMap; @@ -28,7 +25,6 @@ import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.resource.Resource; import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; -import org.eclipse.xtext.xbase.lib.Exceptions; import org.eclipse.xtext.xbase.lib.InputOutput; import org.eclipse.xtext.xbase.lib.ObjectExtensions; import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @@ -36,75 +32,70 @@ import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class FileSystemTest { public static void main(final String[] args) { - try { - final Ecore2Logic ecore2Logic = new Ecore2Logic(); - final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); - final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); - StringConcatenation _builder = new StringConcatenation(); - _builder.append("initialModels/"); - final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); - StringConcatenation _builder_1 = new StringConcatenation(); - _builder_1.append("output/FileSystemTest/"); - final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); - workspace.initAndClear(); - final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; - final Map map = reg.getExtensionToFactoryMap(); - XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); - map.put("logicproblem", _xMIResourceFactoryImpl); - InputOutput.println("Input and output workspaces are created"); - final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); - final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FileSystemPatterns.instance()); - InputOutput.println("DSL loaded"); - Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); - final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); - LogicProblem problem = modelGenerationProblem.getOutput(); - problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); - workspace.writeModel(problem, "FileSystem.logicproblem"); - InputOutput.println("Problem created"); - long startTime = System.currentTimeMillis(); - LogicReasoner reasoner = null; - VampireSolver _vampireSolver = new VampireSolver(); - reasoner = _vampireSolver; - final HashMap classMapMin = new HashMap(); - classMapMin.put(Dir.class, Integer.valueOf(10)); - classMapMin.put(File.class, Integer.valueOf(5)); - final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); - final HashMap classMapMax = new HashMap(); - classMapMax.put(File.class, Integer.valueOf(15)); - classMapMax.put(Dir.class, Integer.valueOf(15)); - final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); - VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); - final Procedure1 _function = (VampireSolverConfiguration it) -> { - it.documentationLevel = DocumentationLevel.FULL; - it.typeScopes.minNewElements = 10; - it.typeScopes.maxNewElements = 25; - int _size = typeMapMin.size(); - boolean _notEquals = (_size != 0); - if (_notEquals) { - it.typeScopes.minNewElementsByType = typeMapMin; - } - int _size_1 = typeMapMin.size(); - boolean _notEquals_1 = (_size_1 != 0); - if (_notEquals_1) { - it.typeScopes.maxNewElementsByType = typeMapMax; - } - it.contCycleLevel = 5; - it.uniquenessDuplicates = false; - }; - final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); - LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); - long _currentTimeMillis = System.currentTimeMillis(); - long _minus = (_currentTimeMillis - startTime); - long totalTimeMin = (_minus / 60000); - long _currentTimeMillis_1 = System.currentTimeMillis(); - long _minus_1 = (_currentTimeMillis_1 - startTime); - long _divide = (_minus_1 / 1000); - long totalTimeSec = (_divide % 60); - InputOutput.println("Problem solved"); - InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); - } catch (Throwable _e) { - throw Exceptions.sneakyThrow(_e); - } + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/FileSystemTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; + final Map map = reg.getExtensionToFactoryMap(); + XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); + map.put("logicproblem", _xMIResourceFactoryImpl); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); + InputOutput.println("DSL loaded"); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + LogicProblem problem = modelGenerationProblem.getOutput(); + problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); + workspace.writeModel(problem, "FileSystem.logicproblem"); + InputOutput.println("Problem created"); + long startTime = System.currentTimeMillis(); + VampireSolver reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + final HashMap classMapMin = new HashMap(); + classMapMin.put(Dir.class, Integer.valueOf(10)); + classMapMin.put(File.class, Integer.valueOf(5)); + final Map typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + final HashMap classMapMax = new HashMap(); + classMapMax.put(File.class, Integer.valueOf(15)); + classMapMax.put(Dir.class, Integer.valueOf(15)); + final Map typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.getTrace()); + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + it.typeScopes.minNewElements = 10; + it.typeScopes.maxNewElements = 25; + int _size = typeMapMin.size(); + boolean _notEquals = (_size != 0); + if (_notEquals) { + it.typeScopes.minNewElementsByType = typeMapMin; + } + int _size_1 = typeMapMin.size(); + boolean _notEquals_1 = (_size_1 != 0); + if (_notEquals_1) { + it.typeScopes.maxNewElementsByType = typeMapMax; + } + it.contCycleLevel = 5; + it.uniquenessDuplicates = false; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + LogicResult solution = reasoner.solve(problem, vampireConfig, workspace, "FS"); + long _currentTimeMillis = System.currentTimeMillis(); + long _minus = (_currentTimeMillis - startTime); + long totalTimeMin = (_minus / 60000); + long _currentTimeMillis_1 = System.currentTimeMillis(); + long _minus_1 = (_currentTimeMillis_1 - startTime); + long _divide = (_minus_1 / 1000); + long totalTimeSec = (_divide % 60); + InputOutput.println("Problem solved"); + InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index c33ed958..36edabcd 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 9fecf93f..0d4e05e0 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 7b5be981..f93484b4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 5d1165ceef23e20c4bbe46fe6f88e95f317234b5 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Mon, 7 Oct 2019 00:35:42 -0400 Subject: VAMPIRE: Implement Vampire measurement code --- .../model/FamMetamodel.ecore | 4 +- .../Examples/ModelGenExampleFAM_plugin/plugin.xml | 6 - .../META-INF/MANIFEST.MF | 5 +- .../domains/yakindu/sgraph/yakindumm/Entry.java | 35 + .../yakindu/sgraph/yakindumm/EntryType.java | 239 + .../yakindu/sgraph/yakindumm/YakindummPackage.java | 63 +- .../yakindu/sgraph/yakindumm/impl/EntryImpl.java | 123 + .../yakindumm/impl/YakindummFactoryImpl.java | 51 + .../yakindumm/impl/YakindummPackageImpl.java | 45 +- .../model/yakindu_simplified.ecore | 9 +- .../model/yakindu_simplified.genmodel | 10 +- .../plugin.xml | 7 - .../partialsnapshot_mavo/yakindu/patterns.vql | 122 +- .../inf/dslreasoner/logic2ecore/Logic2Ecore.xtend | 1 + .../contentassist/antlr/VampireLanguageParser.java | 1 + .../antlr/internal/InternalVampireLanguage.g | 46 + .../internal/InternalVampireLanguageLexer.java | 164 +- .../internal/InternalVampireLanguageParser.java | 5083 ++++++++++---------- .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../AbstractVampireLanguageProposalProvider.java | 6 + .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../model/generated/VampireLanguage.ecore | 4 +- .../model/generated/VampireLanguage.genmodel | 4 +- .../ecse/dslreasoner/VampireLanguage.xtextbin | Bin 8096 -> 8164 bytes .../antlr/internal/InternalVampireLanguage.g | 44 + .../internal/InternalVampireLanguageLexer.java | 164 +- .../internal/InternalVampireLanguageParser.java | 1203 ++--- .../VampireLanguageSemanticSequencer.java | 31 +- .../services/VampireLanguageGrammarAccess.java | 37 +- .../ecse/dslreasoner/vampireLanguage/VLSTerm.java | 32 + .../vampireLanguage/VampireLanguageFactory.java | 18 +- .../vampireLanguage/VampireLanguagePackage.java | 324 +- .../vampireLanguage/impl/VLSTermImpl.java | 136 + .../impl/VampireLanguageFactoryImpl.java | 24 +- .../impl/VampireLanguagePackageImpl.java | 52 +- .../util/VampireLanguageAdapterFactory.java | 40 +- .../util/VampireLanguageSwitch.java | 46 +- .../mcgill/ecse/dslreasoner/VampireLanguage.xtext | 7 +- .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 3759 -> 3759 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../vampire/reasoner/VampireSolver.xtend | 7 +- .../reasoner/builder/Vampire2LogicMapper.xtend | 4 +- .../vampire/reasoner/builder/VampireHandler.xtend | 10 +- .../builder/VampireModelInterpretation.xtend | 28 +- .../.VampireAnalyzerConfiguration.xtendbin | Bin 2691 -> 2691 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 6956 -> 7020 bytes .../vampire/reasoner/VampireSolver.java | 2 +- .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 18099 -> 18099 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 5080 -> 5080 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3165 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 11807 -> 11807 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 7934 -> 7934 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 10717 -> 10676 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 13059 -> 13060 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 11037 -> 11037 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 3858 -> 3950 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 6386 -> 6882 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../reasoner/builder/Vampire2LogicMapper.java | 7 +- .../vampire/reasoner/builder/VampireHandler.java | 9 +- .../META-INF/MANIFEST.MF | 3 +- .../metamodels/yakindu.ecore | 9 +- .../test/yakindu/queries/yakinduPatterns.vql | 2 +- .../META-INF/MANIFEST.MF | 19 +- .../initialModels/Yakindu.xmi | 4 - .../initialModels/yakindu/Yakindu.xmi | 4 + .../initialModels/yakindu/yakindu.ecore | 26 - .../output/FAMTest/Fam.logicproblem | 215 +- .../plugin.properties | 4 + .../plugin.xml | 11 +- .../ecse/dslreasoner/vampire/icse/EcoreTest.xtend | 2 +- .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 15 +- .../dslreasoner/vampire/icse/YakinduTest.xtend | 236 +- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4398 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 7335 -> 6624 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 6041 -> 6204 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6425 -> 6456 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 6883 -> 7597 bytes .../ecse/dslreasoner/vampire/icse/EcoreTest.java | 63 +- .../ecse/dslreasoner/vampire/icse/FAMTest.java | 13 +- .../ecse/dslreasoner/vampire/icse/YakinduTest.java | 148 +- .../vampire/test/.MedicalSystem.xtendbin | Bin 4684 -> 4997 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6443 -> 6500 bytes 95 files changed, 5254 insertions(+), 3773 deletions(-) create mode 100644 Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/EntryType.java delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/Yakindu.xmi create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/Yakindu.xmi delete mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/yakindu.ecore create mode 100644 Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.properties (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore index d8331ba8..3fab9a1d 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore +++ b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore @@ -9,7 +9,7 @@ + volatile="true" transient="true">
    @@ -25,7 +25,7 @@ + volatile="true" transient="true">
    diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml index d6f22c95..07fd662c 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml +++ b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml @@ -3,12 +3,6 @@ - - - - - - diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF index f2fd2ff3..f8973169 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/META-INF/MANIFEST.MF @@ -15,6 +15,7 @@ Require-Bundle: org.eclipse.viatra.query.runtime, org.eclipse.core.runtime, org.eclipse.emf.ecore;visibility:=reexport, com.google.guava;bundle-version="15.0.0" -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 -Bundle-ActivationPolicy: lazy Import-Package: org.apache.log4j +Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph +Bundle-ActivationPolicy: lazy +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/Entry.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/Entry.java index de8cdb07..994ffd96 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/Entry.java +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/Entry.java @@ -8,10 +8,45 @@ package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm; * A representation of the model object 'Entry'. * * + *

    + * The following features are supported: + *

    + *
      + *
    • {@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry#getType Type}
    • + *
    * * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage#getEntry() * @model * @generated */ public interface Entry extends Pseudostate { + + /** + * Returns the value of the 'Type' attribute. + * The literals are from the enumeration {@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType}. + * + *

    + * If the meaning of the 'Type' attribute isn't clear, + * there really should be more of a description here... + *

    + * + * @return the value of the 'Type' attribute. + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType + * @see #setType(EntryType) + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage#getEntry_Type() + * @model + * @generated + */ + EntryType getType(); + + /** + * Sets the value of the '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry#getType Type}' attribute. + * + * + * @param value the new value of the 'Type' attribute. + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType + * @see #getType() + * @generated + */ + void setType(EntryType value); } // Entry diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/EntryType.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/EntryType.java new file mode 100644 index 00000000..4f5d1a31 --- /dev/null +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/EntryType.java @@ -0,0 +1,239 @@ +/** + */ +package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm; + +import java.util.Arrays; +import java.util.Collections; +import java.util.List; + +import org.eclipse.emf.common.util.Enumerator; + +/** + * + * A representation of the literals of the enumeration 'Entry Type', + * and utility methods for working with them. + * + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage#getEntryType() + * @model + * @generated + */ +public enum EntryType implements Enumerator { + /** + * The 'Normal' literal object. + * + * + * @see #NORMAL_VALUE + * @generated + * @ordered + */ + NORMAL(0, "Normal", "Normal"), + + /** + * The 'History' literal object. + * + * + * @see #HISTORY_VALUE + * @generated + * @ordered + */ + HISTORY(0, "History", "History"), + + /** + * The 'Deep History' literal object. + * + * + * @see #DEEP_HISTORY_VALUE + * @generated + * @ordered + */ + DEEP_HISTORY(0, "DeepHistory", "DeepHistory"); + + /** + * The 'Normal' literal value. + * + *

    + * If the meaning of 'Normal' literal object isn't clear, + * there really should be more of a description here... + *

    + * + * @see #NORMAL + * @model name="Normal" + * @generated + * @ordered + */ + public static final int NORMAL_VALUE = 0; + + /** + * The 'History' literal value. + * + *

    + * If the meaning of 'History' literal object isn't clear, + * there really should be more of a description here... + *

    + * + * @see #HISTORY + * @model name="History" + * @generated + * @ordered + */ + public static final int HISTORY_VALUE = 0; + + /** + * The 'Deep History' literal value. + * + *

    + * If the meaning of 'Deep History' literal object isn't clear, + * there really should be more of a description here... + *

    + * + * @see #DEEP_HISTORY + * @model name="DeepHistory" + * @generated + * @ordered + */ + public static final int DEEP_HISTORY_VALUE = 0; + + /** + * An array of all the 'Entry Type' enumerators. + * + * + * @generated + */ + private static final EntryType[] VALUES_ARRAY = + new EntryType[] { + NORMAL, + HISTORY, + DEEP_HISTORY, + }; + + /** + * A public read-only list of all the 'Entry Type' enumerators. + * + * + * @generated + */ + public static final List VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY)); + + /** + * Returns the 'Entry Type' literal with the specified literal value. + * + * + * @param literal the literal. + * @return the matching enumerator or null. + * @generated + */ + public static EntryType get(String literal) { + for (int i = 0; i < VALUES_ARRAY.length; ++i) { + EntryType result = VALUES_ARRAY[i]; + if (result.toString().equals(literal)) { + return result; + } + } + return null; + } + + /** + * Returns the 'Entry Type' literal with the specified name. + * + * + * @param name the name. + * @return the matching enumerator or null. + * @generated + */ + public static EntryType getByName(String name) { + for (int i = 0; i < VALUES_ARRAY.length; ++i) { + EntryType result = VALUES_ARRAY[i]; + if (result.getName().equals(name)) { + return result; + } + } + return null; + } + + /** + * Returns the 'Entry Type' literal with the specified integer value. + * + * + * @param value the integer value. + * @return the matching enumerator or null. + * @generated + */ + public static EntryType get(int value) { + switch (value) { + case NORMAL_VALUE: return NORMAL; + } + return null; + } + + /** + * + * + * @generated + */ + private final int value; + + /** + * + * + * @generated + */ + private final String name; + + /** + * + * + * @generated + */ + private final String literal; + + /** + * Only this class can construct instances. + * + * + * @generated + */ + private EntryType(int value, String name, String literal) { + this.value = value; + this.name = name; + this.literal = literal; + } + + /** + * + * + * @generated + */ + public int getValue() { + return value; + } + + /** + * + * + * @generated + */ + public String getName() { + return name; + } + + /** + * + * + * @generated + */ + public String getLiteral() { + return literal; + } + + /** + * Returns the literal value of the enumerator, which is its string representation. + * + * + * @generated + */ + @Override + public String toString() { + return literal; + } + +} //EntryType diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/YakindummPackage.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/YakindummPackage.java index 18a4b105..a9269e05 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/YakindummPackage.java +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/YakindummPackage.java @@ -2,7 +2,9 @@ */ package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm; +import org.eclipse.emf.ecore.EAttribute; import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EEnum; import org.eclipse.emf.ecore.EPackage; import org.eclipse.emf.ecore.EReference; @@ -332,6 +334,15 @@ public interface YakindummPackage extends EPackage { */ int ENTRY__OUTGOING_TRANSITIONS = PSEUDOSTATE__OUTGOING_TRANSITIONS; + /** + * The feature id for the 'Type' attribute. + * + * + * @generated + * @ordered + */ + int ENTRY__TYPE = PSEUDOSTATE_FEATURE_COUNT + 0; + /** * The number of structural features of the 'Entry' class. * @@ -339,7 +350,7 @@ public interface YakindummPackage extends EPackage { * @generated * @ordered */ - int ENTRY_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 0; + int ENTRY_FEATURE_COUNT = PSEUDOSTATE_FEATURE_COUNT + 1; /** * The number of operations of the 'Entry' class. @@ -638,6 +649,17 @@ public interface YakindummPackage extends EPackage { int FINAL_STATE_OPERATION_COUNT = REGULAR_STATE_OPERATION_COUNT + 0; + /** + * The meta object id for the '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType Entry Type}' enum. + * + * + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl.YakindummPackageImpl#getEntryType() + * @generated + */ + int ENTRY_TYPE = 13; + + /** * Returns the meta object for class '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Pseudostate Pseudostate}'. * @@ -753,6 +775,17 @@ public interface YakindummPackage extends EPackage { */ EClass getEntry(); + /** + * Returns the meta object for the attribute '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry#getType Type}'. + * + * + * @return the meta object for the attribute 'Type'. + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry#getType() + * @see #getEntry() + * @generated + */ + EAttribute getEntry_Type(); + /** * Returns the meta object for class '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Synchronization Synchronization}'. * @@ -834,6 +867,16 @@ public interface YakindummPackage extends EPackage { */ EClass getFinalState(); + /** + * Returns the meta object for enum '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType Entry Type}'. + * + * + * @return the meta object for enum 'Entry Type'. + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType + * @generated + */ + EEnum getEntryType(); + /** * Returns the factory that creates the instances of the model. * @@ -957,6 +1000,14 @@ public interface YakindummPackage extends EPackage { */ EClass ENTRY = eINSTANCE.getEntry(); + /** + * The meta object literal for the 'Type' attribute feature. + * + * + * @generated + */ + EAttribute ENTRY__TYPE = eINSTANCE.getEntry_Type(); + /** * The meta object literal for the '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl.SynchronizationImpl Synchronization}' class. * @@ -1035,6 +1086,16 @@ public interface YakindummPackage extends EPackage { */ EClass FINAL_STATE = eINSTANCE.getFinalState(); + /** + * The meta object literal for the '{@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType Entry Type}' enum. + * + * + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType + * @see hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl.YakindummPackageImpl#getEntryType() + * @generated + */ + EEnum ENTRY_TYPE = eINSTANCE.getEntryType(); + } } //YakindummPackage diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/EntryImpl.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/EntryImpl.java index 35003e0d..27041630 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/EntryImpl.java +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/EntryImpl.java @@ -3,18 +3,46 @@ package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry; +import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage; +import org.eclipse.emf.common.notify.Notification; import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.impl.ENotificationImpl; /** * * An implementation of the model object 'Entry'. * + *

    + * The following features are implemented: + *

    + *
      + *
    • {@link hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl.EntryImpl#getType Type}
    • + *
    * * @generated */ public class EntryImpl extends PseudostateImpl implements Entry { + /** + * The default value of the '{@link #getType() Type}' attribute. + * + * + * @see #getType() + * @generated + * @ordered + */ + protected static final EntryType TYPE_EDEFAULT = EntryType.NORMAL; + /** + * The cached value of the '{@link #getType() Type}' attribute. + * + * + * @see #getType() + * @generated + * @ordered + */ + protected EntryType type = TYPE_EDEFAULT; + /** * * @@ -34,4 +62,99 @@ public class EntryImpl extends PseudostateImpl implements Entry { return YakindummPackage.Literals.ENTRY; } + /** + * + * + * @generated + */ + public EntryType getType() { + return type; + } + + /** + * + * + * @generated + */ + public void setType(EntryType newType) { + EntryType oldType = type; + type = newType == null ? TYPE_EDEFAULT : newType; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, YakindummPackage.ENTRY__TYPE, oldType, type)); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) { + switch (featureID) { + case YakindummPackage.ENTRY__TYPE: + return getType(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) { + switch (featureID) { + case YakindummPackage.ENTRY__TYPE: + setType((EntryType)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) { + switch (featureID) { + case YakindummPackage.ENTRY__TYPE: + setType(TYPE_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) { + switch (featureID) { + case YakindummPackage.ENTRY__TYPE: + return type != TYPE_EDEFAULT; + } + return super.eIsSet(featureID); + } + + /** + * + * + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (Type: "); + result.append(type); + result.append(')'); + return result.toString(); + } + } //EntryImpl diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummFactoryImpl.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummFactoryImpl.java index 9c4fc4f1..d4fc2d01 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummFactoryImpl.java +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummFactoryImpl.java @@ -5,6 +5,7 @@ package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.*; import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EDataType; import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.EPackage; @@ -70,6 +71,36 @@ public class YakindummFactoryImpl extends EFactoryImpl implements YakindummFacto } } + /** + * + * + * @generated + */ + @Override + public Object createFromString(EDataType eDataType, String initialValue) { + switch (eDataType.getClassifierID()) { + case YakindummPackage.ENTRY_TYPE: + return createEntryTypeFromString(eDataType, initialValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + + /** + * + * + * @generated + */ + @Override + public String convertToString(EDataType eDataType, Object instanceValue) { + switch (eDataType.getClassifierID()) { + case YakindummPackage.ENTRY_TYPE: + return convertEntryTypeToString(eDataType, instanceValue); + default: + throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier"); + } + } + /** * * @@ -160,6 +191,26 @@ public class YakindummFactoryImpl extends EFactoryImpl implements YakindummFacto return finalState; } + /** + * + * + * @generated + */ + public EntryType createEntryTypeFromString(EDataType eDataType, String initialValue) { + EntryType result = EntryType.get(initialValue); + if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'"); + return result; + } + + /** + * + * + * @generated + */ + public String convertEntryTypeToString(EDataType eDataType, Object instanceValue) { + return instanceValue == null ? null : instanceValue.toString(); + } + /** * * diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummPackageImpl.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummPackageImpl.java index 77092c17..e6da53ec 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummPackageImpl.java +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/yakindu/sgraph/yakindumm/impl/YakindummPackageImpl.java @@ -5,6 +5,7 @@ package hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.impl; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Choice; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.CompositeElement; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Entry; +import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.EntryType; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Exit; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.FinalState; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Pseudostate; @@ -18,7 +19,9 @@ import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.Vertex; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummFactory; import hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.yakindumm.YakindummPackage; +import org.eclipse.emf.ecore.EAttribute; import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EEnum; import org.eclipse.emf.ecore.EPackage; import org.eclipse.emf.ecore.EReference; @@ -122,6 +125,13 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka */ private EClass finalStateEClass = null; + /** + * + * + * @generated + */ + private EEnum entryTypeEEnum = null; + /** * Creates an instance of the model Package, registered with * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package @@ -150,7 +160,7 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka /** * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * + * *

    This method is used to initialize {@link YakindummPackage#eINSTANCE} when that field is accessed. * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. * @@ -164,7 +174,8 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka if (isInited) return (YakindummPackage)EPackage.Registry.INSTANCE.getEPackage(YakindummPackage.eNS_URI); // Obtain or create and register package - YakindummPackageImpl theYakindummPackage = (YakindummPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof YakindummPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new YakindummPackageImpl()); + Object registeredYakindummPackage = EPackage.Registry.INSTANCE.get(eNS_URI); + YakindummPackageImpl theYakindummPackage = registeredYakindummPackage instanceof YakindummPackageImpl ? (YakindummPackageImpl)registeredYakindummPackage : new YakindummPackageImpl(); isInited = true; @@ -177,7 +188,6 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka // Mark meta-data to indicate it can't be changed theYakindummPackage.freeze(); - // Update the registry and return the package EPackage.Registry.INSTANCE.put(YakindummPackage.eNS_URI, theYakindummPackage); return theYakindummPackage; @@ -282,6 +292,15 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka return entryEClass; } + /** + * + * + * @generated + */ + public EAttribute getEntry_Type() { + return (EAttribute)entryEClass.getEStructuralFeatures().get(0); + } + /** * * @@ -354,6 +373,15 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka return finalStateEClass; } + /** + * + * + * @generated + */ + public EEnum getEntryType() { + return entryTypeEEnum; + } + /** * * @@ -398,6 +426,7 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka statechartEClass = createEClass(STATECHART); entryEClass = createEClass(ENTRY); + createEAttribute(entryEClass, ENTRY__TYPE); synchronizationEClass = createEClass(SYNCHRONIZATION); @@ -413,6 +442,9 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka exitEClass = createEClass(EXIT); finalStateEClass = createEClass(FINAL_STATE); + + // Create enums + entryTypeEEnum = createEEnum(ENTRY_TYPE); } /** @@ -471,6 +503,7 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka initEClass(statechartEClass, Statechart.class, "Statechart", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEClass(entryEClass, Entry.class, "Entry", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getEntry_Type(), this.getEntryType(), "Type", null, 0, 1, Entry.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(synchronizationEClass, Synchronization.class, "Synchronization", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); @@ -487,6 +520,12 @@ public class YakindummPackageImpl extends EPackageImpl implements YakindummPacka initEClass(finalStateEClass, FinalState.class, "FinalState", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + // Initialize enums and add enum literals + initEEnum(entryTypeEEnum, EntryType.class, "EntryType"); + addEEnumLiteral(entryTypeEEnum, EntryType.NORMAL); + addEEnumLiteral(entryTypeEEnum, EntryType.HISTORY); + addEEnumLiteral(entryTypeEEnum, EntryType.DEEP_HISTORY); + // Create resource createResource(eNS_URI); } diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore index 0d6b4ac6..51b0ca5b 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore @@ -19,7 +19,9 @@ eType="#//Vertex" eOpposite="#//Vertex/outgoingTransitions"/> - + + + @@ -30,4 +32,9 @@ + + + + + diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.genmodel b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.genmodel index 4e34cf1d..4419a75a 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.genmodel +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.genmodel @@ -7,6 +7,11 @@ yakindu_simplified.ecore + + + + + @@ -20,7 +25,9 @@ - + + + @@ -29,5 +36,6 @@ + diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml index 8069f168..02c67af1 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/plugin.xml @@ -18,13 +18,6 @@ - - - - - - - diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/queries/hu/bme/mit/inf/dslreasoner/partialsnapshot_mavo/yakindu/patterns.vql b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/queries/hu/bme/mit/inf/dslreasoner/partialsnapshot_mavo/yakindu/patterns.vql index f4bfa3c1..09fb45c8 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/queries/hu/bme/mit/inf/dslreasoner/partialsnapshot_mavo/yakindu/patterns.vql +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/queries/hu/bme/mit/inf/dslreasoner/partialsnapshot_mavo/yakindu/patterns.vql @@ -88,67 +88,67 @@ pattern choiceHasNoIncoming(c: Choice) { neg find transition(_, _, c); } -///////// -// Synchronization -///////// - -@Constraint(severity="error", message="error", key = {s}) -pattern synchHasNoOutgoing(s : Synchronization) { - neg find transition(_, s, _); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern synchHasNoIncoming(s : Synchronization) { - neg find transition(_, _, s); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) { - find transition(t1, v1, s); - find transition(t2, v2, s); - t1!=t2; - Region.vertices(r, v1); - Region.vertices(r, v2); -} or { - find transition(t1, s, v1); - find transition(t2, s, v2); - t1!=t2; - Region.vertices(r, v1); - Region.vertices(r, v2); -} - -@Constraint(severity="error", message="error", key = {s}) -pattern notSynchronizingStates(s : Synchronization) { - neg find hasMultipleOutgoingTrainsition(s); - neg find hasMultipleIncomingTrainsition(s); -} - -pattern hasMultipleOutgoingTrainsition(v : Synchronization) { - find transition(_, v, trg1); - find transition(_, v, trg2); - trg1 != trg2; -} - -pattern hasMultipleIncomingTrainsition(v : Synchronization) { - find transition(_, src1, v); - find transition(_, src2, v); - src1 != src2; -} - -@Constraint(severity="error", message="error", key = {s}) -pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) { - find transition(_, v1, s); - find transition(_, v2, s); - CompositeElement.regions.vertices(r1, v1); - CompositeElement.regions.vertices(r2, v2); - r1 != r2; -} or { - find transition(_, s, v1); - find transition(_, s, v2); - CompositeElement.regions.vertices(r1, v1); - CompositeElement.regions.vertices(r2, v2); - r1 != r2; -} +/////////// +//// Synchronization +/////////// +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern synchHasNoOutgoing(s : Synchronization) { +// neg find transition(_, s, _); +//} +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern synchHasNoIncoming(s : Synchronization) { +// neg find transition(_, _, s); +//} +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern SynchronizedIncomingInSameRegion(s : Synchronization, v1 : Vertex, v2 : Vertex) { +// find transition(t1, v1, s); +// find transition(t2, v2, s); +// t1!=t2; +// Region.vertices(r, v1); +// Region.vertices(r, v2); +//} or { +// find transition(t1, s, v1); +// find transition(t2, s, v2); +// t1!=t2; +// Region.vertices(r, v1); +// Region.vertices(r, v2); +//} +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern notSynchronizingStates(s : Synchronization) { +// neg find hasMultipleOutgoingTrainsition(s); +// neg find hasMultipleIncomingTrainsition(s); +//} +// +//pattern hasMultipleOutgoingTrainsition(v : Synchronization) { +// find transition(_, v, trg1); +// find transition(_, v, trg2); +// trg1 != trg2; +//} +// +//pattern hasMultipleIncomingTrainsition(v : Synchronization) { +// find transition(_, src1, v); +// find transition(_, src2, v); +// src1 != src2; +//} +// +//@Constraint(severity="error", message="error", key = {s}) +//pattern SynchronizedRegionsAreNotSiblings(s : Synchronization, v1 : Vertex, v2 : Vertex) { +// find transition(_, v1, s); +// find transition(_, v2, s); +// CompositeElement.regions.vertices(r1, v1); +// CompositeElement.regions.vertices(r2, v2); +// r1 != r2; +//} or { +// find transition(_, s, v1); +// find transition(_, s, v2); +// CompositeElement.regions.vertices(r1, v1); +// CompositeElement.regions.vertices(r2, v2); +// r1 != r2; +//} /////////////////////////////// // Extra diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic2ecore/src/hu/bme/mit/inf/dslreasoner/logic2ecore/Logic2Ecore.xtend b/Framework/hu.bme.mit.inf.dslreasoner.logic2ecore/src/hu/bme/mit/inf/dslreasoner/logic2ecore/Logic2Ecore.xtend index 92deeae6..22abb083 100644 --- a/Framework/hu.bme.mit.inf.dslreasoner.logic2ecore/src/hu/bme/mit/inf/dslreasoner/logic2ecore/Logic2Ecore.xtend +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic2ecore/src/hu/bme/mit/inf/dslreasoner/logic2ecore/Logic2Ecore.xtend @@ -53,6 +53,7 @@ class Logic2Ecore { val allReferences = ecore2Logic.allReferencesInScope(forwardTrace) for(referenceType : allReferences) { if(referenceType.canSetFeature) { +// println("in") for(sourceElement : elements) { val sourceObject = sourceElement.lookup(element2Object) if(referenceType.EContainingClass.isSuperTypeOf(sourceObject.eClass)) { diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/VampireLanguageParser.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/VampireLanguageParser.java index e3b7a679..3e823077 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/VampireLanguageParser.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/VampireLanguageParser.java @@ -128,6 +128,7 @@ public class VampireLanguageParser extends AbstractContentAssistParser { builder.put(grammarAccess.getVLSAnnotationAccess().getFollowupAssignment_2_1(), "rule__VLSAnnotation__FollowupAssignment_2_1"); builder.put(grammarAccess.getVLSAnnotationTermsAccess().getTermsAssignment_0(), "rule__VLSAnnotationTerms__TermsAssignment_0"); builder.put(grammarAccess.getVLSAnnotationTermsAccess().getTermsAssignment_1_1(), "rule__VLSAnnotationTerms__TermsAssignment_1_1"); + builder.put(grammarAccess.getVLSCommentTermAccess().getCommentAssignment(), "rule__VLSCommentTerm__CommentAssignment"); builder.put(grammarAccess.getVLSOtherDeclarationAccess().getNameAssignment_0(), "rule__VLSOtherDeclaration__NameAssignment_0"); builder.put(grammarAccess.getVLSOtherDeclarationAccess().getTypeAssignment_2(), "rule__VLSOtherDeclaration__TypeAssignment_2"); builder.put(grammarAccess.getVLSVariableDeclarationAccess().getNameAssignment_0(), "rule__VLSVariableDeclaration__NameAssignment_0"); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguage.g b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguage.g index 7b766803..25312fbc 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguage.g +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguage.g @@ -374,6 +374,31 @@ finally { restoreStackSize(stackSize); } +// Entry rule entryRuleVLSCommentTerm +entryRuleVLSCommentTerm +: +{ before(grammarAccess.getVLSCommentTermRule()); } + ruleVLSCommentTerm +{ after(grammarAccess.getVLSCommentTermRule()); } + EOF +; + +// Rule VLSCommentTerm +ruleVLSCommentTerm + @init { + int stackSize = keepStackSize(); + } + : + ( + { before(grammarAccess.getVLSCommentTermAccess().getCommentAssignment()); } + (rule__VLSCommentTerm__CommentAssignment) + { after(grammarAccess.getVLSCommentTermAccess().getCommentAssignment()); } + ) +; +finally { + restoreStackSize(stackSize); +} + // Entry rule entryRuleVLSDeclaration entryRuleVLSDeclaration : @@ -1132,6 +1157,12 @@ rule__VLSTffTerm__Alternatives ruleVLSDeclaration { after(grammarAccess.getVLSTffTermAccess().getVLSDeclarationParserRuleCall_1()); } ) + | + ( + { before(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); } + ruleVLSCommentTerm + { after(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); } + ) ; finally { restoreStackSize(stackSize); @@ -6359,6 +6390,21 @@ finally { restoreStackSize(stackSize); } +rule__VLSCommentTerm__CommentAssignment + @init { + int stackSize = keepStackSize(); + } +: + ( + { before(grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); } + RULE_SINGLE_COMMENT + { after(grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); } + ) +; +finally { + restoreStackSize(stackSize); +} + rule__VLSOtherDeclaration__NameAssignment_0 @init { int stackSize = keepStackSize(); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageLexer.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageLexer.java index 82eb18b1..224e9fe9 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageLexer.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageLexer.java @@ -1331,8 +1331,8 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_ALPHA_NUMERIC" public final void mRULE_ALPHA_NUMERIC() throws RecognitionException { try { - // InternalVampireLanguage.g:6846:29: ( ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) ) - // InternalVampireLanguage.g:6846:31: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) + // InternalVampireLanguage.g:6892:29: ( ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) ) + // InternalVampireLanguage.g:6892:31: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) { if ( (input.LA(1)>='0' && input.LA(1)<='9')||(input.LA(1)>='A' && input.LA(1)<='Z')||input.LA(1)=='_'||(input.LA(1)>='a' && input.LA(1)<='z') ) { input.consume(); @@ -1357,11 +1357,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_UPPER_WORD_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6848:20: ( 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* ) - // InternalVampireLanguage.g:6848:22: 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:6894:20: ( 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* ) + // InternalVampireLanguage.g:6894:22: 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* { matchRange('A','Z'); - // InternalVampireLanguage.g:6848:31: ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:6894:31: ( RULE_ALPHA_NUMERIC )* loop1: do { int alt1=2; @@ -1374,7 +1374,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt1) { case 1 : - // InternalVampireLanguage.g:6848:31: RULE_ALPHA_NUMERIC + // InternalVampireLanguage.g:6894:31: RULE_ALPHA_NUMERIC { mRULE_ALPHA_NUMERIC(); @@ -1402,11 +1402,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_LOWER_WORD_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6850:20: ( 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* ) - // InternalVampireLanguage.g:6850:22: 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:6896:20: ( 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* ) + // InternalVampireLanguage.g:6896:22: 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* { matchRange('a','z'); - // InternalVampireLanguage.g:6850:31: ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:6896:31: ( RULE_ALPHA_NUMERIC )* loop2: do { int alt2=2; @@ -1419,7 +1419,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt2) { case 1 : - // InternalVampireLanguage.g:6850:31: RULE_ALPHA_NUMERIC + // InternalVampireLanguage.g:6896:31: RULE_ALPHA_NUMERIC { mRULE_ALPHA_NUMERIC(); @@ -1447,11 +1447,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOUBLE_QUOTE; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6852:19: ( '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' ) - // InternalVampireLanguage.g:6852:21: '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' + // InternalVampireLanguage.g:6898:19: ( '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' ) + // InternalVampireLanguage.g:6898:21: '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' { match('\"'); - // InternalVampireLanguage.g:6852:25: ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* + // InternalVampireLanguage.g:6898:25: ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* loop3: do { int alt3=3; @@ -1467,7 +1467,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt3) { case 1 : - // InternalVampireLanguage.g:6852:26: '\\\\' ( '\"' | '\\\\' ) + // InternalVampireLanguage.g:6898:26: '\\\\' ( '\"' | '\\\\' ) { match('\\'); if ( input.LA(1)=='\"'||input.LA(1)=='\\' ) { @@ -1483,7 +1483,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:6852:42: ~ ( ( '\\\\' | '\"' ) ) + // InternalVampireLanguage.g:6898:42: ~ ( ( '\\\\' | '\"' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='!')||(input.LA(1)>='#' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1520,11 +1520,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SINGLE_QUOTE; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6854:19: ( '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' ) - // InternalVampireLanguage.g:6854:21: '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' + // InternalVampireLanguage.g:6900:19: ( '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' ) + // InternalVampireLanguage.g:6900:21: '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' { match('\''); - // InternalVampireLanguage.g:6854:26: ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ + // InternalVampireLanguage.g:6900:26: ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ int cnt4=0; loop4: do { @@ -1541,7 +1541,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt4) { case 1 : - // InternalVampireLanguage.g:6854:27: '\\\\' ( '\\'' | '\\\\' ) + // InternalVampireLanguage.g:6900:27: '\\\\' ( '\\'' | '\\\\' ) { match('\\'); if ( input.LA(1)=='\''||input.LA(1)=='\\' ) { @@ -1557,7 +1557,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:6854:44: ~ ( ( '\\\\' | '\\'' ) ) + // InternalVampireLanguage.g:6900:44: ~ ( ( '\\\\' | '\\'' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='&')||(input.LA(1)>='(' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1596,8 +1596,8 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_SIGN" public final void mRULE_SIGN() throws RecognitionException { try { - // InternalVampireLanguage.g:6856:20: ( ( '+' | '-' ) ) - // InternalVampireLanguage.g:6856:22: ( '+' | '-' ) + // InternalVampireLanguage.g:6902:20: ( ( '+' | '-' ) ) + // InternalVampireLanguage.g:6902:22: ( '+' | '-' ) { if ( input.LA(1)=='+'||input.LA(1)=='-' ) { input.consume(); @@ -1622,8 +1622,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOLLAR_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6858:16: ( '$' RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:6858:18: '$' RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:6904:16: ( '$' RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:6904:18: '$' RULE_LOWER_WORD_ID { match('$'); mRULE_LOWER_WORD_ID(); @@ -1643,8 +1643,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOUBLE_DOLLAR_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6860:23: ( '$$' RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:6860:25: '$$' RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:6906:23: ( '$$' RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:6906:25: '$$' RULE_LOWER_WORD_ID { match("$$"); @@ -1665,10 +1665,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_LITERAL; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6862:14: ( ( '0' | '1' .. '9' ( RULE_INT )? ) ) - // InternalVampireLanguage.g:6862:16: ( '0' | '1' .. '9' ( RULE_INT )? ) + // InternalVampireLanguage.g:6908:14: ( ( '0' | '1' .. '9' ( RULE_INT )? ) ) + // InternalVampireLanguage.g:6908:16: ( '0' | '1' .. '9' ( RULE_INT )? ) { - // InternalVampireLanguage.g:6862:16: ( '0' | '1' .. '9' ( RULE_INT )? ) + // InternalVampireLanguage.g:6908:16: ( '0' | '1' .. '9' ( RULE_INT )? ) int alt6=2; int LA6_0 = input.LA(1); @@ -1686,17 +1686,17 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt6) { case 1 : - // InternalVampireLanguage.g:6862:17: '0' + // InternalVampireLanguage.g:6908:17: '0' { match('0'); } break; case 2 : - // InternalVampireLanguage.g:6862:21: '1' .. '9' ( RULE_INT )? + // InternalVampireLanguage.g:6908:21: '1' .. '9' ( RULE_INT )? { matchRange('1','9'); - // InternalVampireLanguage.g:6862:30: ( RULE_INT )? + // InternalVampireLanguage.g:6908:30: ( RULE_INT )? int alt5=2; int LA5_0 = input.LA(1); @@ -1705,7 +1705,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt5) { case 1 : - // InternalVampireLanguage.g:6862:30: RULE_INT + // InternalVampireLanguage.g:6908:30: RULE_INT { mRULE_INT(); @@ -1736,10 +1736,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SIGNED_LITERAL; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6864:21: ( ( RULE_SIGN )* RULE_LITERAL ) - // InternalVampireLanguage.g:6864:23: ( RULE_SIGN )* RULE_LITERAL + // InternalVampireLanguage.g:6910:21: ( ( RULE_SIGN )* RULE_LITERAL ) + // InternalVampireLanguage.g:6910:23: ( RULE_SIGN )* RULE_LITERAL { - // InternalVampireLanguage.g:6864:23: ( RULE_SIGN )* + // InternalVampireLanguage.g:6910:23: ( RULE_SIGN )* loop7: do { int alt7=2; @@ -1752,7 +1752,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt7) { case 1 : - // InternalVampireLanguage.g:6864:23: RULE_SIGN + // InternalVampireLanguage.g:6910:23: RULE_SIGN { mRULE_SIGN(); @@ -1781,11 +1781,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SINGLE_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6866:21: ( '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) - // InternalVampireLanguage.g:6866:23: '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:6912:21: ( '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) + // InternalVampireLanguage.g:6912:23: '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? { match('%'); - // InternalVampireLanguage.g:6866:27: (~ ( ( '\\n' | '\\r' ) ) )* + // InternalVampireLanguage.g:6912:27: (~ ( ( '\\n' | '\\r' ) ) )* loop8: do { int alt8=2; @@ -1798,7 +1798,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt8) { case 1 : - // InternalVampireLanguage.g:6866:27: ~ ( ( '\\n' | '\\r' ) ) + // InternalVampireLanguage.g:6912:27: ~ ( ( '\\n' | '\\r' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='\t')||(input.LA(1)>='\u000B' && input.LA(1)<='\f')||(input.LA(1)>='\u000E' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1818,7 +1818,7 @@ public class InternalVampireLanguageLexer extends Lexer { } } while (true); - // InternalVampireLanguage.g:6866:43: ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:6912:43: ( ( '\\r' )? '\\n' )? int alt10=2; int LA10_0 = input.LA(1); @@ -1827,9 +1827,9 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt10) { case 1 : - // InternalVampireLanguage.g:6866:44: ( '\\r' )? '\\n' + // InternalVampireLanguage.g:6912:44: ( '\\r' )? '\\n' { - // InternalVampireLanguage.g:6866:44: ( '\\r' )? + // InternalVampireLanguage.g:6912:44: ( '\\r' )? int alt9=2; int LA9_0 = input.LA(1); @@ -1838,7 +1838,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt9) { case 1 : - // InternalVampireLanguage.g:6866:44: '\\r' + // InternalVampireLanguage.g:6912:44: '\\r' { match('\r'); @@ -1870,10 +1870,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6868:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* ) - // InternalVampireLanguage.g:6868:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* + // InternalVampireLanguage.g:6914:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* ) + // InternalVampireLanguage.g:6914:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* { - // InternalVampireLanguage.g:6868:11: ( '^' )? + // InternalVampireLanguage.g:6914:11: ( '^' )? int alt11=2; int LA11_0 = input.LA(1); @@ -1882,7 +1882,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt11) { case 1 : - // InternalVampireLanguage.g:6868:11: '^' + // InternalVampireLanguage.g:6914:11: '^' { match('^'); @@ -1900,7 +1900,7 @@ public class InternalVampireLanguageLexer extends Lexer { recover(mse); throw mse;} - // InternalVampireLanguage.g:6868:40: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* + // InternalVampireLanguage.g:6914:40: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* loop12: do { int alt12=2; @@ -1947,10 +1947,10 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_INT" public final void mRULE_INT() throws RecognitionException { try { - // InternalVampireLanguage.g:6870:19: ( ( '0' .. '9' )+ ) - // InternalVampireLanguage.g:6870:21: ( '0' .. '9' )+ + // InternalVampireLanguage.g:6916:19: ( ( '0' .. '9' )+ ) + // InternalVampireLanguage.g:6916:21: ( '0' .. '9' )+ { - // InternalVampireLanguage.g:6870:21: ( '0' .. '9' )+ + // InternalVampireLanguage.g:6916:21: ( '0' .. '9' )+ int cnt13=0; loop13: do { @@ -1964,7 +1964,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt13) { case 1 : - // InternalVampireLanguage.g:6870:22: '0' .. '9' + // InternalVampireLanguage.g:6916:22: '0' .. '9' { matchRange('0','9'); @@ -1994,10 +1994,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_STRING; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6872:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) ) - // InternalVampireLanguage.g:6872:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) + // InternalVampireLanguage.g:6918:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) ) + // InternalVampireLanguage.g:6918:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) { - // InternalVampireLanguage.g:6872:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) + // InternalVampireLanguage.g:6918:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) int alt16=2; int LA16_0 = input.LA(1); @@ -2015,10 +2015,10 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt16) { case 1 : - // InternalVampireLanguage.g:6872:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' + // InternalVampireLanguage.g:6918:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' { match('\"'); - // InternalVampireLanguage.g:6872:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* + // InternalVampireLanguage.g:6918:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* loop14: do { int alt14=3; @@ -2034,7 +2034,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt14) { case 1 : - // InternalVampireLanguage.g:6872:21: '\\\\' . + // InternalVampireLanguage.g:6918:21: '\\\\' . { match('\\'); matchAny(); @@ -2042,7 +2042,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:6872:28: ~ ( ( '\\\\' | '\"' ) ) + // InternalVampireLanguage.g:6918:28: ~ ( ( '\\\\' | '\"' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='!')||(input.LA(1)>='#' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2067,10 +2067,10 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:6872:48: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' + // InternalVampireLanguage.g:6918:48: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' { match('\''); - // InternalVampireLanguage.g:6872:53: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* + // InternalVampireLanguage.g:6918:53: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* loop15: do { int alt15=3; @@ -2086,7 +2086,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt15) { case 1 : - // InternalVampireLanguage.g:6872:54: '\\\\' . + // InternalVampireLanguage.g:6918:54: '\\\\' . { match('\\'); matchAny(); @@ -2094,7 +2094,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:6872:61: ~ ( ( '\\\\' | '\\'' ) ) + // InternalVampireLanguage.g:6918:61: ~ ( ( '\\\\' | '\\'' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='&')||(input.LA(1)>='(' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2137,12 +2137,12 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ML_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6874:17: ( '/*' ( options {greedy=false; } : . )* '*/' ) - // InternalVampireLanguage.g:6874:19: '/*' ( options {greedy=false; } : . )* '*/' + // InternalVampireLanguage.g:6920:17: ( '/*' ( options {greedy=false; } : . )* '*/' ) + // InternalVampireLanguage.g:6920:19: '/*' ( options {greedy=false; } : . )* '*/' { match("/*"); - // InternalVampireLanguage.g:6874:24: ( options {greedy=false; } : . )* + // InternalVampireLanguage.g:6920:24: ( options {greedy=false; } : . )* loop17: do { int alt17=2; @@ -2167,7 +2167,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt17) { case 1 : - // InternalVampireLanguage.g:6874:52: . + // InternalVampireLanguage.g:6920:52: . { matchAny(); @@ -2197,12 +2197,12 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SL_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6876:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) - // InternalVampireLanguage.g:6876:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:6922:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) + // InternalVampireLanguage.g:6922:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? { match("//"); - // InternalVampireLanguage.g:6876:24: (~ ( ( '\\n' | '\\r' ) ) )* + // InternalVampireLanguage.g:6922:24: (~ ( ( '\\n' | '\\r' ) ) )* loop18: do { int alt18=2; @@ -2215,7 +2215,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt18) { case 1 : - // InternalVampireLanguage.g:6876:24: ~ ( ( '\\n' | '\\r' ) ) + // InternalVampireLanguage.g:6922:24: ~ ( ( '\\n' | '\\r' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='\t')||(input.LA(1)>='\u000B' && input.LA(1)<='\f')||(input.LA(1)>='\u000E' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2235,7 +2235,7 @@ public class InternalVampireLanguageLexer extends Lexer { } } while (true); - // InternalVampireLanguage.g:6876:40: ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:6922:40: ( ( '\\r' )? '\\n' )? int alt20=2; int LA20_0 = input.LA(1); @@ -2244,9 +2244,9 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt20) { case 1 : - // InternalVampireLanguage.g:6876:41: ( '\\r' )? '\\n' + // InternalVampireLanguage.g:6922:41: ( '\\r' )? '\\n' { - // InternalVampireLanguage.g:6876:41: ( '\\r' )? + // InternalVampireLanguage.g:6922:41: ( '\\r' )? int alt19=2; int LA19_0 = input.LA(1); @@ -2255,7 +2255,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt19) { case 1 : - // InternalVampireLanguage.g:6876:41: '\\r' + // InternalVampireLanguage.g:6922:41: '\\r' { match('\r'); @@ -2287,10 +2287,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_WS; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6878:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ ) - // InternalVampireLanguage.g:6878:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ + // InternalVampireLanguage.g:6924:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ ) + // InternalVampireLanguage.g:6924:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ { - // InternalVampireLanguage.g:6878:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ + // InternalVampireLanguage.g:6924:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ int cnt21=0; loop21: do { @@ -2344,8 +2344,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ANY_OTHER; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:6880:16: ( . ) - // InternalVampireLanguage.g:6880:18: . + // InternalVampireLanguage.g:6926:16: ( . ) + // InternalVampireLanguage.g:6926:18: . { matchAny(); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageParser.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageParser.java index 38a7d70f..d5378c6f 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageParser.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/src-gen/ca/mcgill/ecse/dslreasoner/ide/contentassist/antlr/internal/InternalVampireLanguageParser.java @@ -1137,12 +1137,89 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR end "ruleVLSTffTerm" + // $ANTLR start "entryRuleVLSCommentTerm" + // InternalVampireLanguage.g:378:1: entryRuleVLSCommentTerm : ruleVLSCommentTerm EOF ; + public final void entryRuleVLSCommentTerm() throws RecognitionException { + try { + // InternalVampireLanguage.g:379:1: ( ruleVLSCommentTerm EOF ) + // InternalVampireLanguage.g:380:1: ruleVLSCommentTerm EOF + { + before(grammarAccess.getVLSCommentTermRule()); + pushFollow(FOLLOW_1); + ruleVLSCommentTerm(); + + state._fsp--; + + after(grammarAccess.getVLSCommentTermRule()); + match(input,EOF,FOLLOW_2); + + } + + } + catch (RecognitionException re) { + reportError(re); + recover(input,re); + } + finally { + } + return ; + } + // $ANTLR end "entryRuleVLSCommentTerm" + + + // $ANTLR start "ruleVLSCommentTerm" + // InternalVampireLanguage.g:387:1: ruleVLSCommentTerm : ( ( rule__VLSCommentTerm__CommentAssignment ) ) ; + public final void ruleVLSCommentTerm() throws RecognitionException { + + int stackSize = keepStackSize(); + + try { + // InternalVampireLanguage.g:391:2: ( ( ( rule__VLSCommentTerm__CommentAssignment ) ) ) + // InternalVampireLanguage.g:392:2: ( ( rule__VLSCommentTerm__CommentAssignment ) ) + { + // InternalVampireLanguage.g:392:2: ( ( rule__VLSCommentTerm__CommentAssignment ) ) + // InternalVampireLanguage.g:393:3: ( rule__VLSCommentTerm__CommentAssignment ) + { + before(grammarAccess.getVLSCommentTermAccess().getCommentAssignment()); + // InternalVampireLanguage.g:394:3: ( rule__VLSCommentTerm__CommentAssignment ) + // InternalVampireLanguage.g:394:4: rule__VLSCommentTerm__CommentAssignment + { + pushFollow(FOLLOW_2); + rule__VLSCommentTerm__CommentAssignment(); + + state._fsp--; + + + } + + after(grammarAccess.getVLSCommentTermAccess().getCommentAssignment()); + + } + + + } + + } + catch (RecognitionException re) { + reportError(re); + recover(input,re); + } + finally { + + restoreStackSize(stackSize); + + } + return ; + } + // $ANTLR end "ruleVLSCommentTerm" + + // $ANTLR start "entryRuleVLSDeclaration" - // InternalVampireLanguage.g:378:1: entryRuleVLSDeclaration : ruleVLSDeclaration EOF ; + // InternalVampireLanguage.g:403:1: entryRuleVLSDeclaration : ruleVLSDeclaration EOF ; public final void entryRuleVLSDeclaration() throws RecognitionException { try { - // InternalVampireLanguage.g:379:1: ( ruleVLSDeclaration EOF ) - // InternalVampireLanguage.g:380:1: ruleVLSDeclaration EOF + // InternalVampireLanguage.g:404:1: ( ruleVLSDeclaration EOF ) + // InternalVampireLanguage.g:405:1: ruleVLSDeclaration EOF { before(grammarAccess.getVLSDeclarationRule()); pushFollow(FOLLOW_1); @@ -1168,21 +1245,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSDeclaration" - // InternalVampireLanguage.g:387:1: ruleVLSDeclaration : ( ( rule__VLSDeclaration__Alternatives ) ) ; + // InternalVampireLanguage.g:412:1: ruleVLSDeclaration : ( ( rule__VLSDeclaration__Alternatives ) ) ; public final void ruleVLSDeclaration() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:391:2: ( ( ( rule__VLSDeclaration__Alternatives ) ) ) - // InternalVampireLanguage.g:392:2: ( ( rule__VLSDeclaration__Alternatives ) ) + // InternalVampireLanguage.g:416:2: ( ( ( rule__VLSDeclaration__Alternatives ) ) ) + // InternalVampireLanguage.g:417:2: ( ( rule__VLSDeclaration__Alternatives ) ) { - // InternalVampireLanguage.g:392:2: ( ( rule__VLSDeclaration__Alternatives ) ) - // InternalVampireLanguage.g:393:3: ( rule__VLSDeclaration__Alternatives ) + // InternalVampireLanguage.g:417:2: ( ( rule__VLSDeclaration__Alternatives ) ) + // InternalVampireLanguage.g:418:3: ( rule__VLSDeclaration__Alternatives ) { before(grammarAccess.getVLSDeclarationAccess().getAlternatives()); - // InternalVampireLanguage.g:394:3: ( rule__VLSDeclaration__Alternatives ) - // InternalVampireLanguage.g:394:4: rule__VLSDeclaration__Alternatives + // InternalVampireLanguage.g:419:3: ( rule__VLSDeclaration__Alternatives ) + // InternalVampireLanguage.g:419:4: rule__VLSDeclaration__Alternatives { pushFollow(FOLLOW_2); rule__VLSDeclaration__Alternatives(); @@ -1215,11 +1292,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSOtherDeclaration" - // InternalVampireLanguage.g:403:1: entryRuleVLSOtherDeclaration : ruleVLSOtherDeclaration EOF ; + // InternalVampireLanguage.g:428:1: entryRuleVLSOtherDeclaration : ruleVLSOtherDeclaration EOF ; public final void entryRuleVLSOtherDeclaration() throws RecognitionException { try { - // InternalVampireLanguage.g:404:1: ( ruleVLSOtherDeclaration EOF ) - // InternalVampireLanguage.g:405:1: ruleVLSOtherDeclaration EOF + // InternalVampireLanguage.g:429:1: ( ruleVLSOtherDeclaration EOF ) + // InternalVampireLanguage.g:430:1: ruleVLSOtherDeclaration EOF { before(grammarAccess.getVLSOtherDeclarationRule()); pushFollow(FOLLOW_1); @@ -1245,21 +1322,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSOtherDeclaration" - // InternalVampireLanguage.g:412:1: ruleVLSOtherDeclaration : ( ( rule__VLSOtherDeclaration__Group__0 ) ) ; + // InternalVampireLanguage.g:437:1: ruleVLSOtherDeclaration : ( ( rule__VLSOtherDeclaration__Group__0 ) ) ; public final void ruleVLSOtherDeclaration() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:416:2: ( ( ( rule__VLSOtherDeclaration__Group__0 ) ) ) - // InternalVampireLanguage.g:417:2: ( ( rule__VLSOtherDeclaration__Group__0 ) ) + // InternalVampireLanguage.g:441:2: ( ( ( rule__VLSOtherDeclaration__Group__0 ) ) ) + // InternalVampireLanguage.g:442:2: ( ( rule__VLSOtherDeclaration__Group__0 ) ) { - // InternalVampireLanguage.g:417:2: ( ( rule__VLSOtherDeclaration__Group__0 ) ) - // InternalVampireLanguage.g:418:3: ( rule__VLSOtherDeclaration__Group__0 ) + // InternalVampireLanguage.g:442:2: ( ( rule__VLSOtherDeclaration__Group__0 ) ) + // InternalVampireLanguage.g:443:3: ( rule__VLSOtherDeclaration__Group__0 ) { before(grammarAccess.getVLSOtherDeclarationAccess().getGroup()); - // InternalVampireLanguage.g:419:3: ( rule__VLSOtherDeclaration__Group__0 ) - // InternalVampireLanguage.g:419:4: rule__VLSOtherDeclaration__Group__0 + // InternalVampireLanguage.g:444:3: ( rule__VLSOtherDeclaration__Group__0 ) + // InternalVampireLanguage.g:444:4: rule__VLSOtherDeclaration__Group__0 { pushFollow(FOLLOW_2); rule__VLSOtherDeclaration__Group__0(); @@ -1292,11 +1369,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSVariableDeclaration" - // InternalVampireLanguage.g:428:1: entryRuleVLSVariableDeclaration : ruleVLSVariableDeclaration EOF ; + // InternalVampireLanguage.g:453:1: entryRuleVLSVariableDeclaration : ruleVLSVariableDeclaration EOF ; public final void entryRuleVLSVariableDeclaration() throws RecognitionException { try { - // InternalVampireLanguage.g:429:1: ( ruleVLSVariableDeclaration EOF ) - // InternalVampireLanguage.g:430:1: ruleVLSVariableDeclaration EOF + // InternalVampireLanguage.g:454:1: ( ruleVLSVariableDeclaration EOF ) + // InternalVampireLanguage.g:455:1: ruleVLSVariableDeclaration EOF { before(grammarAccess.getVLSVariableDeclarationRule()); pushFollow(FOLLOW_1); @@ -1322,21 +1399,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSVariableDeclaration" - // InternalVampireLanguage.g:437:1: ruleVLSVariableDeclaration : ( ( rule__VLSVariableDeclaration__Group__0 ) ) ; + // InternalVampireLanguage.g:462:1: ruleVLSVariableDeclaration : ( ( rule__VLSVariableDeclaration__Group__0 ) ) ; public final void ruleVLSVariableDeclaration() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:441:2: ( ( ( rule__VLSVariableDeclaration__Group__0 ) ) ) - // InternalVampireLanguage.g:442:2: ( ( rule__VLSVariableDeclaration__Group__0 ) ) + // InternalVampireLanguage.g:466:2: ( ( ( rule__VLSVariableDeclaration__Group__0 ) ) ) + // InternalVampireLanguage.g:467:2: ( ( rule__VLSVariableDeclaration__Group__0 ) ) { - // InternalVampireLanguage.g:442:2: ( ( rule__VLSVariableDeclaration__Group__0 ) ) - // InternalVampireLanguage.g:443:3: ( rule__VLSVariableDeclaration__Group__0 ) + // InternalVampireLanguage.g:467:2: ( ( rule__VLSVariableDeclaration__Group__0 ) ) + // InternalVampireLanguage.g:468:3: ( rule__VLSVariableDeclaration__Group__0 ) { before(grammarAccess.getVLSVariableDeclarationAccess().getGroup()); - // InternalVampireLanguage.g:444:3: ( rule__VLSVariableDeclaration__Group__0 ) - // InternalVampireLanguage.g:444:4: rule__VLSVariableDeclaration__Group__0 + // InternalVampireLanguage.g:469:3: ( rule__VLSVariableDeclaration__Group__0 ) + // InternalVampireLanguage.g:469:4: rule__VLSVariableDeclaration__Group__0 { pushFollow(FOLLOW_2); rule__VLSVariableDeclaration__Group__0(); @@ -1369,11 +1446,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSTypeDef" - // InternalVampireLanguage.g:453:1: entryRuleVLSTypeDef : ruleVLSTypeDef EOF ; + // InternalVampireLanguage.g:478:1: entryRuleVLSTypeDef : ruleVLSTypeDef EOF ; public final void entryRuleVLSTypeDef() throws RecognitionException { try { - // InternalVampireLanguage.g:454:1: ( ruleVLSTypeDef EOF ) - // InternalVampireLanguage.g:455:1: ruleVLSTypeDef EOF + // InternalVampireLanguage.g:479:1: ( ruleVLSTypeDef EOF ) + // InternalVampireLanguage.g:480:1: ruleVLSTypeDef EOF { before(grammarAccess.getVLSTypeDefRule()); pushFollow(FOLLOW_1); @@ -1399,21 +1476,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSTypeDef" - // InternalVampireLanguage.g:462:1: ruleVLSTypeDef : ( ( rule__VLSTypeDef__Group__0 ) ) ; + // InternalVampireLanguage.g:487:1: ruleVLSTypeDef : ( ( rule__VLSTypeDef__Group__0 ) ) ; public final void ruleVLSTypeDef() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:466:2: ( ( ( rule__VLSTypeDef__Group__0 ) ) ) - // InternalVampireLanguage.g:467:2: ( ( rule__VLSTypeDef__Group__0 ) ) + // InternalVampireLanguage.g:491:2: ( ( ( rule__VLSTypeDef__Group__0 ) ) ) + // InternalVampireLanguage.g:492:2: ( ( rule__VLSTypeDef__Group__0 ) ) { - // InternalVampireLanguage.g:467:2: ( ( rule__VLSTypeDef__Group__0 ) ) - // InternalVampireLanguage.g:468:3: ( rule__VLSTypeDef__Group__0 ) + // InternalVampireLanguage.g:492:2: ( ( rule__VLSTypeDef__Group__0 ) ) + // InternalVampireLanguage.g:493:3: ( rule__VLSTypeDef__Group__0 ) { before(grammarAccess.getVLSTypeDefAccess().getGroup()); - // InternalVampireLanguage.g:469:3: ( rule__VLSTypeDef__Group__0 ) - // InternalVampireLanguage.g:469:4: rule__VLSTypeDef__Group__0 + // InternalVampireLanguage.g:494:3: ( rule__VLSTypeDef__Group__0 ) + // InternalVampireLanguage.g:494:4: rule__VLSTypeDef__Group__0 { pushFollow(FOLLOW_2); rule__VLSTypeDef__Group__0(); @@ -1446,11 +1523,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSUnitaryTerm" - // InternalVampireLanguage.g:478:1: entryRuleVLSUnitaryTerm : ruleVLSUnitaryTerm EOF ; + // InternalVampireLanguage.g:503:1: entryRuleVLSUnitaryTerm : ruleVLSUnitaryTerm EOF ; public final void entryRuleVLSUnitaryTerm() throws RecognitionException { try { - // InternalVampireLanguage.g:479:1: ( ruleVLSUnitaryTerm EOF ) - // InternalVampireLanguage.g:480:1: ruleVLSUnitaryTerm EOF + // InternalVampireLanguage.g:504:1: ( ruleVLSUnitaryTerm EOF ) + // InternalVampireLanguage.g:505:1: ruleVLSUnitaryTerm EOF { before(grammarAccess.getVLSUnitaryTermRule()); pushFollow(FOLLOW_1); @@ -1476,21 +1553,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSUnitaryTerm" - // InternalVampireLanguage.g:487:1: ruleVLSUnitaryTerm : ( ( rule__VLSUnitaryTerm__Group__0 ) ) ; + // InternalVampireLanguage.g:512:1: ruleVLSUnitaryTerm : ( ( rule__VLSUnitaryTerm__Group__0 ) ) ; public final void ruleVLSUnitaryTerm() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:491:2: ( ( ( rule__VLSUnitaryTerm__Group__0 ) ) ) - // InternalVampireLanguage.g:492:2: ( ( rule__VLSUnitaryTerm__Group__0 ) ) + // InternalVampireLanguage.g:516:2: ( ( ( rule__VLSUnitaryTerm__Group__0 ) ) ) + // InternalVampireLanguage.g:517:2: ( ( rule__VLSUnitaryTerm__Group__0 ) ) { - // InternalVampireLanguage.g:492:2: ( ( rule__VLSUnitaryTerm__Group__0 ) ) - // InternalVampireLanguage.g:493:3: ( rule__VLSUnitaryTerm__Group__0 ) + // InternalVampireLanguage.g:517:2: ( ( rule__VLSUnitaryTerm__Group__0 ) ) + // InternalVampireLanguage.g:518:3: ( rule__VLSUnitaryTerm__Group__0 ) { before(grammarAccess.getVLSUnitaryTermAccess().getGroup()); - // InternalVampireLanguage.g:494:3: ( rule__VLSUnitaryTerm__Group__0 ) - // InternalVampireLanguage.g:494:4: rule__VLSUnitaryTerm__Group__0 + // InternalVampireLanguage.g:519:3: ( rule__VLSUnitaryTerm__Group__0 ) + // InternalVampireLanguage.g:519:4: rule__VLSUnitaryTerm__Group__0 { pushFollow(FOLLOW_2); rule__VLSUnitaryTerm__Group__0(); @@ -1523,11 +1600,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSTerm" - // InternalVampireLanguage.g:503:1: entryRuleVLSTerm : ruleVLSTerm EOF ; + // InternalVampireLanguage.g:528:1: entryRuleVLSTerm : ruleVLSTerm EOF ; public final void entryRuleVLSTerm() throws RecognitionException { try { - // InternalVampireLanguage.g:504:1: ( ruleVLSTerm EOF ) - // InternalVampireLanguage.g:505:1: ruleVLSTerm EOF + // InternalVampireLanguage.g:529:1: ( ruleVLSTerm EOF ) + // InternalVampireLanguage.g:530:1: ruleVLSTerm EOF { before(grammarAccess.getVLSTermRule()); pushFollow(FOLLOW_1); @@ -1553,17 +1630,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSTerm" - // InternalVampireLanguage.g:512:1: ruleVLSTerm : ( ruleVLSBinary ) ; + // InternalVampireLanguage.g:537:1: ruleVLSTerm : ( ruleVLSBinary ) ; public final void ruleVLSTerm() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:516:2: ( ( ruleVLSBinary ) ) - // InternalVampireLanguage.g:517:2: ( ruleVLSBinary ) + // InternalVampireLanguage.g:541:2: ( ( ruleVLSBinary ) ) + // InternalVampireLanguage.g:542:2: ( ruleVLSBinary ) { - // InternalVampireLanguage.g:517:2: ( ruleVLSBinary ) - // InternalVampireLanguage.g:518:3: ruleVLSBinary + // InternalVampireLanguage.g:542:2: ( ruleVLSBinary ) + // InternalVampireLanguage.g:543:3: ruleVLSBinary { before(grammarAccess.getVLSTermAccess().getVLSBinaryParserRuleCall()); pushFollow(FOLLOW_2); @@ -1594,11 +1671,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSBinary" - // InternalVampireLanguage.g:528:1: entryRuleVLSBinary : ruleVLSBinary EOF ; + // InternalVampireLanguage.g:553:1: entryRuleVLSBinary : ruleVLSBinary EOF ; public final void entryRuleVLSBinary() throws RecognitionException { try { - // InternalVampireLanguage.g:529:1: ( ruleVLSBinary EOF ) - // InternalVampireLanguage.g:530:1: ruleVLSBinary EOF + // InternalVampireLanguage.g:554:1: ( ruleVLSBinary EOF ) + // InternalVampireLanguage.g:555:1: ruleVLSBinary EOF { before(grammarAccess.getVLSBinaryRule()); pushFollow(FOLLOW_1); @@ -1624,21 +1701,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSBinary" - // InternalVampireLanguage.g:537:1: ruleVLSBinary : ( ( rule__VLSBinary__Group__0 ) ) ; + // InternalVampireLanguage.g:562:1: ruleVLSBinary : ( ( rule__VLSBinary__Group__0 ) ) ; public final void ruleVLSBinary() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:541:2: ( ( ( rule__VLSBinary__Group__0 ) ) ) - // InternalVampireLanguage.g:542:2: ( ( rule__VLSBinary__Group__0 ) ) + // InternalVampireLanguage.g:566:2: ( ( ( rule__VLSBinary__Group__0 ) ) ) + // InternalVampireLanguage.g:567:2: ( ( rule__VLSBinary__Group__0 ) ) { - // InternalVampireLanguage.g:542:2: ( ( rule__VLSBinary__Group__0 ) ) - // InternalVampireLanguage.g:543:3: ( rule__VLSBinary__Group__0 ) + // InternalVampireLanguage.g:567:2: ( ( rule__VLSBinary__Group__0 ) ) + // InternalVampireLanguage.g:568:3: ( rule__VLSBinary__Group__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup()); - // InternalVampireLanguage.g:544:3: ( rule__VLSBinary__Group__0 ) - // InternalVampireLanguage.g:544:4: rule__VLSBinary__Group__0 + // InternalVampireLanguage.g:569:3: ( rule__VLSBinary__Group__0 ) + // InternalVampireLanguage.g:569:4: rule__VLSBinary__Group__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group__0(); @@ -1671,11 +1748,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSUnitaryFormula" - // InternalVampireLanguage.g:553:1: entryRuleVLSUnitaryFormula : ruleVLSUnitaryFormula EOF ; + // InternalVampireLanguage.g:578:1: entryRuleVLSUnitaryFormula : ruleVLSUnitaryFormula EOF ; public final void entryRuleVLSUnitaryFormula() throws RecognitionException { try { - // InternalVampireLanguage.g:554:1: ( ruleVLSUnitaryFormula EOF ) - // InternalVampireLanguage.g:555:1: ruleVLSUnitaryFormula EOF + // InternalVampireLanguage.g:579:1: ( ruleVLSUnitaryFormula EOF ) + // InternalVampireLanguage.g:580:1: ruleVLSUnitaryFormula EOF { before(grammarAccess.getVLSUnitaryFormulaRule()); pushFollow(FOLLOW_1); @@ -1701,21 +1778,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSUnitaryFormula" - // InternalVampireLanguage.g:562:1: ruleVLSUnitaryFormula : ( ( rule__VLSUnitaryFormula__Alternatives ) ) ; + // InternalVampireLanguage.g:587:1: ruleVLSUnitaryFormula : ( ( rule__VLSUnitaryFormula__Alternatives ) ) ; public final void ruleVLSUnitaryFormula() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:566:2: ( ( ( rule__VLSUnitaryFormula__Alternatives ) ) ) - // InternalVampireLanguage.g:567:2: ( ( rule__VLSUnitaryFormula__Alternatives ) ) + // InternalVampireLanguage.g:591:2: ( ( ( rule__VLSUnitaryFormula__Alternatives ) ) ) + // InternalVampireLanguage.g:592:2: ( ( rule__VLSUnitaryFormula__Alternatives ) ) { - // InternalVampireLanguage.g:567:2: ( ( rule__VLSUnitaryFormula__Alternatives ) ) - // InternalVampireLanguage.g:568:3: ( rule__VLSUnitaryFormula__Alternatives ) + // InternalVampireLanguage.g:592:2: ( ( rule__VLSUnitaryFormula__Alternatives ) ) + // InternalVampireLanguage.g:593:3: ( rule__VLSUnitaryFormula__Alternatives ) { before(grammarAccess.getVLSUnitaryFormulaAccess().getAlternatives()); - // InternalVampireLanguage.g:569:3: ( rule__VLSUnitaryFormula__Alternatives ) - // InternalVampireLanguage.g:569:4: rule__VLSUnitaryFormula__Alternatives + // InternalVampireLanguage.g:594:3: ( rule__VLSUnitaryFormula__Alternatives ) + // InternalVampireLanguage.g:594:4: rule__VLSUnitaryFormula__Alternatives { pushFollow(FOLLOW_2); rule__VLSUnitaryFormula__Alternatives(); @@ -1748,11 +1825,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSUniversalQuantifier" - // InternalVampireLanguage.g:578:1: entryRuleVLSUniversalQuantifier : ruleVLSUniversalQuantifier EOF ; + // InternalVampireLanguage.g:603:1: entryRuleVLSUniversalQuantifier : ruleVLSUniversalQuantifier EOF ; public final void entryRuleVLSUniversalQuantifier() throws RecognitionException { try { - // InternalVampireLanguage.g:579:1: ( ruleVLSUniversalQuantifier EOF ) - // InternalVampireLanguage.g:580:1: ruleVLSUniversalQuantifier EOF + // InternalVampireLanguage.g:604:1: ( ruleVLSUniversalQuantifier EOF ) + // InternalVampireLanguage.g:605:1: ruleVLSUniversalQuantifier EOF { before(grammarAccess.getVLSUniversalQuantifierRule()); pushFollow(FOLLOW_1); @@ -1778,21 +1855,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSUniversalQuantifier" - // InternalVampireLanguage.g:587:1: ruleVLSUniversalQuantifier : ( ( rule__VLSUniversalQuantifier__Group__0 ) ) ; + // InternalVampireLanguage.g:612:1: ruleVLSUniversalQuantifier : ( ( rule__VLSUniversalQuantifier__Group__0 ) ) ; public final void ruleVLSUniversalQuantifier() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:591:2: ( ( ( rule__VLSUniversalQuantifier__Group__0 ) ) ) - // InternalVampireLanguage.g:592:2: ( ( rule__VLSUniversalQuantifier__Group__0 ) ) + // InternalVampireLanguage.g:616:2: ( ( ( rule__VLSUniversalQuantifier__Group__0 ) ) ) + // InternalVampireLanguage.g:617:2: ( ( rule__VLSUniversalQuantifier__Group__0 ) ) { - // InternalVampireLanguage.g:592:2: ( ( rule__VLSUniversalQuantifier__Group__0 ) ) - // InternalVampireLanguage.g:593:3: ( rule__VLSUniversalQuantifier__Group__0 ) + // InternalVampireLanguage.g:617:2: ( ( rule__VLSUniversalQuantifier__Group__0 ) ) + // InternalVampireLanguage.g:618:3: ( rule__VLSUniversalQuantifier__Group__0 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getGroup()); - // InternalVampireLanguage.g:594:3: ( rule__VLSUniversalQuantifier__Group__0 ) - // InternalVampireLanguage.g:594:4: rule__VLSUniversalQuantifier__Group__0 + // InternalVampireLanguage.g:619:3: ( rule__VLSUniversalQuantifier__Group__0 ) + // InternalVampireLanguage.g:619:4: rule__VLSUniversalQuantifier__Group__0 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__Group__0(); @@ -1825,11 +1902,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSExistentialQuantifier" - // InternalVampireLanguage.g:603:1: entryRuleVLSExistentialQuantifier : ruleVLSExistentialQuantifier EOF ; + // InternalVampireLanguage.g:628:1: entryRuleVLSExistentialQuantifier : ruleVLSExistentialQuantifier EOF ; public final void entryRuleVLSExistentialQuantifier() throws RecognitionException { try { - // InternalVampireLanguage.g:604:1: ( ruleVLSExistentialQuantifier EOF ) - // InternalVampireLanguage.g:605:1: ruleVLSExistentialQuantifier EOF + // InternalVampireLanguage.g:629:1: ( ruleVLSExistentialQuantifier EOF ) + // InternalVampireLanguage.g:630:1: ruleVLSExistentialQuantifier EOF { before(grammarAccess.getVLSExistentialQuantifierRule()); pushFollow(FOLLOW_1); @@ -1855,21 +1932,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSExistentialQuantifier" - // InternalVampireLanguage.g:612:1: ruleVLSExistentialQuantifier : ( ( rule__VLSExistentialQuantifier__Group__0 ) ) ; + // InternalVampireLanguage.g:637:1: ruleVLSExistentialQuantifier : ( ( rule__VLSExistentialQuantifier__Group__0 ) ) ; public final void ruleVLSExistentialQuantifier() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:616:2: ( ( ( rule__VLSExistentialQuantifier__Group__0 ) ) ) - // InternalVampireLanguage.g:617:2: ( ( rule__VLSExistentialQuantifier__Group__0 ) ) + // InternalVampireLanguage.g:641:2: ( ( ( rule__VLSExistentialQuantifier__Group__0 ) ) ) + // InternalVampireLanguage.g:642:2: ( ( rule__VLSExistentialQuantifier__Group__0 ) ) { - // InternalVampireLanguage.g:617:2: ( ( rule__VLSExistentialQuantifier__Group__0 ) ) - // InternalVampireLanguage.g:618:3: ( rule__VLSExistentialQuantifier__Group__0 ) + // InternalVampireLanguage.g:642:2: ( ( rule__VLSExistentialQuantifier__Group__0 ) ) + // InternalVampireLanguage.g:643:3: ( rule__VLSExistentialQuantifier__Group__0 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getGroup()); - // InternalVampireLanguage.g:619:3: ( rule__VLSExistentialQuantifier__Group__0 ) - // InternalVampireLanguage.g:619:4: rule__VLSExistentialQuantifier__Group__0 + // InternalVampireLanguage.g:644:3: ( rule__VLSExistentialQuantifier__Group__0 ) + // InternalVampireLanguage.g:644:4: rule__VLSExistentialQuantifier__Group__0 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__Group__0(); @@ -1902,11 +1979,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSUnaryNegation" - // InternalVampireLanguage.g:628:1: entryRuleVLSUnaryNegation : ruleVLSUnaryNegation EOF ; + // InternalVampireLanguage.g:653:1: entryRuleVLSUnaryNegation : ruleVLSUnaryNegation EOF ; public final void entryRuleVLSUnaryNegation() throws RecognitionException { try { - // InternalVampireLanguage.g:629:1: ( ruleVLSUnaryNegation EOF ) - // InternalVampireLanguage.g:630:1: ruleVLSUnaryNegation EOF + // InternalVampireLanguage.g:654:1: ( ruleVLSUnaryNegation EOF ) + // InternalVampireLanguage.g:655:1: ruleVLSUnaryNegation EOF { before(grammarAccess.getVLSUnaryNegationRule()); pushFollow(FOLLOW_1); @@ -1932,21 +2009,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSUnaryNegation" - // InternalVampireLanguage.g:637:1: ruleVLSUnaryNegation : ( ( rule__VLSUnaryNegation__Group__0 ) ) ; + // InternalVampireLanguage.g:662:1: ruleVLSUnaryNegation : ( ( rule__VLSUnaryNegation__Group__0 ) ) ; public final void ruleVLSUnaryNegation() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:641:2: ( ( ( rule__VLSUnaryNegation__Group__0 ) ) ) - // InternalVampireLanguage.g:642:2: ( ( rule__VLSUnaryNegation__Group__0 ) ) + // InternalVampireLanguage.g:666:2: ( ( ( rule__VLSUnaryNegation__Group__0 ) ) ) + // InternalVampireLanguage.g:667:2: ( ( rule__VLSUnaryNegation__Group__0 ) ) { - // InternalVampireLanguage.g:642:2: ( ( rule__VLSUnaryNegation__Group__0 ) ) - // InternalVampireLanguage.g:643:3: ( rule__VLSUnaryNegation__Group__0 ) + // InternalVampireLanguage.g:667:2: ( ( rule__VLSUnaryNegation__Group__0 ) ) + // InternalVampireLanguage.g:668:3: ( rule__VLSUnaryNegation__Group__0 ) { before(grammarAccess.getVLSUnaryNegationAccess().getGroup()); - // InternalVampireLanguage.g:644:3: ( rule__VLSUnaryNegation__Group__0 ) - // InternalVampireLanguage.g:644:4: rule__VLSUnaryNegation__Group__0 + // InternalVampireLanguage.g:669:3: ( rule__VLSUnaryNegation__Group__0 ) + // InternalVampireLanguage.g:669:4: rule__VLSUnaryNegation__Group__0 { pushFollow(FOLLOW_2); rule__VLSUnaryNegation__Group__0(); @@ -1979,11 +2056,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSUnaryInfix" - // InternalVampireLanguage.g:653:1: entryRuleVLSUnaryInfix : ruleVLSUnaryInfix EOF ; + // InternalVampireLanguage.g:678:1: entryRuleVLSUnaryInfix : ruleVLSUnaryInfix EOF ; public final void entryRuleVLSUnaryInfix() throws RecognitionException { try { - // InternalVampireLanguage.g:654:1: ( ruleVLSUnaryInfix EOF ) - // InternalVampireLanguage.g:655:1: ruleVLSUnaryInfix EOF + // InternalVampireLanguage.g:679:1: ( ruleVLSUnaryInfix EOF ) + // InternalVampireLanguage.g:680:1: ruleVLSUnaryInfix EOF { before(grammarAccess.getVLSUnaryInfixRule()); pushFollow(FOLLOW_1); @@ -2009,21 +2086,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSUnaryInfix" - // InternalVampireLanguage.g:662:1: ruleVLSUnaryInfix : ( ( rule__VLSUnaryInfix__Group__0 ) ) ; + // InternalVampireLanguage.g:687:1: ruleVLSUnaryInfix : ( ( rule__VLSUnaryInfix__Group__0 ) ) ; public final void ruleVLSUnaryInfix() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:666:2: ( ( ( rule__VLSUnaryInfix__Group__0 ) ) ) - // InternalVampireLanguage.g:667:2: ( ( rule__VLSUnaryInfix__Group__0 ) ) + // InternalVampireLanguage.g:691:2: ( ( ( rule__VLSUnaryInfix__Group__0 ) ) ) + // InternalVampireLanguage.g:692:2: ( ( rule__VLSUnaryInfix__Group__0 ) ) { - // InternalVampireLanguage.g:667:2: ( ( rule__VLSUnaryInfix__Group__0 ) ) - // InternalVampireLanguage.g:668:3: ( rule__VLSUnaryInfix__Group__0 ) + // InternalVampireLanguage.g:692:2: ( ( rule__VLSUnaryInfix__Group__0 ) ) + // InternalVampireLanguage.g:693:3: ( rule__VLSUnaryInfix__Group__0 ) { before(grammarAccess.getVLSUnaryInfixAccess().getGroup()); - // InternalVampireLanguage.g:669:3: ( rule__VLSUnaryInfix__Group__0 ) - // InternalVampireLanguage.g:669:4: rule__VLSUnaryInfix__Group__0 + // InternalVampireLanguage.g:694:3: ( rule__VLSUnaryInfix__Group__0 ) + // InternalVampireLanguage.g:694:4: rule__VLSUnaryInfix__Group__0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group__0(); @@ -2056,11 +2133,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSAtomic" - // InternalVampireLanguage.g:678:1: entryRuleVLSAtomic : ruleVLSAtomic EOF ; + // InternalVampireLanguage.g:703:1: entryRuleVLSAtomic : ruleVLSAtomic EOF ; public final void entryRuleVLSAtomic() throws RecognitionException { try { - // InternalVampireLanguage.g:679:1: ( ruleVLSAtomic EOF ) - // InternalVampireLanguage.g:680:1: ruleVLSAtomic EOF + // InternalVampireLanguage.g:704:1: ( ruleVLSAtomic EOF ) + // InternalVampireLanguage.g:705:1: ruleVLSAtomic EOF { before(grammarAccess.getVLSAtomicRule()); pushFollow(FOLLOW_1); @@ -2086,21 +2163,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSAtomic" - // InternalVampireLanguage.g:687:1: ruleVLSAtomic : ( ( rule__VLSAtomic__Alternatives ) ) ; + // InternalVampireLanguage.g:712:1: ruleVLSAtomic : ( ( rule__VLSAtomic__Alternatives ) ) ; public final void ruleVLSAtomic() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:691:2: ( ( ( rule__VLSAtomic__Alternatives ) ) ) - // InternalVampireLanguage.g:692:2: ( ( rule__VLSAtomic__Alternatives ) ) + // InternalVampireLanguage.g:716:2: ( ( ( rule__VLSAtomic__Alternatives ) ) ) + // InternalVampireLanguage.g:717:2: ( ( rule__VLSAtomic__Alternatives ) ) { - // InternalVampireLanguage.g:692:2: ( ( rule__VLSAtomic__Alternatives ) ) - // InternalVampireLanguage.g:693:3: ( rule__VLSAtomic__Alternatives ) + // InternalVampireLanguage.g:717:2: ( ( rule__VLSAtomic__Alternatives ) ) + // InternalVampireLanguage.g:718:3: ( rule__VLSAtomic__Alternatives ) { before(grammarAccess.getVLSAtomicAccess().getAlternatives()); - // InternalVampireLanguage.g:694:3: ( rule__VLSAtomic__Alternatives ) - // InternalVampireLanguage.g:694:4: rule__VLSAtomic__Alternatives + // InternalVampireLanguage.g:719:3: ( rule__VLSAtomic__Alternatives ) + // InternalVampireLanguage.g:719:4: rule__VLSAtomic__Alternatives { pushFollow(FOLLOW_2); rule__VLSAtomic__Alternatives(); @@ -2133,11 +2210,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSAtomicConstant" - // InternalVampireLanguage.g:703:1: entryRuleVLSAtomicConstant : ruleVLSAtomicConstant EOF ; + // InternalVampireLanguage.g:728:1: entryRuleVLSAtomicConstant : ruleVLSAtomicConstant EOF ; public final void entryRuleVLSAtomicConstant() throws RecognitionException { try { - // InternalVampireLanguage.g:704:1: ( ruleVLSAtomicConstant EOF ) - // InternalVampireLanguage.g:705:1: ruleVLSAtomicConstant EOF + // InternalVampireLanguage.g:729:1: ( ruleVLSAtomicConstant EOF ) + // InternalVampireLanguage.g:730:1: ruleVLSAtomicConstant EOF { before(grammarAccess.getVLSAtomicConstantRule()); pushFollow(FOLLOW_1); @@ -2163,21 +2240,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSAtomicConstant" - // InternalVampireLanguage.g:712:1: ruleVLSAtomicConstant : ( ( rule__VLSAtomicConstant__Alternatives ) ) ; + // InternalVampireLanguage.g:737:1: ruleVLSAtomicConstant : ( ( rule__VLSAtomicConstant__Alternatives ) ) ; public final void ruleVLSAtomicConstant() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:716:2: ( ( ( rule__VLSAtomicConstant__Alternatives ) ) ) - // InternalVampireLanguage.g:717:2: ( ( rule__VLSAtomicConstant__Alternatives ) ) + // InternalVampireLanguage.g:741:2: ( ( ( rule__VLSAtomicConstant__Alternatives ) ) ) + // InternalVampireLanguage.g:742:2: ( ( rule__VLSAtomicConstant__Alternatives ) ) { - // InternalVampireLanguage.g:717:2: ( ( rule__VLSAtomicConstant__Alternatives ) ) - // InternalVampireLanguage.g:718:3: ( rule__VLSAtomicConstant__Alternatives ) + // InternalVampireLanguage.g:742:2: ( ( rule__VLSAtomicConstant__Alternatives ) ) + // InternalVampireLanguage.g:743:3: ( rule__VLSAtomicConstant__Alternatives ) { before(grammarAccess.getVLSAtomicConstantAccess().getAlternatives()); - // InternalVampireLanguage.g:719:3: ( rule__VLSAtomicConstant__Alternatives ) - // InternalVampireLanguage.g:719:4: rule__VLSAtomicConstant__Alternatives + // InternalVampireLanguage.g:744:3: ( rule__VLSAtomicConstant__Alternatives ) + // InternalVampireLanguage.g:744:4: rule__VLSAtomicConstant__Alternatives { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Alternatives(); @@ -2210,11 +2287,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSAtomicFunction" - // InternalVampireLanguage.g:728:1: entryRuleVLSAtomicFunction : ruleVLSAtomicFunction EOF ; + // InternalVampireLanguage.g:753:1: entryRuleVLSAtomicFunction : ruleVLSAtomicFunction EOF ; public final void entryRuleVLSAtomicFunction() throws RecognitionException { try { - // InternalVampireLanguage.g:729:1: ( ruleVLSAtomicFunction EOF ) - // InternalVampireLanguage.g:730:1: ruleVLSAtomicFunction EOF + // InternalVampireLanguage.g:754:1: ( ruleVLSAtomicFunction EOF ) + // InternalVampireLanguage.g:755:1: ruleVLSAtomicFunction EOF { before(grammarAccess.getVLSAtomicFunctionRule()); pushFollow(FOLLOW_1); @@ -2240,21 +2317,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSAtomicFunction" - // InternalVampireLanguage.g:737:1: ruleVLSAtomicFunction : ( ( rule__VLSAtomicFunction__Alternatives ) ) ; + // InternalVampireLanguage.g:762:1: ruleVLSAtomicFunction : ( ( rule__VLSAtomicFunction__Alternatives ) ) ; public final void ruleVLSAtomicFunction() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:741:2: ( ( ( rule__VLSAtomicFunction__Alternatives ) ) ) - // InternalVampireLanguage.g:742:2: ( ( rule__VLSAtomicFunction__Alternatives ) ) + // InternalVampireLanguage.g:766:2: ( ( ( rule__VLSAtomicFunction__Alternatives ) ) ) + // InternalVampireLanguage.g:767:2: ( ( rule__VLSAtomicFunction__Alternatives ) ) { - // InternalVampireLanguage.g:742:2: ( ( rule__VLSAtomicFunction__Alternatives ) ) - // InternalVampireLanguage.g:743:3: ( rule__VLSAtomicFunction__Alternatives ) + // InternalVampireLanguage.g:767:2: ( ( rule__VLSAtomicFunction__Alternatives ) ) + // InternalVampireLanguage.g:768:3: ( rule__VLSAtomicFunction__Alternatives ) { before(grammarAccess.getVLSAtomicFunctionAccess().getAlternatives()); - // InternalVampireLanguage.g:744:3: ( rule__VLSAtomicFunction__Alternatives ) - // InternalVampireLanguage.g:744:4: rule__VLSAtomicFunction__Alternatives + // InternalVampireLanguage.g:769:3: ( rule__VLSAtomicFunction__Alternatives ) + // InternalVampireLanguage.g:769:4: rule__VLSAtomicFunction__Alternatives { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Alternatives(); @@ -2287,11 +2364,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSVariable" - // InternalVampireLanguage.g:753:1: entryRuleVLSVariable : ruleVLSVariable EOF ; + // InternalVampireLanguage.g:778:1: entryRuleVLSVariable : ruleVLSVariable EOF ; public final void entryRuleVLSVariable() throws RecognitionException { try { - // InternalVampireLanguage.g:754:1: ( ruleVLSVariable EOF ) - // InternalVampireLanguage.g:755:1: ruleVLSVariable EOF + // InternalVampireLanguage.g:779:1: ( ruleVLSVariable EOF ) + // InternalVampireLanguage.g:780:1: ruleVLSVariable EOF { before(grammarAccess.getVLSVariableRule()); pushFollow(FOLLOW_1); @@ -2317,21 +2394,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSVariable" - // InternalVampireLanguage.g:762:1: ruleVLSVariable : ( ( rule__VLSVariable__NameAssignment ) ) ; + // InternalVampireLanguage.g:787:1: ruleVLSVariable : ( ( rule__VLSVariable__NameAssignment ) ) ; public final void ruleVLSVariable() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:766:2: ( ( ( rule__VLSVariable__NameAssignment ) ) ) - // InternalVampireLanguage.g:767:2: ( ( rule__VLSVariable__NameAssignment ) ) + // InternalVampireLanguage.g:791:2: ( ( ( rule__VLSVariable__NameAssignment ) ) ) + // InternalVampireLanguage.g:792:2: ( ( rule__VLSVariable__NameAssignment ) ) { - // InternalVampireLanguage.g:767:2: ( ( rule__VLSVariable__NameAssignment ) ) - // InternalVampireLanguage.g:768:3: ( rule__VLSVariable__NameAssignment ) + // InternalVampireLanguage.g:792:2: ( ( rule__VLSVariable__NameAssignment ) ) + // InternalVampireLanguage.g:793:3: ( rule__VLSVariable__NameAssignment ) { before(grammarAccess.getVLSVariableAccess().getNameAssignment()); - // InternalVampireLanguage.g:769:3: ( rule__VLSVariable__NameAssignment ) - // InternalVampireLanguage.g:769:4: rule__VLSVariable__NameAssignment + // InternalVampireLanguage.g:794:3: ( rule__VLSVariable__NameAssignment ) + // InternalVampireLanguage.g:794:4: rule__VLSVariable__NameAssignment { pushFollow(FOLLOW_2); rule__VLSVariable__NameAssignment(); @@ -2364,11 +2441,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSFofTerm" - // InternalVampireLanguage.g:778:1: entryRuleVLSFofTerm : ruleVLSFofTerm EOF ; + // InternalVampireLanguage.g:803:1: entryRuleVLSFofTerm : ruleVLSFofTerm EOF ; public final void entryRuleVLSFofTerm() throws RecognitionException { try { - // InternalVampireLanguage.g:779:1: ( ruleVLSFofTerm EOF ) - // InternalVampireLanguage.g:780:1: ruleVLSFofTerm EOF + // InternalVampireLanguage.g:804:1: ( ruleVLSFofTerm EOF ) + // InternalVampireLanguage.g:805:1: ruleVLSFofTerm EOF { before(grammarAccess.getVLSFofTermRule()); pushFollow(FOLLOW_1); @@ -2394,21 +2471,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSFofTerm" - // InternalVampireLanguage.g:787:1: ruleVLSFofTerm : ( ( rule__VLSFofTerm__Alternatives ) ) ; + // InternalVampireLanguage.g:812:1: ruleVLSFofTerm : ( ( rule__VLSFofTerm__Alternatives ) ) ; public final void ruleVLSFofTerm() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:791:2: ( ( ( rule__VLSFofTerm__Alternatives ) ) ) - // InternalVampireLanguage.g:792:2: ( ( rule__VLSFofTerm__Alternatives ) ) + // InternalVampireLanguage.g:816:2: ( ( ( rule__VLSFofTerm__Alternatives ) ) ) + // InternalVampireLanguage.g:817:2: ( ( rule__VLSFofTerm__Alternatives ) ) { - // InternalVampireLanguage.g:792:2: ( ( rule__VLSFofTerm__Alternatives ) ) - // InternalVampireLanguage.g:793:3: ( rule__VLSFofTerm__Alternatives ) + // InternalVampireLanguage.g:817:2: ( ( rule__VLSFofTerm__Alternatives ) ) + // InternalVampireLanguage.g:818:3: ( rule__VLSFofTerm__Alternatives ) { before(grammarAccess.getVLSFofTermAccess().getAlternatives()); - // InternalVampireLanguage.g:794:3: ( rule__VLSFofTerm__Alternatives ) - // InternalVampireLanguage.g:794:4: rule__VLSFofTerm__Alternatives + // InternalVampireLanguage.g:819:3: ( rule__VLSFofTerm__Alternatives ) + // InternalVampireLanguage.g:819:4: rule__VLSFofTerm__Alternatives { pushFollow(FOLLOW_2); rule__VLSFofTerm__Alternatives(); @@ -2441,11 +2518,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSFunctionAsTerm" - // InternalVampireLanguage.g:803:1: entryRuleVLSFunctionAsTerm : ruleVLSFunctionAsTerm EOF ; + // InternalVampireLanguage.g:828:1: entryRuleVLSFunctionAsTerm : ruleVLSFunctionAsTerm EOF ; public final void entryRuleVLSFunctionAsTerm() throws RecognitionException { try { - // InternalVampireLanguage.g:804:1: ( ruleVLSFunctionAsTerm EOF ) - // InternalVampireLanguage.g:805:1: ruleVLSFunctionAsTerm EOF + // InternalVampireLanguage.g:829:1: ( ruleVLSFunctionAsTerm EOF ) + // InternalVampireLanguage.g:830:1: ruleVLSFunctionAsTerm EOF { before(grammarAccess.getVLSFunctionAsTermRule()); pushFollow(FOLLOW_1); @@ -2471,21 +2548,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSFunctionAsTerm" - // InternalVampireLanguage.g:812:1: ruleVLSFunctionAsTerm : ( ( rule__VLSFunctionAsTerm__Group__0 ) ) ; + // InternalVampireLanguage.g:837:1: ruleVLSFunctionAsTerm : ( ( rule__VLSFunctionAsTerm__Group__0 ) ) ; public final void ruleVLSFunctionAsTerm() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:816:2: ( ( ( rule__VLSFunctionAsTerm__Group__0 ) ) ) - // InternalVampireLanguage.g:817:2: ( ( rule__VLSFunctionAsTerm__Group__0 ) ) + // InternalVampireLanguage.g:841:2: ( ( ( rule__VLSFunctionAsTerm__Group__0 ) ) ) + // InternalVampireLanguage.g:842:2: ( ( rule__VLSFunctionAsTerm__Group__0 ) ) { - // InternalVampireLanguage.g:817:2: ( ( rule__VLSFunctionAsTerm__Group__0 ) ) - // InternalVampireLanguage.g:818:3: ( rule__VLSFunctionAsTerm__Group__0 ) + // InternalVampireLanguage.g:842:2: ( ( rule__VLSFunctionAsTerm__Group__0 ) ) + // InternalVampireLanguage.g:843:3: ( rule__VLSFunctionAsTerm__Group__0 ) { before(grammarAccess.getVLSFunctionAsTermAccess().getGroup()); - // InternalVampireLanguage.g:819:3: ( rule__VLSFunctionAsTerm__Group__0 ) - // InternalVampireLanguage.g:819:4: rule__VLSFunctionAsTerm__Group__0 + // InternalVampireLanguage.g:844:3: ( rule__VLSFunctionAsTerm__Group__0 ) + // InternalVampireLanguage.g:844:4: rule__VLSFunctionAsTerm__Group__0 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__Group__0(); @@ -2518,11 +2595,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "entryRuleVLSDefinedTerm" - // InternalVampireLanguage.g:828:1: entryRuleVLSDefinedTerm : ruleVLSDefinedTerm EOF ; + // InternalVampireLanguage.g:853:1: entryRuleVLSDefinedTerm : ruleVLSDefinedTerm EOF ; public final void entryRuleVLSDefinedTerm() throws RecognitionException { try { - // InternalVampireLanguage.g:829:1: ( ruleVLSDefinedTerm EOF ) - // InternalVampireLanguage.g:830:1: ruleVLSDefinedTerm EOF + // InternalVampireLanguage.g:854:1: ( ruleVLSDefinedTerm EOF ) + // InternalVampireLanguage.g:855:1: ruleVLSDefinedTerm EOF { before(grammarAccess.getVLSDefinedTermRule()); pushFollow(FOLLOW_1); @@ -2548,21 +2625,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "ruleVLSDefinedTerm" - // InternalVampireLanguage.g:837:1: ruleVLSDefinedTerm : ( ( rule__VLSDefinedTerm__Alternatives ) ) ; + // InternalVampireLanguage.g:862:1: ruleVLSDefinedTerm : ( ( rule__VLSDefinedTerm__Alternatives ) ) ; public final void ruleVLSDefinedTerm() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:841:2: ( ( ( rule__VLSDefinedTerm__Alternatives ) ) ) - // InternalVampireLanguage.g:842:2: ( ( rule__VLSDefinedTerm__Alternatives ) ) + // InternalVampireLanguage.g:866:2: ( ( ( rule__VLSDefinedTerm__Alternatives ) ) ) + // InternalVampireLanguage.g:867:2: ( ( rule__VLSDefinedTerm__Alternatives ) ) { - // InternalVampireLanguage.g:842:2: ( ( rule__VLSDefinedTerm__Alternatives ) ) - // InternalVampireLanguage.g:843:3: ( rule__VLSDefinedTerm__Alternatives ) + // InternalVampireLanguage.g:867:2: ( ( rule__VLSDefinedTerm__Alternatives ) ) + // InternalVampireLanguage.g:868:3: ( rule__VLSDefinedTerm__Alternatives ) { before(grammarAccess.getVLSDefinedTermAccess().getAlternatives()); - // InternalVampireLanguage.g:844:3: ( rule__VLSDefinedTerm__Alternatives ) - // InternalVampireLanguage.g:844:4: rule__VLSDefinedTerm__Alternatives + // InternalVampireLanguage.g:869:3: ( rule__VLSDefinedTerm__Alternatives ) + // InternalVampireLanguage.g:869:4: rule__VLSDefinedTerm__Alternatives { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__Alternatives(); @@ -2595,13 +2672,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VampireModel__Alternatives" - // InternalVampireLanguage.g:852:1: rule__VampireModel__Alternatives : ( ( ( rule__VampireModel__CommentsAssignment_0 ) ) | ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) | ( ( rule__VampireModel__FormulasAssignment_2 ) ) | ( ( rule__VampireModel__TfformulasAssignment_3 ) ) ); + // InternalVampireLanguage.g:877:1: rule__VampireModel__Alternatives : ( ( ( rule__VampireModel__CommentsAssignment_0 ) ) | ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) | ( ( rule__VampireModel__FormulasAssignment_2 ) ) | ( ( rule__VampireModel__TfformulasAssignment_3 ) ) ); public final void rule__VampireModel__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:856:1: ( ( ( rule__VampireModel__CommentsAssignment_0 ) ) | ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) | ( ( rule__VampireModel__FormulasAssignment_2 ) ) | ( ( rule__VampireModel__TfformulasAssignment_3 ) ) ) + // InternalVampireLanguage.g:881:1: ( ( ( rule__VampireModel__CommentsAssignment_0 ) ) | ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) | ( ( rule__VampireModel__FormulasAssignment_2 ) ) | ( ( rule__VampireModel__TfformulasAssignment_3 ) ) ) int alt2=4; switch ( input.LA(1) ) { case RULE_SINGLE_COMMENT: @@ -2636,14 +2713,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt2) { case 1 : - // InternalVampireLanguage.g:857:2: ( ( rule__VampireModel__CommentsAssignment_0 ) ) + // InternalVampireLanguage.g:882:2: ( ( rule__VampireModel__CommentsAssignment_0 ) ) { - // InternalVampireLanguage.g:857:2: ( ( rule__VampireModel__CommentsAssignment_0 ) ) - // InternalVampireLanguage.g:858:3: ( rule__VampireModel__CommentsAssignment_0 ) + // InternalVampireLanguage.g:882:2: ( ( rule__VampireModel__CommentsAssignment_0 ) ) + // InternalVampireLanguage.g:883:3: ( rule__VampireModel__CommentsAssignment_0 ) { before(grammarAccess.getVampireModelAccess().getCommentsAssignment_0()); - // InternalVampireLanguage.g:859:3: ( rule__VampireModel__CommentsAssignment_0 ) - // InternalVampireLanguage.g:859:4: rule__VampireModel__CommentsAssignment_0 + // InternalVampireLanguage.g:884:3: ( rule__VampireModel__CommentsAssignment_0 ) + // InternalVampireLanguage.g:884:4: rule__VampireModel__CommentsAssignment_0 { pushFollow(FOLLOW_2); rule__VampireModel__CommentsAssignment_0(); @@ -2661,14 +2738,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:863:2: ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) + // InternalVampireLanguage.g:888:2: ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) { - // InternalVampireLanguage.g:863:2: ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) - // InternalVampireLanguage.g:864:3: ( rule__VampireModel__ConfirmationsAssignment_1 ) + // InternalVampireLanguage.g:888:2: ( ( rule__VampireModel__ConfirmationsAssignment_1 ) ) + // InternalVampireLanguage.g:889:3: ( rule__VampireModel__ConfirmationsAssignment_1 ) { before(grammarAccess.getVampireModelAccess().getConfirmationsAssignment_1()); - // InternalVampireLanguage.g:865:3: ( rule__VampireModel__ConfirmationsAssignment_1 ) - // InternalVampireLanguage.g:865:4: rule__VampireModel__ConfirmationsAssignment_1 + // InternalVampireLanguage.g:890:3: ( rule__VampireModel__ConfirmationsAssignment_1 ) + // InternalVampireLanguage.g:890:4: rule__VampireModel__ConfirmationsAssignment_1 { pushFollow(FOLLOW_2); rule__VampireModel__ConfirmationsAssignment_1(); @@ -2686,14 +2763,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:869:2: ( ( rule__VampireModel__FormulasAssignment_2 ) ) + // InternalVampireLanguage.g:894:2: ( ( rule__VampireModel__FormulasAssignment_2 ) ) { - // InternalVampireLanguage.g:869:2: ( ( rule__VampireModel__FormulasAssignment_2 ) ) - // InternalVampireLanguage.g:870:3: ( rule__VampireModel__FormulasAssignment_2 ) + // InternalVampireLanguage.g:894:2: ( ( rule__VampireModel__FormulasAssignment_2 ) ) + // InternalVampireLanguage.g:895:3: ( rule__VampireModel__FormulasAssignment_2 ) { before(grammarAccess.getVampireModelAccess().getFormulasAssignment_2()); - // InternalVampireLanguage.g:871:3: ( rule__VampireModel__FormulasAssignment_2 ) - // InternalVampireLanguage.g:871:4: rule__VampireModel__FormulasAssignment_2 + // InternalVampireLanguage.g:896:3: ( rule__VampireModel__FormulasAssignment_2 ) + // InternalVampireLanguage.g:896:4: rule__VampireModel__FormulasAssignment_2 { pushFollow(FOLLOW_2); rule__VampireModel__FormulasAssignment_2(); @@ -2711,14 +2788,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:875:2: ( ( rule__VampireModel__TfformulasAssignment_3 ) ) + // InternalVampireLanguage.g:900:2: ( ( rule__VampireModel__TfformulasAssignment_3 ) ) { - // InternalVampireLanguage.g:875:2: ( ( rule__VampireModel__TfformulasAssignment_3 ) ) - // InternalVampireLanguage.g:876:3: ( rule__VampireModel__TfformulasAssignment_3 ) + // InternalVampireLanguage.g:900:2: ( ( rule__VampireModel__TfformulasAssignment_3 ) ) + // InternalVampireLanguage.g:901:3: ( rule__VampireModel__TfformulasAssignment_3 ) { before(grammarAccess.getVampireModelAccess().getTfformulasAssignment_3()); - // InternalVampireLanguage.g:877:3: ( rule__VampireModel__TfformulasAssignment_3 ) - // InternalVampireLanguage.g:877:4: rule__VampireModel__TfformulasAssignment_3 + // InternalVampireLanguage.g:902:3: ( rule__VampireModel__TfformulasAssignment_3 ) + // InternalVampireLanguage.g:902:4: rule__VampireModel__TfformulasAssignment_3 { pushFollow(FOLLOW_2); rule__VampireModel__TfformulasAssignment_3(); @@ -2753,13 +2830,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Alternatives" - // InternalVampireLanguage.g:885:1: rule__VLSConfirmations__Alternatives : ( ( ( rule__VLSConfirmations__Group_0__0 ) ) | ( ( rule__VLSConfirmations__Group_1__0 ) ) | ( ( rule__VLSConfirmations__Group_2__0 ) ) | ( ( rule__VLSConfirmations__Group_3__0 ) ) ); + // InternalVampireLanguage.g:910:1: rule__VLSConfirmations__Alternatives : ( ( ( rule__VLSConfirmations__Group_0__0 ) ) | ( ( rule__VLSConfirmations__Group_1__0 ) ) | ( ( rule__VLSConfirmations__Group_2__0 ) ) | ( ( rule__VLSConfirmations__Group_3__0 ) ) ); public final void rule__VLSConfirmations__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:889:1: ( ( ( rule__VLSConfirmations__Group_0__0 ) ) | ( ( rule__VLSConfirmations__Group_1__0 ) ) | ( ( rule__VLSConfirmations__Group_2__0 ) ) | ( ( rule__VLSConfirmations__Group_3__0 ) ) ) + // InternalVampireLanguage.g:914:1: ( ( ( rule__VLSConfirmations__Group_0__0 ) ) | ( ( rule__VLSConfirmations__Group_1__0 ) ) | ( ( rule__VLSConfirmations__Group_2__0 ) ) | ( ( rule__VLSConfirmations__Group_3__0 ) ) ) int alt3=4; switch ( input.LA(1) ) { case 39: @@ -2791,14 +2868,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt3) { case 1 : - // InternalVampireLanguage.g:890:2: ( ( rule__VLSConfirmations__Group_0__0 ) ) + // InternalVampireLanguage.g:915:2: ( ( rule__VLSConfirmations__Group_0__0 ) ) { - // InternalVampireLanguage.g:890:2: ( ( rule__VLSConfirmations__Group_0__0 ) ) - // InternalVampireLanguage.g:891:3: ( rule__VLSConfirmations__Group_0__0 ) + // InternalVampireLanguage.g:915:2: ( ( rule__VLSConfirmations__Group_0__0 ) ) + // InternalVampireLanguage.g:916:3: ( rule__VLSConfirmations__Group_0__0 ) { before(grammarAccess.getVLSConfirmationsAccess().getGroup_0()); - // InternalVampireLanguage.g:892:3: ( rule__VLSConfirmations__Group_0__0 ) - // InternalVampireLanguage.g:892:4: rule__VLSConfirmations__Group_0__0 + // InternalVampireLanguage.g:917:3: ( rule__VLSConfirmations__Group_0__0 ) + // InternalVampireLanguage.g:917:4: rule__VLSConfirmations__Group_0__0 { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_0__0(); @@ -2816,14 +2893,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:896:2: ( ( rule__VLSConfirmations__Group_1__0 ) ) + // InternalVampireLanguage.g:921:2: ( ( rule__VLSConfirmations__Group_1__0 ) ) { - // InternalVampireLanguage.g:896:2: ( ( rule__VLSConfirmations__Group_1__0 ) ) - // InternalVampireLanguage.g:897:3: ( rule__VLSConfirmations__Group_1__0 ) + // InternalVampireLanguage.g:921:2: ( ( rule__VLSConfirmations__Group_1__0 ) ) + // InternalVampireLanguage.g:922:3: ( rule__VLSConfirmations__Group_1__0 ) { before(grammarAccess.getVLSConfirmationsAccess().getGroup_1()); - // InternalVampireLanguage.g:898:3: ( rule__VLSConfirmations__Group_1__0 ) - // InternalVampireLanguage.g:898:4: rule__VLSConfirmations__Group_1__0 + // InternalVampireLanguage.g:923:3: ( rule__VLSConfirmations__Group_1__0 ) + // InternalVampireLanguage.g:923:4: rule__VLSConfirmations__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_1__0(); @@ -2841,14 +2918,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:902:2: ( ( rule__VLSConfirmations__Group_2__0 ) ) + // InternalVampireLanguage.g:927:2: ( ( rule__VLSConfirmations__Group_2__0 ) ) { - // InternalVampireLanguage.g:902:2: ( ( rule__VLSConfirmations__Group_2__0 ) ) - // InternalVampireLanguage.g:903:3: ( rule__VLSConfirmations__Group_2__0 ) + // InternalVampireLanguage.g:927:2: ( ( rule__VLSConfirmations__Group_2__0 ) ) + // InternalVampireLanguage.g:928:3: ( rule__VLSConfirmations__Group_2__0 ) { before(grammarAccess.getVLSConfirmationsAccess().getGroup_2()); - // InternalVampireLanguage.g:904:3: ( rule__VLSConfirmations__Group_2__0 ) - // InternalVampireLanguage.g:904:4: rule__VLSConfirmations__Group_2__0 + // InternalVampireLanguage.g:929:3: ( rule__VLSConfirmations__Group_2__0 ) + // InternalVampireLanguage.g:929:4: rule__VLSConfirmations__Group_2__0 { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_2__0(); @@ -2866,14 +2943,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:908:2: ( ( rule__VLSConfirmations__Group_3__0 ) ) + // InternalVampireLanguage.g:933:2: ( ( rule__VLSConfirmations__Group_3__0 ) ) { - // InternalVampireLanguage.g:908:2: ( ( rule__VLSConfirmations__Group_3__0 ) ) - // InternalVampireLanguage.g:909:3: ( rule__VLSConfirmations__Group_3__0 ) + // InternalVampireLanguage.g:933:2: ( ( rule__VLSConfirmations__Group_3__0 ) ) + // InternalVampireLanguage.g:934:3: ( rule__VLSConfirmations__Group_3__0 ) { before(grammarAccess.getVLSConfirmationsAccess().getGroup_3()); - // InternalVampireLanguage.g:910:3: ( rule__VLSConfirmations__Group_3__0 ) - // InternalVampireLanguage.g:910:4: rule__VLSConfirmations__Group_3__0 + // InternalVampireLanguage.g:935:3: ( rule__VLSConfirmations__Group_3__0 ) + // InternalVampireLanguage.g:935:4: rule__VLSConfirmations__Group_3__0 { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_3__0(); @@ -2908,13 +2985,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__NameAlternatives_2_0" - // InternalVampireLanguage.g:918:1: rule__VLSFofFormula__NameAlternatives_2_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SIGNED_LITERAL ) | ( RULE_SINGLE_QUOTE ) ); + // InternalVampireLanguage.g:943:1: rule__VLSFofFormula__NameAlternatives_2_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SIGNED_LITERAL ) | ( RULE_SINGLE_QUOTE ) ); public final void rule__VLSFofFormula__NameAlternatives_2_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:922:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SIGNED_LITERAL ) | ( RULE_SINGLE_QUOTE ) ) + // InternalVampireLanguage.g:947:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SIGNED_LITERAL ) | ( RULE_SINGLE_QUOTE ) ) int alt4=3; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -2941,10 +3018,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt4) { case 1 : - // InternalVampireLanguage.g:923:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:948:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:923:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:924:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:948:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:949:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSFofFormulaAccess().getNameLOWER_WORD_IDTerminalRuleCall_2_0_0()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -2956,10 +3033,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:929:2: ( RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:954:2: ( RULE_SIGNED_LITERAL ) { - // InternalVampireLanguage.g:929:2: ( RULE_SIGNED_LITERAL ) - // InternalVampireLanguage.g:930:3: RULE_SIGNED_LITERAL + // InternalVampireLanguage.g:954:2: ( RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:955:3: RULE_SIGNED_LITERAL { before(grammarAccess.getVLSFofFormulaAccess().getNameSIGNED_LITERALTerminalRuleCall_2_0_1()); match(input,RULE_SIGNED_LITERAL,FOLLOW_2); @@ -2971,10 +3048,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:935:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:960:2: ( RULE_SINGLE_QUOTE ) { - // InternalVampireLanguage.g:935:2: ( RULE_SINGLE_QUOTE ) - // InternalVampireLanguage.g:936:3: RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:960:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:961:3: RULE_SINGLE_QUOTE { before(grammarAccess.getVLSFofFormulaAccess().getNameSINGLE_QUOTETerminalRuleCall_2_0_2()); match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -3003,13 +3080,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffName__Alternatives" - // InternalVampireLanguage.g:945:1: rule__VLSTffName__Alternatives : ( ( ruleVLSTffDeclPred ) | ( ruleVLSTffFinite ) | ( ruleVLSTffDistinct ) ); + // InternalVampireLanguage.g:970:1: rule__VLSTffName__Alternatives : ( ( ruleVLSTffDeclPred ) | ( ruleVLSTffFinite ) | ( ruleVLSTffDistinct ) ); public final void rule__VLSTffName__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:949:1: ( ( ruleVLSTffDeclPred ) | ( ruleVLSTffFinite ) | ( ruleVLSTffDistinct ) ) + // InternalVampireLanguage.g:974:1: ( ( ruleVLSTffDeclPred ) | ( ruleVLSTffFinite ) | ( ruleVLSTffDistinct ) ) int alt5=3; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -3037,10 +3114,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt5) { case 1 : - // InternalVampireLanguage.g:950:2: ( ruleVLSTffDeclPred ) + // InternalVampireLanguage.g:975:2: ( ruleVLSTffDeclPred ) { - // InternalVampireLanguage.g:950:2: ( ruleVLSTffDeclPred ) - // InternalVampireLanguage.g:951:3: ruleVLSTffDeclPred + // InternalVampireLanguage.g:975:2: ( ruleVLSTffDeclPred ) + // InternalVampireLanguage.g:976:3: ruleVLSTffDeclPred { before(grammarAccess.getVLSTffNameAccess().getVLSTffDeclPredParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -3056,10 +3133,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:956:2: ( ruleVLSTffFinite ) + // InternalVampireLanguage.g:981:2: ( ruleVLSTffFinite ) { - // InternalVampireLanguage.g:956:2: ( ruleVLSTffFinite ) - // InternalVampireLanguage.g:957:3: ruleVLSTffFinite + // InternalVampireLanguage.g:981:2: ( ruleVLSTffFinite ) + // InternalVampireLanguage.g:982:3: ruleVLSTffFinite { before(grammarAccess.getVLSTffNameAccess().getVLSTffFiniteParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -3075,10 +3152,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:962:2: ( ruleVLSTffDistinct ) + // InternalVampireLanguage.g:987:2: ( ruleVLSTffDistinct ) { - // InternalVampireLanguage.g:962:2: ( ruleVLSTffDistinct ) - // InternalVampireLanguage.g:963:3: ruleVLSTffDistinct + // InternalVampireLanguage.g:987:2: ( ruleVLSTffDistinct ) + // InternalVampireLanguage.g:988:3: ruleVLSTffDistinct { before(grammarAccess.getVLSTffNameAccess().getVLSTffDistinctParserRuleCall_2()); pushFollow(FOLLOW_2); @@ -3111,13 +3188,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffDeclPred__Alternatives" - // InternalVampireLanguage.g:972:1: rule__VLSTffDeclPred__Alternatives : ( ( ( rule__VLSTffDeclPred__Group_0__0 ) ) | ( RULE_LOWER_WORD_ID ) ); + // InternalVampireLanguage.g:997:1: rule__VLSTffDeclPred__Alternatives : ( ( ( rule__VLSTffDeclPred__Group_0__0 ) ) | ( RULE_LOWER_WORD_ID ) ); public final void rule__VLSTffDeclPred__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:976:1: ( ( ( rule__VLSTffDeclPred__Group_0__0 ) ) | ( RULE_LOWER_WORD_ID ) ) + // InternalVampireLanguage.g:1001:1: ( ( ( rule__VLSTffDeclPred__Group_0__0 ) ) | ( RULE_LOWER_WORD_ID ) ) int alt6=2; int LA6_0 = input.LA(1); @@ -3135,14 +3212,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt6) { case 1 : - // InternalVampireLanguage.g:977:2: ( ( rule__VLSTffDeclPred__Group_0__0 ) ) + // InternalVampireLanguage.g:1002:2: ( ( rule__VLSTffDeclPred__Group_0__0 ) ) { - // InternalVampireLanguage.g:977:2: ( ( rule__VLSTffDeclPred__Group_0__0 ) ) - // InternalVampireLanguage.g:978:3: ( rule__VLSTffDeclPred__Group_0__0 ) + // InternalVampireLanguage.g:1002:2: ( ( rule__VLSTffDeclPred__Group_0__0 ) ) + // InternalVampireLanguage.g:1003:3: ( rule__VLSTffDeclPred__Group_0__0 ) { before(grammarAccess.getVLSTffDeclPredAccess().getGroup_0()); - // InternalVampireLanguage.g:979:3: ( rule__VLSTffDeclPred__Group_0__0 ) - // InternalVampireLanguage.g:979:4: rule__VLSTffDeclPred__Group_0__0 + // InternalVampireLanguage.g:1004:3: ( rule__VLSTffDeclPred__Group_0__0 ) + // InternalVampireLanguage.g:1004:4: rule__VLSTffDeclPred__Group_0__0 { pushFollow(FOLLOW_2); rule__VLSTffDeclPred__Group_0__0(); @@ -3160,10 +3237,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:983:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1008:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:983:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:984:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:1008:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1009:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSTffDeclPredAccess().getLOWER_WORD_IDTerminalRuleCall_1()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -3192,13 +3269,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSRole__Alternatives" - // InternalVampireLanguage.g:993:1: rule__VLSRole__Alternatives : ( ( 'axiom' ) | ( 'conjecture' ) | ( 'hypothesis' ) | ( 'definition' ) | ( 'assumption' ) | ( 'lemma' ) | ( 'theorem' ) | ( 'corollary' ) | ( 'negated_conjecture' ) | ( 'plain' ) | ( 'type' ) | ( 'fi_domain' ) | ( 'fi_functors' ) | ( 'fi_predicates' ) | ( 'unknown' ) ); + // InternalVampireLanguage.g:1018:1: rule__VLSRole__Alternatives : ( ( 'axiom' ) | ( 'conjecture' ) | ( 'hypothesis' ) | ( 'definition' ) | ( 'assumption' ) | ( 'lemma' ) | ( 'theorem' ) | ( 'corollary' ) | ( 'negated_conjecture' ) | ( 'plain' ) | ( 'type' ) | ( 'fi_domain' ) | ( 'fi_functors' ) | ( 'fi_predicates' ) | ( 'unknown' ) ); public final void rule__VLSRole__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:997:1: ( ( 'axiom' ) | ( 'conjecture' ) | ( 'hypothesis' ) | ( 'definition' ) | ( 'assumption' ) | ( 'lemma' ) | ( 'theorem' ) | ( 'corollary' ) | ( 'negated_conjecture' ) | ( 'plain' ) | ( 'type' ) | ( 'fi_domain' ) | ( 'fi_functors' ) | ( 'fi_predicates' ) | ( 'unknown' ) ) + // InternalVampireLanguage.g:1022:1: ( ( 'axiom' ) | ( 'conjecture' ) | ( 'hypothesis' ) | ( 'definition' ) | ( 'assumption' ) | ( 'lemma' ) | ( 'theorem' ) | ( 'corollary' ) | ( 'negated_conjecture' ) | ( 'plain' ) | ( 'type' ) | ( 'fi_domain' ) | ( 'fi_functors' ) | ( 'fi_predicates' ) | ( 'unknown' ) ) int alt7=15; switch ( input.LA(1) ) { case 24: @@ -3285,10 +3362,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt7) { case 1 : - // InternalVampireLanguage.g:998:2: ( 'axiom' ) + // InternalVampireLanguage.g:1023:2: ( 'axiom' ) { - // InternalVampireLanguage.g:998:2: ( 'axiom' ) - // InternalVampireLanguage.g:999:3: 'axiom' + // InternalVampireLanguage.g:1023:2: ( 'axiom' ) + // InternalVampireLanguage.g:1024:3: 'axiom' { before(grammarAccess.getVLSRoleAccess().getAxiomKeyword_0()); match(input,24,FOLLOW_2); @@ -3300,10 +3377,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1004:2: ( 'conjecture' ) + // InternalVampireLanguage.g:1029:2: ( 'conjecture' ) { - // InternalVampireLanguage.g:1004:2: ( 'conjecture' ) - // InternalVampireLanguage.g:1005:3: 'conjecture' + // InternalVampireLanguage.g:1029:2: ( 'conjecture' ) + // InternalVampireLanguage.g:1030:3: 'conjecture' { before(grammarAccess.getVLSRoleAccess().getConjectureKeyword_1()); match(input,25,FOLLOW_2); @@ -3315,10 +3392,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1010:2: ( 'hypothesis' ) + // InternalVampireLanguage.g:1035:2: ( 'hypothesis' ) { - // InternalVampireLanguage.g:1010:2: ( 'hypothesis' ) - // InternalVampireLanguage.g:1011:3: 'hypothesis' + // InternalVampireLanguage.g:1035:2: ( 'hypothesis' ) + // InternalVampireLanguage.g:1036:3: 'hypothesis' { before(grammarAccess.getVLSRoleAccess().getHypothesisKeyword_2()); match(input,26,FOLLOW_2); @@ -3330,10 +3407,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1016:2: ( 'definition' ) + // InternalVampireLanguage.g:1041:2: ( 'definition' ) { - // InternalVampireLanguage.g:1016:2: ( 'definition' ) - // InternalVampireLanguage.g:1017:3: 'definition' + // InternalVampireLanguage.g:1041:2: ( 'definition' ) + // InternalVampireLanguage.g:1042:3: 'definition' { before(grammarAccess.getVLSRoleAccess().getDefinitionKeyword_3()); match(input,27,FOLLOW_2); @@ -3345,10 +3422,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 5 : - // InternalVampireLanguage.g:1022:2: ( 'assumption' ) + // InternalVampireLanguage.g:1047:2: ( 'assumption' ) { - // InternalVampireLanguage.g:1022:2: ( 'assumption' ) - // InternalVampireLanguage.g:1023:3: 'assumption' + // InternalVampireLanguage.g:1047:2: ( 'assumption' ) + // InternalVampireLanguage.g:1048:3: 'assumption' { before(grammarAccess.getVLSRoleAccess().getAssumptionKeyword_4()); match(input,28,FOLLOW_2); @@ -3360,10 +3437,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 6 : - // InternalVampireLanguage.g:1028:2: ( 'lemma' ) + // InternalVampireLanguage.g:1053:2: ( 'lemma' ) { - // InternalVampireLanguage.g:1028:2: ( 'lemma' ) - // InternalVampireLanguage.g:1029:3: 'lemma' + // InternalVampireLanguage.g:1053:2: ( 'lemma' ) + // InternalVampireLanguage.g:1054:3: 'lemma' { before(grammarAccess.getVLSRoleAccess().getLemmaKeyword_5()); match(input,29,FOLLOW_2); @@ -3375,10 +3452,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 7 : - // InternalVampireLanguage.g:1034:2: ( 'theorem' ) + // InternalVampireLanguage.g:1059:2: ( 'theorem' ) { - // InternalVampireLanguage.g:1034:2: ( 'theorem' ) - // InternalVampireLanguage.g:1035:3: 'theorem' + // InternalVampireLanguage.g:1059:2: ( 'theorem' ) + // InternalVampireLanguage.g:1060:3: 'theorem' { before(grammarAccess.getVLSRoleAccess().getTheoremKeyword_6()); match(input,30,FOLLOW_2); @@ -3390,10 +3467,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 8 : - // InternalVampireLanguage.g:1040:2: ( 'corollary' ) + // InternalVampireLanguage.g:1065:2: ( 'corollary' ) { - // InternalVampireLanguage.g:1040:2: ( 'corollary' ) - // InternalVampireLanguage.g:1041:3: 'corollary' + // InternalVampireLanguage.g:1065:2: ( 'corollary' ) + // InternalVampireLanguage.g:1066:3: 'corollary' { before(grammarAccess.getVLSRoleAccess().getCorollaryKeyword_7()); match(input,31,FOLLOW_2); @@ -3405,10 +3482,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 9 : - // InternalVampireLanguage.g:1046:2: ( 'negated_conjecture' ) + // InternalVampireLanguage.g:1071:2: ( 'negated_conjecture' ) { - // InternalVampireLanguage.g:1046:2: ( 'negated_conjecture' ) - // InternalVampireLanguage.g:1047:3: 'negated_conjecture' + // InternalVampireLanguage.g:1071:2: ( 'negated_conjecture' ) + // InternalVampireLanguage.g:1072:3: 'negated_conjecture' { before(grammarAccess.getVLSRoleAccess().getNegated_conjectureKeyword_8()); match(input,32,FOLLOW_2); @@ -3420,10 +3497,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 10 : - // InternalVampireLanguage.g:1052:2: ( 'plain' ) + // InternalVampireLanguage.g:1077:2: ( 'plain' ) { - // InternalVampireLanguage.g:1052:2: ( 'plain' ) - // InternalVampireLanguage.g:1053:3: 'plain' + // InternalVampireLanguage.g:1077:2: ( 'plain' ) + // InternalVampireLanguage.g:1078:3: 'plain' { before(grammarAccess.getVLSRoleAccess().getPlainKeyword_9()); match(input,33,FOLLOW_2); @@ -3435,10 +3512,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 11 : - // InternalVampireLanguage.g:1058:2: ( 'type' ) + // InternalVampireLanguage.g:1083:2: ( 'type' ) { - // InternalVampireLanguage.g:1058:2: ( 'type' ) - // InternalVampireLanguage.g:1059:3: 'type' + // InternalVampireLanguage.g:1083:2: ( 'type' ) + // InternalVampireLanguage.g:1084:3: 'type' { before(grammarAccess.getVLSRoleAccess().getTypeKeyword_10()); match(input,34,FOLLOW_2); @@ -3450,10 +3527,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 12 : - // InternalVampireLanguage.g:1064:2: ( 'fi_domain' ) + // InternalVampireLanguage.g:1089:2: ( 'fi_domain' ) { - // InternalVampireLanguage.g:1064:2: ( 'fi_domain' ) - // InternalVampireLanguage.g:1065:3: 'fi_domain' + // InternalVampireLanguage.g:1089:2: ( 'fi_domain' ) + // InternalVampireLanguage.g:1090:3: 'fi_domain' { before(grammarAccess.getVLSRoleAccess().getFi_domainKeyword_11()); match(input,35,FOLLOW_2); @@ -3465,10 +3542,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 13 : - // InternalVampireLanguage.g:1070:2: ( 'fi_functors' ) + // InternalVampireLanguage.g:1095:2: ( 'fi_functors' ) { - // InternalVampireLanguage.g:1070:2: ( 'fi_functors' ) - // InternalVampireLanguage.g:1071:3: 'fi_functors' + // InternalVampireLanguage.g:1095:2: ( 'fi_functors' ) + // InternalVampireLanguage.g:1096:3: 'fi_functors' { before(grammarAccess.getVLSRoleAccess().getFi_functorsKeyword_12()); match(input,36,FOLLOW_2); @@ -3480,10 +3557,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 14 : - // InternalVampireLanguage.g:1076:2: ( 'fi_predicates' ) + // InternalVampireLanguage.g:1101:2: ( 'fi_predicates' ) { - // InternalVampireLanguage.g:1076:2: ( 'fi_predicates' ) - // InternalVampireLanguage.g:1077:3: 'fi_predicates' + // InternalVampireLanguage.g:1101:2: ( 'fi_predicates' ) + // InternalVampireLanguage.g:1102:3: 'fi_predicates' { before(grammarAccess.getVLSRoleAccess().getFi_predicatesKeyword_13()); match(input,37,FOLLOW_2); @@ -3495,10 +3572,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 15 : - // InternalVampireLanguage.g:1082:2: ( 'unknown' ) + // InternalVampireLanguage.g:1107:2: ( 'unknown' ) { - // InternalVampireLanguage.g:1082:2: ( 'unknown' ) - // InternalVampireLanguage.g:1083:3: 'unknown' + // InternalVampireLanguage.g:1107:2: ( 'unknown' ) + // InternalVampireLanguage.g:1108:3: 'unknown' { before(grammarAccess.getVLSRoleAccess().getUnknownKeyword_14()); match(input,38,FOLLOW_2); @@ -3527,13 +3604,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__NameAlternatives_1_0" - // InternalVampireLanguage.g:1092:1: rule__VLSAnnotation__NameAlternatives_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( ruleVLSRole ) ); + // InternalVampireLanguage.g:1117:1: rule__VLSAnnotation__NameAlternatives_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( ruleVLSRole ) ); public final void rule__VLSAnnotation__NameAlternatives_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1096:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( ruleVLSRole ) ) + // InternalVampireLanguage.g:1121:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( ruleVLSRole ) ) int alt8=3; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -3574,10 +3651,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt8) { case 1 : - // InternalVampireLanguage.g:1097:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1122:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:1097:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:1098:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:1122:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1123:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSAnnotationAccess().getNameLOWER_WORD_IDTerminalRuleCall_1_0_0()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -3589,10 +3666,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1103:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1128:2: ( RULE_SINGLE_QUOTE ) { - // InternalVampireLanguage.g:1103:2: ( RULE_SINGLE_QUOTE ) - // InternalVampireLanguage.g:1104:3: RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:1128:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1129:3: RULE_SINGLE_QUOTE { before(grammarAccess.getVLSAnnotationAccess().getNameSINGLE_QUOTETerminalRuleCall_1_0_1()); match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -3604,10 +3681,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1109:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1134:2: ( ruleVLSRole ) { - // InternalVampireLanguage.g:1109:2: ( ruleVLSRole ) - // InternalVampireLanguage.g:1110:3: ruleVLSRole + // InternalVampireLanguage.g:1134:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1135:3: ruleVLSRole { before(grammarAccess.getVLSAnnotationAccess().getNameVLSRoleParserRuleCall_1_0_2()); pushFollow(FOLLOW_2); @@ -3640,21 +3717,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffTerm__Alternatives" - // InternalVampireLanguage.g:1119:1: rule__VLSTffTerm__Alternatives : ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) ); + // InternalVampireLanguage.g:1144:1: rule__VLSTffTerm__Alternatives : ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) | ( ruleVLSCommentTerm ) ); public final void rule__VLSTffTerm__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1123:1: ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) ) - int alt9=2; + // InternalVampireLanguage.g:1148:1: ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) | ( ruleVLSCommentTerm ) ) + int alt9=3; alt9 = dfa9.predict(input); switch (alt9) { case 1 : - // InternalVampireLanguage.g:1124:2: ( ruleVLSTerm ) + // InternalVampireLanguage.g:1149:2: ( ruleVLSTerm ) { - // InternalVampireLanguage.g:1124:2: ( ruleVLSTerm ) - // InternalVampireLanguage.g:1125:3: ruleVLSTerm + // InternalVampireLanguage.g:1149:2: ( ruleVLSTerm ) + // InternalVampireLanguage.g:1150:3: ruleVLSTerm { before(grammarAccess.getVLSTffTermAccess().getVLSTermParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -3670,10 +3747,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1130:2: ( ruleVLSDeclaration ) + // InternalVampireLanguage.g:1155:2: ( ruleVLSDeclaration ) { - // InternalVampireLanguage.g:1130:2: ( ruleVLSDeclaration ) - // InternalVampireLanguage.g:1131:3: ruleVLSDeclaration + // InternalVampireLanguage.g:1155:2: ( ruleVLSDeclaration ) + // InternalVampireLanguage.g:1156:3: ruleVLSDeclaration { before(grammarAccess.getVLSTffTermAccess().getVLSDeclarationParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -3686,6 +3763,25 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } + } + break; + case 3 : + // InternalVampireLanguage.g:1161:2: ( ruleVLSCommentTerm ) + { + // InternalVampireLanguage.g:1161:2: ( ruleVLSCommentTerm ) + // InternalVampireLanguage.g:1162:3: ruleVLSCommentTerm + { + before(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); + pushFollow(FOLLOW_2); + ruleVLSCommentTerm(); + + state._fsp--; + + after(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); + + } + + } break; @@ -3706,13 +3802,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDeclaration__Alternatives" - // InternalVampireLanguage.g:1140:1: rule__VLSDeclaration__Alternatives : ( ( ruleVLSVariableDeclaration ) | ( ruleVLSOtherDeclaration ) ); + // InternalVampireLanguage.g:1171:1: rule__VLSDeclaration__Alternatives : ( ( ruleVLSVariableDeclaration ) | ( ruleVLSOtherDeclaration ) ); public final void rule__VLSDeclaration__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1144:1: ( ( ruleVLSVariableDeclaration ) | ( ruleVLSOtherDeclaration ) ) + // InternalVampireLanguage.g:1175:1: ( ( ruleVLSVariableDeclaration ) | ( ruleVLSOtherDeclaration ) ) int alt10=2; int LA10_0 = input.LA(1); @@ -3730,10 +3826,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt10) { case 1 : - // InternalVampireLanguage.g:1145:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1176:2: ( ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1145:2: ( ruleVLSVariableDeclaration ) - // InternalVampireLanguage.g:1146:3: ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1176:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1177:3: ruleVLSVariableDeclaration { before(grammarAccess.getVLSDeclarationAccess().getVLSVariableDeclarationParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -3749,10 +3845,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1151:2: ( ruleVLSOtherDeclaration ) + // InternalVampireLanguage.g:1182:2: ( ruleVLSOtherDeclaration ) { - // InternalVampireLanguage.g:1151:2: ( ruleVLSOtherDeclaration ) - // InternalVampireLanguage.g:1152:3: ruleVLSOtherDeclaration + // InternalVampireLanguage.g:1182:2: ( ruleVLSOtherDeclaration ) + // InternalVampireLanguage.g:1183:3: ruleVLSOtherDeclaration { before(grammarAccess.getVLSDeclarationAccess().getVLSOtherDeclarationParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -3785,13 +3881,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Alternatives_1" - // InternalVampireLanguage.g:1161:1: rule__VLSBinary__Alternatives_1 : ( ( ( rule__VLSBinary__Group_1_0__0 ) ) | ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) | ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) ); + // InternalVampireLanguage.g:1192:1: rule__VLSBinary__Alternatives_1 : ( ( ( rule__VLSBinary__Group_1_0__0 ) ) | ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) | ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) ); public final void rule__VLSBinary__Alternatives_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1165:1: ( ( ( rule__VLSBinary__Group_1_0__0 ) ) | ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) | ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) ) + // InternalVampireLanguage.g:1196:1: ( ( ( rule__VLSBinary__Group_1_0__0 ) ) | ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) | ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) ) int alt13=3; switch ( input.LA(1) ) { case 64: @@ -3823,14 +3919,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt13) { case 1 : - // InternalVampireLanguage.g:1166:2: ( ( rule__VLSBinary__Group_1_0__0 ) ) + // InternalVampireLanguage.g:1197:2: ( ( rule__VLSBinary__Group_1_0__0 ) ) { - // InternalVampireLanguage.g:1166:2: ( ( rule__VLSBinary__Group_1_0__0 ) ) - // InternalVampireLanguage.g:1167:3: ( rule__VLSBinary__Group_1_0__0 ) + // InternalVampireLanguage.g:1197:2: ( ( rule__VLSBinary__Group_1_0__0 ) ) + // InternalVampireLanguage.g:1198:3: ( rule__VLSBinary__Group_1_0__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0()); - // InternalVampireLanguage.g:1168:3: ( rule__VLSBinary__Group_1_0__0 ) - // InternalVampireLanguage.g:1168:4: rule__VLSBinary__Group_1_0__0 + // InternalVampireLanguage.g:1199:3: ( rule__VLSBinary__Group_1_0__0 ) + // InternalVampireLanguage.g:1199:4: rule__VLSBinary__Group_1_0__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0__0(); @@ -3848,17 +3944,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1172:2: ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) + // InternalVampireLanguage.g:1203:2: ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) { - // InternalVampireLanguage.g:1172:2: ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) - // InternalVampireLanguage.g:1173:3: ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) + // InternalVampireLanguage.g:1203:2: ( ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) ) + // InternalVampireLanguage.g:1204:3: ( ( rule__VLSBinary__Group_1_1__0 ) ) ( ( rule__VLSBinary__Group_1_1__0 )* ) { - // InternalVampireLanguage.g:1173:3: ( ( rule__VLSBinary__Group_1_1__0 ) ) - // InternalVampireLanguage.g:1174:4: ( rule__VLSBinary__Group_1_1__0 ) + // InternalVampireLanguage.g:1204:3: ( ( rule__VLSBinary__Group_1_1__0 ) ) + // InternalVampireLanguage.g:1205:4: ( rule__VLSBinary__Group_1_1__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_1()); - // InternalVampireLanguage.g:1175:4: ( rule__VLSBinary__Group_1_1__0 ) - // InternalVampireLanguage.g:1175:5: rule__VLSBinary__Group_1_1__0 + // InternalVampireLanguage.g:1206:4: ( rule__VLSBinary__Group_1_1__0 ) + // InternalVampireLanguage.g:1206:5: rule__VLSBinary__Group_1_1__0 { pushFollow(FOLLOW_4); rule__VLSBinary__Group_1_1__0(); @@ -3872,11 +3968,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } - // InternalVampireLanguage.g:1178:3: ( ( rule__VLSBinary__Group_1_1__0 )* ) - // InternalVampireLanguage.g:1179:4: ( rule__VLSBinary__Group_1_1__0 )* + // InternalVampireLanguage.g:1209:3: ( ( rule__VLSBinary__Group_1_1__0 )* ) + // InternalVampireLanguage.g:1210:4: ( rule__VLSBinary__Group_1_1__0 )* { before(grammarAccess.getVLSBinaryAccess().getGroup_1_1()); - // InternalVampireLanguage.g:1180:4: ( rule__VLSBinary__Group_1_1__0 )* + // InternalVampireLanguage.g:1211:4: ( rule__VLSBinary__Group_1_1__0 )* loop11: do { int alt11=2; @@ -3889,7 +3985,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt11) { case 1 : - // InternalVampireLanguage.g:1180:5: rule__VLSBinary__Group_1_1__0 + // InternalVampireLanguage.g:1211:5: rule__VLSBinary__Group_1_1__0 { pushFollow(FOLLOW_4); rule__VLSBinary__Group_1_1__0(); @@ -3916,17 +4012,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1185:2: ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) + // InternalVampireLanguage.g:1216:2: ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) { - // InternalVampireLanguage.g:1185:2: ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) - // InternalVampireLanguage.g:1186:3: ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) + // InternalVampireLanguage.g:1216:2: ( ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) ) + // InternalVampireLanguage.g:1217:3: ( ( rule__VLSBinary__Group_1_2__0 ) ) ( ( rule__VLSBinary__Group_1_2__0 )* ) { - // InternalVampireLanguage.g:1186:3: ( ( rule__VLSBinary__Group_1_2__0 ) ) - // InternalVampireLanguage.g:1187:4: ( rule__VLSBinary__Group_1_2__0 ) + // InternalVampireLanguage.g:1217:3: ( ( rule__VLSBinary__Group_1_2__0 ) ) + // InternalVampireLanguage.g:1218:4: ( rule__VLSBinary__Group_1_2__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_2()); - // InternalVampireLanguage.g:1188:4: ( rule__VLSBinary__Group_1_2__0 ) - // InternalVampireLanguage.g:1188:5: rule__VLSBinary__Group_1_2__0 + // InternalVampireLanguage.g:1219:4: ( rule__VLSBinary__Group_1_2__0 ) + // InternalVampireLanguage.g:1219:5: rule__VLSBinary__Group_1_2__0 { pushFollow(FOLLOW_5); rule__VLSBinary__Group_1_2__0(); @@ -3940,11 +4036,11 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } - // InternalVampireLanguage.g:1191:3: ( ( rule__VLSBinary__Group_1_2__0 )* ) - // InternalVampireLanguage.g:1192:4: ( rule__VLSBinary__Group_1_2__0 )* + // InternalVampireLanguage.g:1222:3: ( ( rule__VLSBinary__Group_1_2__0 )* ) + // InternalVampireLanguage.g:1223:4: ( rule__VLSBinary__Group_1_2__0 )* { before(grammarAccess.getVLSBinaryAccess().getGroup_1_2()); - // InternalVampireLanguage.g:1193:4: ( rule__VLSBinary__Group_1_2__0 )* + // InternalVampireLanguage.g:1224:4: ( rule__VLSBinary__Group_1_2__0 )* loop12: do { int alt12=2; @@ -3957,7 +4053,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt12) { case 1 : - // InternalVampireLanguage.g:1193:5: rule__VLSBinary__Group_1_2__0 + // InternalVampireLanguage.g:1224:5: rule__VLSBinary__Group_1_2__0 { pushFollow(FOLLOW_5); rule__VLSBinary__Group_1_2__0(); @@ -4001,13 +4097,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Alternatives_1_0_0" - // InternalVampireLanguage.g:1202:1: rule__VLSBinary__Alternatives_1_0_0 : ( ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) ); + // InternalVampireLanguage.g:1233:1: rule__VLSBinary__Alternatives_1_0_0 : ( ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) ); public final void rule__VLSBinary__Alternatives_1_0_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1206:1: ( ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) ) + // InternalVampireLanguage.g:1237:1: ( ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) | ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) ) int alt14=6; switch ( input.LA(1) ) { case 64: @@ -4049,14 +4145,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt14) { case 1 : - // InternalVampireLanguage.g:1207:2: ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) + // InternalVampireLanguage.g:1238:2: ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) { - // InternalVampireLanguage.g:1207:2: ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) - // InternalVampireLanguage.g:1208:3: ( rule__VLSBinary__Group_1_0_0_0__0 ) + // InternalVampireLanguage.g:1238:2: ( ( rule__VLSBinary__Group_1_0_0_0__0 ) ) + // InternalVampireLanguage.g:1239:3: ( rule__VLSBinary__Group_1_0_0_0__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_0()); - // InternalVampireLanguage.g:1209:3: ( rule__VLSBinary__Group_1_0_0_0__0 ) - // InternalVampireLanguage.g:1209:4: rule__VLSBinary__Group_1_0_0_0__0 + // InternalVampireLanguage.g:1240:3: ( rule__VLSBinary__Group_1_0_0_0__0 ) + // InternalVampireLanguage.g:1240:4: rule__VLSBinary__Group_1_0_0_0__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_0__0(); @@ -4074,14 +4170,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1213:2: ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) + // InternalVampireLanguage.g:1244:2: ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) { - // InternalVampireLanguage.g:1213:2: ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) - // InternalVampireLanguage.g:1214:3: ( rule__VLSBinary__Group_1_0_0_1__0 ) + // InternalVampireLanguage.g:1244:2: ( ( rule__VLSBinary__Group_1_0_0_1__0 ) ) + // InternalVampireLanguage.g:1245:3: ( rule__VLSBinary__Group_1_0_0_1__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_1()); - // InternalVampireLanguage.g:1215:3: ( rule__VLSBinary__Group_1_0_0_1__0 ) - // InternalVampireLanguage.g:1215:4: rule__VLSBinary__Group_1_0_0_1__0 + // InternalVampireLanguage.g:1246:3: ( rule__VLSBinary__Group_1_0_0_1__0 ) + // InternalVampireLanguage.g:1246:4: rule__VLSBinary__Group_1_0_0_1__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_1__0(); @@ -4099,14 +4195,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1219:2: ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) + // InternalVampireLanguage.g:1250:2: ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) { - // InternalVampireLanguage.g:1219:2: ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) - // InternalVampireLanguage.g:1220:3: ( rule__VLSBinary__Group_1_0_0_2__0 ) + // InternalVampireLanguage.g:1250:2: ( ( rule__VLSBinary__Group_1_0_0_2__0 ) ) + // InternalVampireLanguage.g:1251:3: ( rule__VLSBinary__Group_1_0_0_2__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_2()); - // InternalVampireLanguage.g:1221:3: ( rule__VLSBinary__Group_1_0_0_2__0 ) - // InternalVampireLanguage.g:1221:4: rule__VLSBinary__Group_1_0_0_2__0 + // InternalVampireLanguage.g:1252:3: ( rule__VLSBinary__Group_1_0_0_2__0 ) + // InternalVampireLanguage.g:1252:4: rule__VLSBinary__Group_1_0_0_2__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_2__0(); @@ -4124,14 +4220,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1225:2: ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) + // InternalVampireLanguage.g:1256:2: ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) { - // InternalVampireLanguage.g:1225:2: ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) - // InternalVampireLanguage.g:1226:3: ( rule__VLSBinary__Group_1_0_0_3__0 ) + // InternalVampireLanguage.g:1256:2: ( ( rule__VLSBinary__Group_1_0_0_3__0 ) ) + // InternalVampireLanguage.g:1257:3: ( rule__VLSBinary__Group_1_0_0_3__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_3()); - // InternalVampireLanguage.g:1227:3: ( rule__VLSBinary__Group_1_0_0_3__0 ) - // InternalVampireLanguage.g:1227:4: rule__VLSBinary__Group_1_0_0_3__0 + // InternalVampireLanguage.g:1258:3: ( rule__VLSBinary__Group_1_0_0_3__0 ) + // InternalVampireLanguage.g:1258:4: rule__VLSBinary__Group_1_0_0_3__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_3__0(); @@ -4149,14 +4245,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 5 : - // InternalVampireLanguage.g:1231:2: ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) + // InternalVampireLanguage.g:1262:2: ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) { - // InternalVampireLanguage.g:1231:2: ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) - // InternalVampireLanguage.g:1232:3: ( rule__VLSBinary__Group_1_0_0_4__0 ) + // InternalVampireLanguage.g:1262:2: ( ( rule__VLSBinary__Group_1_0_0_4__0 ) ) + // InternalVampireLanguage.g:1263:3: ( rule__VLSBinary__Group_1_0_0_4__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_4()); - // InternalVampireLanguage.g:1233:3: ( rule__VLSBinary__Group_1_0_0_4__0 ) - // InternalVampireLanguage.g:1233:4: rule__VLSBinary__Group_1_0_0_4__0 + // InternalVampireLanguage.g:1264:3: ( rule__VLSBinary__Group_1_0_0_4__0 ) + // InternalVampireLanguage.g:1264:4: rule__VLSBinary__Group_1_0_0_4__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_4__0(); @@ -4174,14 +4270,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 6 : - // InternalVampireLanguage.g:1237:2: ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) + // InternalVampireLanguage.g:1268:2: ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) { - // InternalVampireLanguage.g:1237:2: ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) - // InternalVampireLanguage.g:1238:3: ( rule__VLSBinary__Group_1_0_0_5__0 ) + // InternalVampireLanguage.g:1268:2: ( ( rule__VLSBinary__Group_1_0_0_5__0 ) ) + // InternalVampireLanguage.g:1269:3: ( rule__VLSBinary__Group_1_0_0_5__0 ) { before(grammarAccess.getVLSBinaryAccess().getGroup_1_0_0_5()); - // InternalVampireLanguage.g:1239:3: ( rule__VLSBinary__Group_1_0_0_5__0 ) - // InternalVampireLanguage.g:1239:4: rule__VLSBinary__Group_1_0_0_5__0 + // InternalVampireLanguage.g:1270:3: ( rule__VLSBinary__Group_1_0_0_5__0 ) + // InternalVampireLanguage.g:1270:4: rule__VLSBinary__Group_1_0_0_5__0 { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_5__0(); @@ -4216,13 +4312,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Alternatives" - // InternalVampireLanguage.g:1247:1: rule__VLSUnitaryFormula__Alternatives : ( ( ruleVLSUniversalQuantifier ) | ( ruleVLSExistentialQuantifier ) | ( ruleVLSUnaryNegation ) | ( ruleVLSUnaryInfix ) | ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) ); + // InternalVampireLanguage.g:1278:1: rule__VLSUnitaryFormula__Alternatives : ( ( ruleVLSUniversalQuantifier ) | ( ruleVLSExistentialQuantifier ) | ( ruleVLSUnaryNegation ) | ( ruleVLSUnaryInfix ) | ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) ); public final void rule__VLSUnitaryFormula__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1251:1: ( ( ruleVLSUniversalQuantifier ) | ( ruleVLSExistentialQuantifier ) | ( ruleVLSUnaryNegation ) | ( ruleVLSUnaryInfix ) | ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) ) + // InternalVampireLanguage.g:1282:1: ( ( ruleVLSUniversalQuantifier ) | ( ruleVLSExistentialQuantifier ) | ( ruleVLSUnaryNegation ) | ( ruleVLSUnaryInfix ) | ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) ) int alt15=5; switch ( input.LA(1) ) { case 72: @@ -4283,10 +4379,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt15) { case 1 : - // InternalVampireLanguage.g:1252:2: ( ruleVLSUniversalQuantifier ) + // InternalVampireLanguage.g:1283:2: ( ruleVLSUniversalQuantifier ) { - // InternalVampireLanguage.g:1252:2: ( ruleVLSUniversalQuantifier ) - // InternalVampireLanguage.g:1253:3: ruleVLSUniversalQuantifier + // InternalVampireLanguage.g:1283:2: ( ruleVLSUniversalQuantifier ) + // InternalVampireLanguage.g:1284:3: ruleVLSUniversalQuantifier { before(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUniversalQuantifierParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -4302,10 +4398,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1258:2: ( ruleVLSExistentialQuantifier ) + // InternalVampireLanguage.g:1289:2: ( ruleVLSExistentialQuantifier ) { - // InternalVampireLanguage.g:1258:2: ( ruleVLSExistentialQuantifier ) - // InternalVampireLanguage.g:1259:3: ruleVLSExistentialQuantifier + // InternalVampireLanguage.g:1289:2: ( ruleVLSExistentialQuantifier ) + // InternalVampireLanguage.g:1290:3: ruleVLSExistentialQuantifier { before(grammarAccess.getVLSUnitaryFormulaAccess().getVLSExistentialQuantifierParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -4321,10 +4417,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1264:2: ( ruleVLSUnaryNegation ) + // InternalVampireLanguage.g:1295:2: ( ruleVLSUnaryNegation ) { - // InternalVampireLanguage.g:1264:2: ( ruleVLSUnaryNegation ) - // InternalVampireLanguage.g:1265:3: ruleVLSUnaryNegation + // InternalVampireLanguage.g:1295:2: ( ruleVLSUnaryNegation ) + // InternalVampireLanguage.g:1296:3: ruleVLSUnaryNegation { before(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUnaryNegationParserRuleCall_2()); pushFollow(FOLLOW_2); @@ -4340,10 +4436,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1270:2: ( ruleVLSUnaryInfix ) + // InternalVampireLanguage.g:1301:2: ( ruleVLSUnaryInfix ) { - // InternalVampireLanguage.g:1270:2: ( ruleVLSUnaryInfix ) - // InternalVampireLanguage.g:1271:3: ruleVLSUnaryInfix + // InternalVampireLanguage.g:1301:2: ( ruleVLSUnaryInfix ) + // InternalVampireLanguage.g:1302:3: ruleVLSUnaryInfix { before(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUnaryInfixParserRuleCall_3()); pushFollow(FOLLOW_2); @@ -4359,14 +4455,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 5 : - // InternalVampireLanguage.g:1276:2: ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) + // InternalVampireLanguage.g:1307:2: ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) { - // InternalVampireLanguage.g:1276:2: ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) - // InternalVampireLanguage.g:1277:3: ( rule__VLSUnitaryFormula__Group_4__0 ) + // InternalVampireLanguage.g:1307:2: ( ( rule__VLSUnitaryFormula__Group_4__0 ) ) + // InternalVampireLanguage.g:1308:3: ( rule__VLSUnitaryFormula__Group_4__0 ) { before(grammarAccess.getVLSUnitaryFormulaAccess().getGroup_4()); - // InternalVampireLanguage.g:1278:3: ( rule__VLSUnitaryFormula__Group_4__0 ) - // InternalVampireLanguage.g:1278:4: rule__VLSUnitaryFormula__Group_4__0 + // InternalVampireLanguage.g:1309:3: ( rule__VLSUnitaryFormula__Group_4__0 ) + // InternalVampireLanguage.g:1309:4: rule__VLSUnitaryFormula__Group_4__0 { pushFollow(FOLLOW_2); rule__VLSUnitaryFormula__Group_4__0(); @@ -4401,13 +4497,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0" - // InternalVampireLanguage.g:1286:1: rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); + // InternalVampireLanguage.g:1317:1: rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); public final void rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1290:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1321:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) int alt16=2; int LA16_0 = input.LA(1); @@ -4435,10 +4531,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt16) { case 1 : - // InternalVampireLanguage.g:1291:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1322:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1291:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1292:3: ruleVLSVariable + // InternalVampireLanguage.g:1322:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1323:3: ruleVLSVariable { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_2_0_0()); pushFollow(FOLLOW_2); @@ -4454,10 +4550,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1297:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1328:2: ( ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1297:2: ( ruleVLSVariableDeclaration ) - // InternalVampireLanguage.g:1298:3: ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1328:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1329:3: ruleVLSVariableDeclaration { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_2_0_1()); pushFollow(FOLLOW_2); @@ -4490,13 +4586,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0" - // InternalVampireLanguage.g:1307:1: rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); + // InternalVampireLanguage.g:1338:1: rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); public final void rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1311:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1342:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) int alt17=2; int LA17_0 = input.LA(1); @@ -4524,10 +4620,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt17) { case 1 : - // InternalVampireLanguage.g:1312:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1343:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1312:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1313:3: ruleVLSVariable + // InternalVampireLanguage.g:1343:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1344:3: ruleVLSVariable { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_3_1_0_0()); pushFollow(FOLLOW_2); @@ -4543,10 +4639,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1318:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1349:2: ( ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1318:2: ( ruleVLSVariableDeclaration ) - // InternalVampireLanguage.g:1319:3: ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1349:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1350:3: ruleVLSVariableDeclaration { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_3_1_0_1()); pushFollow(FOLLOW_2); @@ -4579,13 +4675,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0" - // InternalVampireLanguage.g:1328:1: rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); + // InternalVampireLanguage.g:1359:1: rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); public final void rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1332:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1363:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) int alt18=2; int LA18_0 = input.LA(1); @@ -4613,10 +4709,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt18) { case 1 : - // InternalVampireLanguage.g:1333:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1364:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1333:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1334:3: ruleVLSVariable + // InternalVampireLanguage.g:1364:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1365:3: ruleVLSVariable { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_2_0_0()); pushFollow(FOLLOW_2); @@ -4632,10 +4728,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1339:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1370:2: ( ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1339:2: ( ruleVLSVariableDeclaration ) - // InternalVampireLanguage.g:1340:3: ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1370:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1371:3: ruleVLSVariableDeclaration { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_2_0_1()); pushFollow(FOLLOW_2); @@ -4668,25 +4764,25 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0" - // InternalVampireLanguage.g:1349:1: rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); + // InternalVampireLanguage.g:1380:1: rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 : ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ); public final void rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1353:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1384:1: ( ( ruleVLSVariable ) | ( ruleVLSVariableDeclaration ) ) int alt19=2; int LA19_0 = input.LA(1); if ( (LA19_0==RULE_UPPER_WORD_ID) ) { int LA19_1 = input.LA(2); - if ( (LA19_1==50||LA19_1==56) ) { - alt19=1; - } - else if ( (LA19_1==61) ) { + if ( (LA19_1==61) ) { alt19=2; } + else if ( (LA19_1==50||LA19_1==56) ) { + alt19=1; + } else { NoViableAltException nvae = new NoViableAltException("", 19, 1, input); @@ -4702,10 +4798,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt19) { case 1 : - // InternalVampireLanguage.g:1354:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1385:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1354:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1355:3: ruleVLSVariable + // InternalVampireLanguage.g:1385:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1386:3: ruleVLSVariable { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_3_1_0_0()); pushFollow(FOLLOW_2); @@ -4721,10 +4817,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1360:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1391:2: ( ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1360:2: ( ruleVLSVariableDeclaration ) - // InternalVampireLanguage.g:1361:3: ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1391:2: ( ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1392:3: ruleVLSVariableDeclaration { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_3_1_0_1()); pushFollow(FOLLOW_2); @@ -4757,13 +4853,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Alternatives_1_0" - // InternalVampireLanguage.g:1370:1: rule__VLSUnaryInfix__Alternatives_1_0 : ( ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) ); + // InternalVampireLanguage.g:1401:1: rule__VLSUnaryInfix__Alternatives_1_0 : ( ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) ); public final void rule__VLSUnaryInfix__Alternatives_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1374:1: ( ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) ) + // InternalVampireLanguage.g:1405:1: ( ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) | ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) ) int alt20=3; switch ( input.LA(1) ) { case 75: @@ -4790,14 +4886,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt20) { case 1 : - // InternalVampireLanguage.g:1375:2: ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) + // InternalVampireLanguage.g:1406:2: ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) { - // InternalVampireLanguage.g:1375:2: ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) - // InternalVampireLanguage.g:1376:3: ( rule__VLSUnaryInfix__Group_1_0_0__0 ) + // InternalVampireLanguage.g:1406:2: ( ( rule__VLSUnaryInfix__Group_1_0_0__0 ) ) + // InternalVampireLanguage.g:1407:3: ( rule__VLSUnaryInfix__Group_1_0_0__0 ) { before(grammarAccess.getVLSUnaryInfixAccess().getGroup_1_0_0()); - // InternalVampireLanguage.g:1377:3: ( rule__VLSUnaryInfix__Group_1_0_0__0 ) - // InternalVampireLanguage.g:1377:4: rule__VLSUnaryInfix__Group_1_0_0__0 + // InternalVampireLanguage.g:1408:3: ( rule__VLSUnaryInfix__Group_1_0_0__0 ) + // InternalVampireLanguage.g:1408:4: rule__VLSUnaryInfix__Group_1_0_0__0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_0__0(); @@ -4815,14 +4911,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1381:2: ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) + // InternalVampireLanguage.g:1412:2: ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) { - // InternalVampireLanguage.g:1381:2: ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) - // InternalVampireLanguage.g:1382:3: ( rule__VLSUnaryInfix__Group_1_0_1__0 ) + // InternalVampireLanguage.g:1412:2: ( ( rule__VLSUnaryInfix__Group_1_0_1__0 ) ) + // InternalVampireLanguage.g:1413:3: ( rule__VLSUnaryInfix__Group_1_0_1__0 ) { before(grammarAccess.getVLSUnaryInfixAccess().getGroup_1_0_1()); - // InternalVampireLanguage.g:1383:3: ( rule__VLSUnaryInfix__Group_1_0_1__0 ) - // InternalVampireLanguage.g:1383:4: rule__VLSUnaryInfix__Group_1_0_1__0 + // InternalVampireLanguage.g:1414:3: ( rule__VLSUnaryInfix__Group_1_0_1__0 ) + // InternalVampireLanguage.g:1414:4: rule__VLSUnaryInfix__Group_1_0_1__0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_1__0(); @@ -4840,14 +4936,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1387:2: ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) + // InternalVampireLanguage.g:1418:2: ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) { - // InternalVampireLanguage.g:1387:2: ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) - // InternalVampireLanguage.g:1388:3: ( rule__VLSUnaryInfix__Group_1_0_2__0 ) + // InternalVampireLanguage.g:1418:2: ( ( rule__VLSUnaryInfix__Group_1_0_2__0 ) ) + // InternalVampireLanguage.g:1419:3: ( rule__VLSUnaryInfix__Group_1_0_2__0 ) { before(grammarAccess.getVLSUnaryInfixAccess().getGroup_1_0_2()); - // InternalVampireLanguage.g:1389:3: ( rule__VLSUnaryInfix__Group_1_0_2__0 ) - // InternalVampireLanguage.g:1389:4: rule__VLSUnaryInfix__Group_1_0_2__0 + // InternalVampireLanguage.g:1420:3: ( rule__VLSUnaryInfix__Group_1_0_2__0 ) + // InternalVampireLanguage.g:1420:4: rule__VLSUnaryInfix__Group_1_0_2__0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_2__0(); @@ -4882,21 +4978,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomic__Alternatives" - // InternalVampireLanguage.g:1397:1: rule__VLSAtomic__Alternatives : ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) ); + // InternalVampireLanguage.g:1428:1: rule__VLSAtomic__Alternatives : ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) ); public final void rule__VLSAtomic__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1401:1: ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) ) + // InternalVampireLanguage.g:1432:1: ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) ) int alt21=4; alt21 = dfa21.predict(input); switch (alt21) { case 1 : - // InternalVampireLanguage.g:1402:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1433:2: ( ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:1402:2: ( ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:1403:3: ruleVLSAtomicConstant + // InternalVampireLanguage.g:1433:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1434:3: ruleVLSAtomicConstant { before(grammarAccess.getVLSAtomicAccess().getVLSAtomicConstantParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -4912,10 +5008,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1408:2: ( ruleVLSAtomicFunction ) + // InternalVampireLanguage.g:1439:2: ( ruleVLSAtomicFunction ) { - // InternalVampireLanguage.g:1408:2: ( ruleVLSAtomicFunction ) - // InternalVampireLanguage.g:1409:3: ruleVLSAtomicFunction + // InternalVampireLanguage.g:1439:2: ( ruleVLSAtomicFunction ) + // InternalVampireLanguage.g:1440:3: ruleVLSAtomicFunction { before(grammarAccess.getVLSAtomicAccess().getVLSAtomicFunctionParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -4931,10 +5027,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1414:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1445:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1414:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1415:3: ruleVLSVariable + // InternalVampireLanguage.g:1445:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1446:3: ruleVLSVariable { before(grammarAccess.getVLSAtomicAccess().getVLSVariableParserRuleCall_2()); pushFollow(FOLLOW_2); @@ -4950,10 +5046,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1420:2: ( ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:1451:2: ( ruleVLSDefinedTerm ) { - // InternalVampireLanguage.g:1420:2: ( ruleVLSDefinedTerm ) - // InternalVampireLanguage.g:1421:3: ruleVLSDefinedTerm + // InternalVampireLanguage.g:1451:2: ( ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:1452:3: ruleVLSDefinedTerm { before(grammarAccess.getVLSAtomicAccess().getVLSDefinedTermParserRuleCall_3()); pushFollow(FOLLOW_2); @@ -4986,13 +5082,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Alternatives" - // InternalVampireLanguage.g:1430:1: rule__VLSAtomicConstant__Alternatives : ( ( ( rule__VLSAtomicConstant__Group_0__0 ) ) | ( ( rule__VLSAtomicConstant__Group_1__0 ) ) | ( ( rule__VLSAtomicConstant__Group_2__0 ) ) ); + // InternalVampireLanguage.g:1461:1: rule__VLSAtomicConstant__Alternatives : ( ( ( rule__VLSAtomicConstant__Group_0__0 ) ) | ( ( rule__VLSAtomicConstant__Group_1__0 ) ) | ( ( rule__VLSAtomicConstant__Group_2__0 ) ) ); public final void rule__VLSAtomicConstant__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1434:1: ( ( ( rule__VLSAtomicConstant__Group_0__0 ) ) | ( ( rule__VLSAtomicConstant__Group_1__0 ) ) | ( ( rule__VLSAtomicConstant__Group_2__0 ) ) ) + // InternalVampireLanguage.g:1465:1: ( ( ( rule__VLSAtomicConstant__Group_0__0 ) ) | ( ( rule__VLSAtomicConstant__Group_1__0 ) ) | ( ( rule__VLSAtomicConstant__Group_2__0 ) ) ) int alt22=3; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5037,14 +5133,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt22) { case 1 : - // InternalVampireLanguage.g:1435:2: ( ( rule__VLSAtomicConstant__Group_0__0 ) ) + // InternalVampireLanguage.g:1466:2: ( ( rule__VLSAtomicConstant__Group_0__0 ) ) { - // InternalVampireLanguage.g:1435:2: ( ( rule__VLSAtomicConstant__Group_0__0 ) ) - // InternalVampireLanguage.g:1436:3: ( rule__VLSAtomicConstant__Group_0__0 ) + // InternalVampireLanguage.g:1466:2: ( ( rule__VLSAtomicConstant__Group_0__0 ) ) + // InternalVampireLanguage.g:1467:3: ( rule__VLSAtomicConstant__Group_0__0 ) { before(grammarAccess.getVLSAtomicConstantAccess().getGroup_0()); - // InternalVampireLanguage.g:1437:3: ( rule__VLSAtomicConstant__Group_0__0 ) - // InternalVampireLanguage.g:1437:4: rule__VLSAtomicConstant__Group_0__0 + // InternalVampireLanguage.g:1468:3: ( rule__VLSAtomicConstant__Group_0__0 ) + // InternalVampireLanguage.g:1468:4: rule__VLSAtomicConstant__Group_0__0 { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_0__0(); @@ -5062,14 +5158,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1441:2: ( ( rule__VLSAtomicConstant__Group_1__0 ) ) + // InternalVampireLanguage.g:1472:2: ( ( rule__VLSAtomicConstant__Group_1__0 ) ) { - // InternalVampireLanguage.g:1441:2: ( ( rule__VLSAtomicConstant__Group_1__0 ) ) - // InternalVampireLanguage.g:1442:3: ( rule__VLSAtomicConstant__Group_1__0 ) + // InternalVampireLanguage.g:1472:2: ( ( rule__VLSAtomicConstant__Group_1__0 ) ) + // InternalVampireLanguage.g:1473:3: ( rule__VLSAtomicConstant__Group_1__0 ) { before(grammarAccess.getVLSAtomicConstantAccess().getGroup_1()); - // InternalVampireLanguage.g:1443:3: ( rule__VLSAtomicConstant__Group_1__0 ) - // InternalVampireLanguage.g:1443:4: rule__VLSAtomicConstant__Group_1__0 + // InternalVampireLanguage.g:1474:3: ( rule__VLSAtomicConstant__Group_1__0 ) + // InternalVampireLanguage.g:1474:4: rule__VLSAtomicConstant__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_1__0(); @@ -5087,14 +5183,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1447:2: ( ( rule__VLSAtomicConstant__Group_2__0 ) ) + // InternalVampireLanguage.g:1478:2: ( ( rule__VLSAtomicConstant__Group_2__0 ) ) { - // InternalVampireLanguage.g:1447:2: ( ( rule__VLSAtomicConstant__Group_2__0 ) ) - // InternalVampireLanguage.g:1448:3: ( rule__VLSAtomicConstant__Group_2__0 ) + // InternalVampireLanguage.g:1478:2: ( ( rule__VLSAtomicConstant__Group_2__0 ) ) + // InternalVampireLanguage.g:1479:3: ( rule__VLSAtomicConstant__Group_2__0 ) { before(grammarAccess.getVLSAtomicConstantAccess().getGroup_2()); - // InternalVampireLanguage.g:1449:3: ( rule__VLSAtomicConstant__Group_2__0 ) - // InternalVampireLanguage.g:1449:4: rule__VLSAtomicConstant__Group_2__0 + // InternalVampireLanguage.g:1480:3: ( rule__VLSAtomicConstant__Group_2__0 ) + // InternalVampireLanguage.g:1480:4: rule__VLSAtomicConstant__Group_2__0 { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_2__0(); @@ -5129,13 +5225,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__NameAlternatives_0_1_0" - // InternalVampireLanguage.g:1457:1: rule__VLSAtomicConstant__NameAlternatives_0_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ); + // InternalVampireLanguage.g:1488:1: rule__VLSAtomicConstant__NameAlternatives_0_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ); public final void rule__VLSAtomicConstant__NameAlternatives_0_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1461:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ) + // InternalVampireLanguage.g:1492:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ) int alt23=5; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5186,10 +5282,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt23) { case 1 : - // InternalVampireLanguage.g:1462:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1493:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:1462:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:1463:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:1493:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1494:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSAtomicConstantAccess().getNameLOWER_WORD_IDTerminalRuleCall_0_1_0_0()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -5201,10 +5297,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1468:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1499:2: ( RULE_SINGLE_QUOTE ) { - // InternalVampireLanguage.g:1468:2: ( RULE_SINGLE_QUOTE ) - // InternalVampireLanguage.g:1469:3: RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:1499:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1500:3: RULE_SINGLE_QUOTE { before(grammarAccess.getVLSAtomicConstantAccess().getNameSINGLE_QUOTETerminalRuleCall_0_1_0_1()); match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -5216,10 +5312,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1474:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1505:2: ( RULE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1474:2: ( RULE_DOLLAR_ID ) - // InternalVampireLanguage.g:1475:3: RULE_DOLLAR_ID + // InternalVampireLanguage.g:1505:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1506:3: RULE_DOLLAR_ID { before(grammarAccess.getVLSAtomicConstantAccess().getNameDOLLAR_IDTerminalRuleCall_0_1_0_2()); match(input,RULE_DOLLAR_ID,FOLLOW_2); @@ -5231,10 +5327,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1480:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1511:2: ( RULE_DOUBLE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1480:2: ( RULE_DOUBLE_DOLLAR_ID ) - // InternalVampireLanguage.g:1481:3: RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:1511:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1512:3: RULE_DOUBLE_DOLLAR_ID { before(grammarAccess.getVLSAtomicConstantAccess().getNameDOUBLE_DOLLAR_IDTerminalRuleCall_0_1_0_3()); match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_2); @@ -5246,10 +5342,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 5 : - // InternalVampireLanguage.g:1486:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1517:2: ( ruleVLSRole ) { - // InternalVampireLanguage.g:1486:2: ( ruleVLSRole ) - // InternalVampireLanguage.g:1487:3: ruleVLSRole + // InternalVampireLanguage.g:1517:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1518:3: ruleVLSRole { before(grammarAccess.getVLSAtomicConstantAccess().getNameVLSRoleParserRuleCall_0_1_0_4()); pushFollow(FOLLOW_2); @@ -5282,13 +5378,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Alternatives" - // InternalVampireLanguage.g:1496:1: rule__VLSAtomicFunction__Alternatives : ( ( ( rule__VLSAtomicFunction__Group_0__0 ) ) | ( ( rule__VLSAtomicFunction__Group_1__0 ) ) ); + // InternalVampireLanguage.g:1527:1: rule__VLSAtomicFunction__Alternatives : ( ( ( rule__VLSAtomicFunction__Group_0__0 ) ) | ( ( rule__VLSAtomicFunction__Group_1__0 ) ) ); public final void rule__VLSAtomicFunction__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1500:1: ( ( ( rule__VLSAtomicFunction__Group_0__0 ) ) | ( ( rule__VLSAtomicFunction__Group_1__0 ) ) ) + // InternalVampireLanguage.g:1531:1: ( ( ( rule__VLSAtomicFunction__Group_0__0 ) ) | ( ( rule__VLSAtomicFunction__Group_1__0 ) ) ) int alt24=2; int LA24_0 = input.LA(1); @@ -5306,14 +5402,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt24) { case 1 : - // InternalVampireLanguage.g:1501:2: ( ( rule__VLSAtomicFunction__Group_0__0 ) ) + // InternalVampireLanguage.g:1532:2: ( ( rule__VLSAtomicFunction__Group_0__0 ) ) { - // InternalVampireLanguage.g:1501:2: ( ( rule__VLSAtomicFunction__Group_0__0 ) ) - // InternalVampireLanguage.g:1502:3: ( rule__VLSAtomicFunction__Group_0__0 ) + // InternalVampireLanguage.g:1532:2: ( ( rule__VLSAtomicFunction__Group_0__0 ) ) + // InternalVampireLanguage.g:1533:3: ( rule__VLSAtomicFunction__Group_0__0 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getGroup_0()); - // InternalVampireLanguage.g:1503:3: ( rule__VLSAtomicFunction__Group_0__0 ) - // InternalVampireLanguage.g:1503:4: rule__VLSAtomicFunction__Group_0__0 + // InternalVampireLanguage.g:1534:3: ( rule__VLSAtomicFunction__Group_0__0 ) + // InternalVampireLanguage.g:1534:4: rule__VLSAtomicFunction__Group_0__0 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_0__0(); @@ -5331,14 +5427,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1507:2: ( ( rule__VLSAtomicFunction__Group_1__0 ) ) + // InternalVampireLanguage.g:1538:2: ( ( rule__VLSAtomicFunction__Group_1__0 ) ) { - // InternalVampireLanguage.g:1507:2: ( ( rule__VLSAtomicFunction__Group_1__0 ) ) - // InternalVampireLanguage.g:1508:3: ( rule__VLSAtomicFunction__Group_1__0 ) + // InternalVampireLanguage.g:1538:2: ( ( rule__VLSAtomicFunction__Group_1__0 ) ) + // InternalVampireLanguage.g:1539:3: ( rule__VLSAtomicFunction__Group_1__0 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getGroup_1()); - // InternalVampireLanguage.g:1509:3: ( rule__VLSAtomicFunction__Group_1__0 ) - // InternalVampireLanguage.g:1509:4: rule__VLSAtomicFunction__Group_1__0 + // InternalVampireLanguage.g:1540:3: ( rule__VLSAtomicFunction__Group_1__0 ) + // InternalVampireLanguage.g:1540:4: rule__VLSAtomicFunction__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_1__0(); @@ -5373,13 +5469,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__ConstantAlternatives_0_1_0" - // InternalVampireLanguage.g:1517:1: rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ); + // InternalVampireLanguage.g:1548:1: rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ); public final void rule__VLSAtomicFunction__ConstantAlternatives_0_1_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1521:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ) + // InternalVampireLanguage.g:1552:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) | ( ruleVLSRole ) ) int alt25=5; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5430,10 +5526,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt25) { case 1 : - // InternalVampireLanguage.g:1522:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1553:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:1522:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:1523:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:1553:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1554:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantLOWER_WORD_IDTerminalRuleCall_0_1_0_0()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -5445,10 +5541,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1528:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1559:2: ( RULE_SINGLE_QUOTE ) { - // InternalVampireLanguage.g:1528:2: ( RULE_SINGLE_QUOTE ) - // InternalVampireLanguage.g:1529:3: RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:1559:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1560:3: RULE_SINGLE_QUOTE { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantSINGLE_QUOTETerminalRuleCall_0_1_0_1()); match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -5460,10 +5556,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1534:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1565:2: ( RULE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1534:2: ( RULE_DOLLAR_ID ) - // InternalVampireLanguage.g:1535:3: RULE_DOLLAR_ID + // InternalVampireLanguage.g:1565:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1566:3: RULE_DOLLAR_ID { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantDOLLAR_IDTerminalRuleCall_0_1_0_2()); match(input,RULE_DOLLAR_ID,FOLLOW_2); @@ -5475,10 +5571,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1540:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1571:2: ( RULE_DOUBLE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1540:2: ( RULE_DOUBLE_DOLLAR_ID ) - // InternalVampireLanguage.g:1541:3: RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:1571:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1572:3: RULE_DOUBLE_DOLLAR_ID { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantDOUBLE_DOLLAR_IDTerminalRuleCall_0_1_0_3()); match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_2); @@ -5490,10 +5586,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 5 : - // InternalVampireLanguage.g:1546:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1577:2: ( ruleVLSRole ) { - // InternalVampireLanguage.g:1546:2: ( ruleVLSRole ) - // InternalVampireLanguage.g:1547:3: ruleVLSRole + // InternalVampireLanguage.g:1577:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:1578:3: ruleVLSRole { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantVLSRoleParserRuleCall_0_1_0_4()); pushFollow(FOLLOW_2); @@ -5526,13 +5622,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofTerm__Alternatives" - // InternalVampireLanguage.g:1556:1: rule__VLSFofTerm__Alternatives : ( ( ruleVLSVariable ) | ( ruleVLSFunctionAsTerm ) | ( ruleVLSDefinedTerm ) ); + // InternalVampireLanguage.g:1587:1: rule__VLSFofTerm__Alternatives : ( ( ruleVLSVariable ) | ( ruleVLSFunctionAsTerm ) | ( ruleVLSDefinedTerm ) ); public final void rule__VLSFofTerm__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1560:1: ( ( ruleVLSVariable ) | ( ruleVLSFunctionAsTerm ) | ( ruleVLSDefinedTerm ) ) + // InternalVampireLanguage.g:1591:1: ( ( ruleVLSVariable ) | ( ruleVLSFunctionAsTerm ) | ( ruleVLSDefinedTerm ) ) int alt26=3; switch ( input.LA(1) ) { case RULE_UPPER_WORD_ID: @@ -5563,10 +5659,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt26) { case 1 : - // InternalVampireLanguage.g:1561:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1592:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:1561:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:1562:3: ruleVLSVariable + // InternalVampireLanguage.g:1592:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:1593:3: ruleVLSVariable { before(grammarAccess.getVLSFofTermAccess().getVLSVariableParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -5582,10 +5678,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1567:2: ( ruleVLSFunctionAsTerm ) + // InternalVampireLanguage.g:1598:2: ( ruleVLSFunctionAsTerm ) { - // InternalVampireLanguage.g:1567:2: ( ruleVLSFunctionAsTerm ) - // InternalVampireLanguage.g:1568:3: ruleVLSFunctionAsTerm + // InternalVampireLanguage.g:1598:2: ( ruleVLSFunctionAsTerm ) + // InternalVampireLanguage.g:1599:3: ruleVLSFunctionAsTerm { before(grammarAccess.getVLSFofTermAccess().getVLSFunctionAsTermParserRuleCall_1()); pushFollow(FOLLOW_2); @@ -5601,10 +5697,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1573:2: ( ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:1604:2: ( ruleVLSDefinedTerm ) { - // InternalVampireLanguage.g:1573:2: ( ruleVLSDefinedTerm ) - // InternalVampireLanguage.g:1574:3: ruleVLSDefinedTerm + // InternalVampireLanguage.g:1604:2: ( ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:1605:3: ruleVLSDefinedTerm { before(grammarAccess.getVLSFofTermAccess().getVLSDefinedTermParserRuleCall_2()); pushFollow(FOLLOW_2); @@ -5637,13 +5733,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__FunctorAlternatives_0_0" - // InternalVampireLanguage.g:1583:1: rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) ); + // InternalVampireLanguage.g:1614:1: rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 : ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) ); public final void rule__VLSFunctionAsTerm__FunctorAlternatives_0_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1587:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) ) + // InternalVampireLanguage.g:1618:1: ( ( RULE_LOWER_WORD_ID ) | ( RULE_SINGLE_QUOTE ) | ( RULE_DOLLAR_ID ) | ( RULE_DOUBLE_DOLLAR_ID ) ) int alt27=4; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5675,10 +5771,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt27) { case 1 : - // InternalVampireLanguage.g:1588:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1619:2: ( RULE_LOWER_WORD_ID ) { - // InternalVampireLanguage.g:1588:2: ( RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:1589:3: RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:1619:2: ( RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:1620:3: RULE_LOWER_WORD_ID { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorLOWER_WORD_IDTerminalRuleCall_0_0_0()); match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -5690,10 +5786,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1594:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1625:2: ( RULE_SINGLE_QUOTE ) { - // InternalVampireLanguage.g:1594:2: ( RULE_SINGLE_QUOTE ) - // InternalVampireLanguage.g:1595:3: RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:1625:2: ( RULE_SINGLE_QUOTE ) + // InternalVampireLanguage.g:1626:3: RULE_SINGLE_QUOTE { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorSINGLE_QUOTETerminalRuleCall_0_0_1()); match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -5705,10 +5801,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 3 : - // InternalVampireLanguage.g:1600:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1631:2: ( RULE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1600:2: ( RULE_DOLLAR_ID ) - // InternalVampireLanguage.g:1601:3: RULE_DOLLAR_ID + // InternalVampireLanguage.g:1631:2: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:1632:3: RULE_DOLLAR_ID { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorDOLLAR_IDTerminalRuleCall_0_0_2()); match(input,RULE_DOLLAR_ID,FOLLOW_2); @@ -5720,10 +5816,10 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 4 : - // InternalVampireLanguage.g:1606:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1637:2: ( RULE_DOUBLE_DOLLAR_ID ) { - // InternalVampireLanguage.g:1606:2: ( RULE_DOUBLE_DOLLAR_ID ) - // InternalVampireLanguage.g:1607:3: RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:1637:2: ( RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:1638:3: RULE_DOUBLE_DOLLAR_ID { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorDOUBLE_DOLLAR_IDTerminalRuleCall_0_0_3()); match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_2); @@ -5752,13 +5848,13 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Alternatives" - // InternalVampireLanguage.g:1616:1: rule__VLSDefinedTerm__Alternatives : ( ( ( rule__VLSDefinedTerm__Group_0__0 ) ) | ( ( rule__VLSDefinedTerm__Group_1__0 ) ) ); + // InternalVampireLanguage.g:1647:1: rule__VLSDefinedTerm__Alternatives : ( ( ( rule__VLSDefinedTerm__Group_0__0 ) ) | ( ( rule__VLSDefinedTerm__Group_1__0 ) ) ); public final void rule__VLSDefinedTerm__Alternatives() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1620:1: ( ( ( rule__VLSDefinedTerm__Group_0__0 ) ) | ( ( rule__VLSDefinedTerm__Group_1__0 ) ) ) + // InternalVampireLanguage.g:1651:1: ( ( ( rule__VLSDefinedTerm__Group_0__0 ) ) | ( ( rule__VLSDefinedTerm__Group_1__0 ) ) ) int alt28=2; int LA28_0 = input.LA(1); @@ -5776,14 +5872,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt28) { case 1 : - // InternalVampireLanguage.g:1621:2: ( ( rule__VLSDefinedTerm__Group_0__0 ) ) + // InternalVampireLanguage.g:1652:2: ( ( rule__VLSDefinedTerm__Group_0__0 ) ) { - // InternalVampireLanguage.g:1621:2: ( ( rule__VLSDefinedTerm__Group_0__0 ) ) - // InternalVampireLanguage.g:1622:3: ( rule__VLSDefinedTerm__Group_0__0 ) + // InternalVampireLanguage.g:1652:2: ( ( rule__VLSDefinedTerm__Group_0__0 ) ) + // InternalVampireLanguage.g:1653:3: ( rule__VLSDefinedTerm__Group_0__0 ) { before(grammarAccess.getVLSDefinedTermAccess().getGroup_0()); - // InternalVampireLanguage.g:1623:3: ( rule__VLSDefinedTerm__Group_0__0 ) - // InternalVampireLanguage.g:1623:4: rule__VLSDefinedTerm__Group_0__0 + // InternalVampireLanguage.g:1654:3: ( rule__VLSDefinedTerm__Group_0__0 ) + // InternalVampireLanguage.g:1654:4: rule__VLSDefinedTerm__Group_0__0 { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__Group_0__0(); @@ -5801,14 +5897,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } break; case 2 : - // InternalVampireLanguage.g:1627:2: ( ( rule__VLSDefinedTerm__Group_1__0 ) ) + // InternalVampireLanguage.g:1658:2: ( ( rule__VLSDefinedTerm__Group_1__0 ) ) { - // InternalVampireLanguage.g:1627:2: ( ( rule__VLSDefinedTerm__Group_1__0 ) ) - // InternalVampireLanguage.g:1628:3: ( rule__VLSDefinedTerm__Group_1__0 ) + // InternalVampireLanguage.g:1658:2: ( ( rule__VLSDefinedTerm__Group_1__0 ) ) + // InternalVampireLanguage.g:1659:3: ( rule__VLSDefinedTerm__Group_1__0 ) { before(grammarAccess.getVLSDefinedTermAccess().getGroup_1()); - // InternalVampireLanguage.g:1629:3: ( rule__VLSDefinedTerm__Group_1__0 ) - // InternalVampireLanguage.g:1629:4: rule__VLSDefinedTerm__Group_1__0 + // InternalVampireLanguage.g:1660:3: ( rule__VLSDefinedTerm__Group_1__0 ) + // InternalVampireLanguage.g:1660:4: rule__VLSDefinedTerm__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__Group_1__0(); @@ -5843,14 +5939,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_0__0" - // InternalVampireLanguage.g:1637:1: rule__VLSConfirmations__Group_0__0 : rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 ; + // InternalVampireLanguage.g:1668:1: rule__VLSConfirmations__Group_0__0 : rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 ; public final void rule__VLSConfirmations__Group_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1641:1: ( rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 ) - // InternalVampireLanguage.g:1642:2: rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 + // InternalVampireLanguage.g:1672:1: ( rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 ) + // InternalVampireLanguage.g:1673:2: rule__VLSConfirmations__Group_0__0__Impl rule__VLSConfirmations__Group_0__1 { pushFollow(FOLLOW_6); rule__VLSConfirmations__Group_0__0__Impl(); @@ -5881,21 +5977,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_0__0__Impl" - // InternalVampireLanguage.g:1649:1: rule__VLSConfirmations__Group_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:1680:1: rule__VLSConfirmations__Group_0__0__Impl : ( () ) ; public final void rule__VLSConfirmations__Group_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1653:1: ( ( () ) ) - // InternalVampireLanguage.g:1654:1: ( () ) + // InternalVampireLanguage.g:1684:1: ( ( () ) ) + // InternalVampireLanguage.g:1685:1: ( () ) { - // InternalVampireLanguage.g:1654:1: ( () ) - // InternalVampireLanguage.g:1655:2: () + // InternalVampireLanguage.g:1685:1: ( () ) + // InternalVampireLanguage.g:1686:2: () { before(grammarAccess.getVLSConfirmationsAccess().getVLSSatisfiableAction_0_0()); - // InternalVampireLanguage.g:1656:2: () - // InternalVampireLanguage.g:1656:3: + // InternalVampireLanguage.g:1687:2: () + // InternalVampireLanguage.g:1687:3: { } @@ -5918,14 +6014,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_0__1" - // InternalVampireLanguage.g:1664:1: rule__VLSConfirmations__Group_0__1 : rule__VLSConfirmations__Group_0__1__Impl ; + // InternalVampireLanguage.g:1695:1: rule__VLSConfirmations__Group_0__1 : rule__VLSConfirmations__Group_0__1__Impl ; public final void rule__VLSConfirmations__Group_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1668:1: ( rule__VLSConfirmations__Group_0__1__Impl ) - // InternalVampireLanguage.g:1669:2: rule__VLSConfirmations__Group_0__1__Impl + // InternalVampireLanguage.g:1699:1: ( rule__VLSConfirmations__Group_0__1__Impl ) + // InternalVampireLanguage.g:1700:2: rule__VLSConfirmations__Group_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_0__1__Impl(); @@ -5951,17 +6047,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_0__1__Impl" - // InternalVampireLanguage.g:1675:1: rule__VLSConfirmations__Group_0__1__Impl : ( 'Satisfiable!' ) ; + // InternalVampireLanguage.g:1706:1: rule__VLSConfirmations__Group_0__1__Impl : ( 'Satisfiable!' ) ; public final void rule__VLSConfirmations__Group_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1679:1: ( ( 'Satisfiable!' ) ) - // InternalVampireLanguage.g:1680:1: ( 'Satisfiable!' ) + // InternalVampireLanguage.g:1710:1: ( ( 'Satisfiable!' ) ) + // InternalVampireLanguage.g:1711:1: ( 'Satisfiable!' ) { - // InternalVampireLanguage.g:1680:1: ( 'Satisfiable!' ) - // InternalVampireLanguage.g:1681:2: 'Satisfiable!' + // InternalVampireLanguage.g:1711:1: ( 'Satisfiable!' ) + // InternalVampireLanguage.g:1712:2: 'Satisfiable!' { before(grammarAccess.getVLSConfirmationsAccess().getSatisfiableKeyword_0_1()); match(input,39,FOLLOW_2); @@ -5988,14 +6084,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__0" - // InternalVampireLanguage.g:1691:1: rule__VLSConfirmations__Group_1__0 : rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 ; + // InternalVampireLanguage.g:1722:1: rule__VLSConfirmations__Group_1__0 : rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 ; public final void rule__VLSConfirmations__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1695:1: ( rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 ) - // InternalVampireLanguage.g:1696:2: rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 + // InternalVampireLanguage.g:1726:1: ( rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 ) + // InternalVampireLanguage.g:1727:2: rule__VLSConfirmations__Group_1__0__Impl rule__VLSConfirmations__Group_1__1 { pushFollow(FOLLOW_7); rule__VLSConfirmations__Group_1__0__Impl(); @@ -6026,21 +6122,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__0__Impl" - // InternalVampireLanguage.g:1703:1: rule__VLSConfirmations__Group_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:1734:1: rule__VLSConfirmations__Group_1__0__Impl : ( () ) ; public final void rule__VLSConfirmations__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1707:1: ( ( () ) ) - // InternalVampireLanguage.g:1708:1: ( () ) + // InternalVampireLanguage.g:1738:1: ( ( () ) ) + // InternalVampireLanguage.g:1739:1: ( () ) { - // InternalVampireLanguage.g:1708:1: ( () ) - // InternalVampireLanguage.g:1709:2: () + // InternalVampireLanguage.g:1739:1: ( () ) + // InternalVampireLanguage.g:1740:2: () { before(grammarAccess.getVLSConfirmationsAccess().getVLSWarningAction_1_0()); - // InternalVampireLanguage.g:1710:2: () - // InternalVampireLanguage.g:1710:3: + // InternalVampireLanguage.g:1741:2: () + // InternalVampireLanguage.g:1741:3: { } @@ -6063,14 +6159,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__1" - // InternalVampireLanguage.g:1718:1: rule__VLSConfirmations__Group_1__1 : rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 ; + // InternalVampireLanguage.g:1749:1: rule__VLSConfirmations__Group_1__1 : rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 ; public final void rule__VLSConfirmations__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1722:1: ( rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 ) - // InternalVampireLanguage.g:1723:2: rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 + // InternalVampireLanguage.g:1753:1: ( rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 ) + // InternalVampireLanguage.g:1754:2: rule__VLSConfirmations__Group_1__1__Impl rule__VLSConfirmations__Group_1__2 { pushFollow(FOLLOW_8); rule__VLSConfirmations__Group_1__1__Impl(); @@ -6101,17 +6197,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__1__Impl" - // InternalVampireLanguage.g:1730:1: rule__VLSConfirmations__Group_1__1__Impl : ( 'WARNING!' ) ; + // InternalVampireLanguage.g:1761:1: rule__VLSConfirmations__Group_1__1__Impl : ( 'WARNING!' ) ; public final void rule__VLSConfirmations__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1734:1: ( ( 'WARNING!' ) ) - // InternalVampireLanguage.g:1735:1: ( 'WARNING!' ) + // InternalVampireLanguage.g:1765:1: ( ( 'WARNING!' ) ) + // InternalVampireLanguage.g:1766:1: ( 'WARNING!' ) { - // InternalVampireLanguage.g:1735:1: ( 'WARNING!' ) - // InternalVampireLanguage.g:1736:2: 'WARNING!' + // InternalVampireLanguage.g:1766:1: ( 'WARNING!' ) + // InternalVampireLanguage.g:1767:2: 'WARNING!' { before(grammarAccess.getVLSConfirmationsAccess().getWARNINGKeyword_1_1()); match(input,40,FOLLOW_2); @@ -6138,14 +6234,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__2" - // InternalVampireLanguage.g:1745:1: rule__VLSConfirmations__Group_1__2 : rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 ; + // InternalVampireLanguage.g:1776:1: rule__VLSConfirmations__Group_1__2 : rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 ; public final void rule__VLSConfirmations__Group_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1749:1: ( rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 ) - // InternalVampireLanguage.g:1750:2: rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 + // InternalVampireLanguage.g:1780:1: ( rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 ) + // InternalVampireLanguage.g:1781:2: rule__VLSConfirmations__Group_1__2__Impl rule__VLSConfirmations__Group_1__3 { pushFollow(FOLLOW_9); rule__VLSConfirmations__Group_1__2__Impl(); @@ -6176,17 +6272,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__2__Impl" - // InternalVampireLanguage.g:1757:1: rule__VLSConfirmations__Group_1__2__Impl : ( 'Could' ) ; + // InternalVampireLanguage.g:1788:1: rule__VLSConfirmations__Group_1__2__Impl : ( 'Could' ) ; public final void rule__VLSConfirmations__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1761:1: ( ( 'Could' ) ) - // InternalVampireLanguage.g:1762:1: ( 'Could' ) + // InternalVampireLanguage.g:1792:1: ( ( 'Could' ) ) + // InternalVampireLanguage.g:1793:1: ( 'Could' ) { - // InternalVampireLanguage.g:1762:1: ( 'Could' ) - // InternalVampireLanguage.g:1763:2: 'Could' + // InternalVampireLanguage.g:1793:1: ( 'Could' ) + // InternalVampireLanguage.g:1794:2: 'Could' { before(grammarAccess.getVLSConfirmationsAccess().getCouldKeyword_1_2()); match(input,41,FOLLOW_2); @@ -6213,14 +6309,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__3" - // InternalVampireLanguage.g:1772:1: rule__VLSConfirmations__Group_1__3 : rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 ; + // InternalVampireLanguage.g:1803:1: rule__VLSConfirmations__Group_1__3 : rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 ; public final void rule__VLSConfirmations__Group_1__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1776:1: ( rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 ) - // InternalVampireLanguage.g:1777:2: rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 + // InternalVampireLanguage.g:1807:1: ( rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 ) + // InternalVampireLanguage.g:1808:2: rule__VLSConfirmations__Group_1__3__Impl rule__VLSConfirmations__Group_1__4 { pushFollow(FOLLOW_10); rule__VLSConfirmations__Group_1__3__Impl(); @@ -6251,17 +6347,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__3__Impl" - // InternalVampireLanguage.g:1784:1: rule__VLSConfirmations__Group_1__3__Impl : ( 'not' ) ; + // InternalVampireLanguage.g:1815:1: rule__VLSConfirmations__Group_1__3__Impl : ( 'not' ) ; public final void rule__VLSConfirmations__Group_1__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1788:1: ( ( 'not' ) ) - // InternalVampireLanguage.g:1789:1: ( 'not' ) + // InternalVampireLanguage.g:1819:1: ( ( 'not' ) ) + // InternalVampireLanguage.g:1820:1: ( 'not' ) { - // InternalVampireLanguage.g:1789:1: ( 'not' ) - // InternalVampireLanguage.g:1790:2: 'not' + // InternalVampireLanguage.g:1820:1: ( 'not' ) + // InternalVampireLanguage.g:1821:2: 'not' { before(grammarAccess.getVLSConfirmationsAccess().getNotKeyword_1_3()); match(input,42,FOLLOW_2); @@ -6288,14 +6384,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__4" - // InternalVampireLanguage.g:1799:1: rule__VLSConfirmations__Group_1__4 : rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 ; + // InternalVampireLanguage.g:1830:1: rule__VLSConfirmations__Group_1__4 : rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 ; public final void rule__VLSConfirmations__Group_1__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1803:1: ( rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 ) - // InternalVampireLanguage.g:1804:2: rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 + // InternalVampireLanguage.g:1834:1: ( rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 ) + // InternalVampireLanguage.g:1835:2: rule__VLSConfirmations__Group_1__4__Impl rule__VLSConfirmations__Group_1__5 { pushFollow(FOLLOW_11); rule__VLSConfirmations__Group_1__4__Impl(); @@ -6326,17 +6422,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__4__Impl" - // InternalVampireLanguage.g:1811:1: rule__VLSConfirmations__Group_1__4__Impl : ( 'set' ) ; + // InternalVampireLanguage.g:1842:1: rule__VLSConfirmations__Group_1__4__Impl : ( 'set' ) ; public final void rule__VLSConfirmations__Group_1__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1815:1: ( ( 'set' ) ) - // InternalVampireLanguage.g:1816:1: ( 'set' ) + // InternalVampireLanguage.g:1846:1: ( ( 'set' ) ) + // InternalVampireLanguage.g:1847:1: ( 'set' ) { - // InternalVampireLanguage.g:1816:1: ( 'set' ) - // InternalVampireLanguage.g:1817:2: 'set' + // InternalVampireLanguage.g:1847:1: ( 'set' ) + // InternalVampireLanguage.g:1848:2: 'set' { before(grammarAccess.getVLSConfirmationsAccess().getSetKeyword_1_4()); match(input,43,FOLLOW_2); @@ -6363,14 +6459,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__5" - // InternalVampireLanguage.g:1826:1: rule__VLSConfirmations__Group_1__5 : rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 ; + // InternalVampireLanguage.g:1857:1: rule__VLSConfirmations__Group_1__5 : rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 ; public final void rule__VLSConfirmations__Group_1__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1830:1: ( rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 ) - // InternalVampireLanguage.g:1831:2: rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 + // InternalVampireLanguage.g:1861:1: ( rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 ) + // InternalVampireLanguage.g:1862:2: rule__VLSConfirmations__Group_1__5__Impl rule__VLSConfirmations__Group_1__6 { pushFollow(FOLLOW_12); rule__VLSConfirmations__Group_1__5__Impl(); @@ -6401,17 +6497,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__5__Impl" - // InternalVampireLanguage.g:1838:1: rule__VLSConfirmations__Group_1__5__Impl : ( 'resource' ) ; + // InternalVampireLanguage.g:1869:1: rule__VLSConfirmations__Group_1__5__Impl : ( 'resource' ) ; public final void rule__VLSConfirmations__Group_1__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1842:1: ( ( 'resource' ) ) - // InternalVampireLanguage.g:1843:1: ( 'resource' ) + // InternalVampireLanguage.g:1873:1: ( ( 'resource' ) ) + // InternalVampireLanguage.g:1874:1: ( 'resource' ) { - // InternalVampireLanguage.g:1843:1: ( 'resource' ) - // InternalVampireLanguage.g:1844:2: 'resource' + // InternalVampireLanguage.g:1874:1: ( 'resource' ) + // InternalVampireLanguage.g:1875:2: 'resource' { before(grammarAccess.getVLSConfirmationsAccess().getResourceKeyword_1_5()); match(input,44,FOLLOW_2); @@ -6438,14 +6534,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__6" - // InternalVampireLanguage.g:1853:1: rule__VLSConfirmations__Group_1__6 : rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 ; + // InternalVampireLanguage.g:1884:1: rule__VLSConfirmations__Group_1__6 : rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 ; public final void rule__VLSConfirmations__Group_1__6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1857:1: ( rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 ) - // InternalVampireLanguage.g:1858:2: rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 + // InternalVampireLanguage.g:1888:1: ( rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 ) + // InternalVampireLanguage.g:1889:2: rule__VLSConfirmations__Group_1__6__Impl rule__VLSConfirmations__Group_1__7 { pushFollow(FOLLOW_13); rule__VLSConfirmations__Group_1__6__Impl(); @@ -6476,17 +6572,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__6__Impl" - // InternalVampireLanguage.g:1865:1: rule__VLSConfirmations__Group_1__6__Impl : ( 'limit:' ) ; + // InternalVampireLanguage.g:1896:1: rule__VLSConfirmations__Group_1__6__Impl : ( 'limit:' ) ; public final void rule__VLSConfirmations__Group_1__6__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1869:1: ( ( 'limit:' ) ) - // InternalVampireLanguage.g:1870:1: ( 'limit:' ) + // InternalVampireLanguage.g:1900:1: ( ( 'limit:' ) ) + // InternalVampireLanguage.g:1901:1: ( 'limit:' ) { - // InternalVampireLanguage.g:1870:1: ( 'limit:' ) - // InternalVampireLanguage.g:1871:2: 'limit:' + // InternalVampireLanguage.g:1901:1: ( 'limit:' ) + // InternalVampireLanguage.g:1902:2: 'limit:' { before(grammarAccess.getVLSConfirmationsAccess().getLimitKeyword_1_6()); match(input,45,FOLLOW_2); @@ -6513,14 +6609,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__7" - // InternalVampireLanguage.g:1880:1: rule__VLSConfirmations__Group_1__7 : rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 ; + // InternalVampireLanguage.g:1911:1: rule__VLSConfirmations__Group_1__7 : rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 ; public final void rule__VLSConfirmations__Group_1__7() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1884:1: ( rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 ) - // InternalVampireLanguage.g:1885:2: rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 + // InternalVampireLanguage.g:1915:1: ( rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 ) + // InternalVampireLanguage.g:1916:2: rule__VLSConfirmations__Group_1__7__Impl rule__VLSConfirmations__Group_1__8 { pushFollow(FOLLOW_14); rule__VLSConfirmations__Group_1__7__Impl(); @@ -6551,17 +6647,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__7__Impl" - // InternalVampireLanguage.g:1892:1: rule__VLSConfirmations__Group_1__7__Impl : ( 'Virtual' ) ; + // InternalVampireLanguage.g:1923:1: rule__VLSConfirmations__Group_1__7__Impl : ( 'Virtual' ) ; public final void rule__VLSConfirmations__Group_1__7__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1896:1: ( ( 'Virtual' ) ) - // InternalVampireLanguage.g:1897:1: ( 'Virtual' ) + // InternalVampireLanguage.g:1927:1: ( ( 'Virtual' ) ) + // InternalVampireLanguage.g:1928:1: ( 'Virtual' ) { - // InternalVampireLanguage.g:1897:1: ( 'Virtual' ) - // InternalVampireLanguage.g:1898:2: 'Virtual' + // InternalVampireLanguage.g:1928:1: ( 'Virtual' ) + // InternalVampireLanguage.g:1929:2: 'Virtual' { before(grammarAccess.getVLSConfirmationsAccess().getVirtualKeyword_1_7()); match(input,46,FOLLOW_2); @@ -6588,14 +6684,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__8" - // InternalVampireLanguage.g:1907:1: rule__VLSConfirmations__Group_1__8 : rule__VLSConfirmations__Group_1__8__Impl ; + // InternalVampireLanguage.g:1938:1: rule__VLSConfirmations__Group_1__8 : rule__VLSConfirmations__Group_1__8__Impl ; public final void rule__VLSConfirmations__Group_1__8() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1911:1: ( rule__VLSConfirmations__Group_1__8__Impl ) - // InternalVampireLanguage.g:1912:2: rule__VLSConfirmations__Group_1__8__Impl + // InternalVampireLanguage.g:1942:1: ( rule__VLSConfirmations__Group_1__8__Impl ) + // InternalVampireLanguage.g:1943:2: rule__VLSConfirmations__Group_1__8__Impl { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_1__8__Impl(); @@ -6621,17 +6717,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_1__8__Impl" - // InternalVampireLanguage.g:1918:1: rule__VLSConfirmations__Group_1__8__Impl : ( 'memory.' ) ; + // InternalVampireLanguage.g:1949:1: rule__VLSConfirmations__Group_1__8__Impl : ( 'memory.' ) ; public final void rule__VLSConfirmations__Group_1__8__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1922:1: ( ( 'memory.' ) ) - // InternalVampireLanguage.g:1923:1: ( 'memory.' ) + // InternalVampireLanguage.g:1953:1: ( ( 'memory.' ) ) + // InternalVampireLanguage.g:1954:1: ( 'memory.' ) { - // InternalVampireLanguage.g:1923:1: ( 'memory.' ) - // InternalVampireLanguage.g:1924:2: 'memory.' + // InternalVampireLanguage.g:1954:1: ( 'memory.' ) + // InternalVampireLanguage.g:1955:2: 'memory.' { before(grammarAccess.getVLSConfirmationsAccess().getMemoryKeyword_1_8()); match(input,47,FOLLOW_2); @@ -6658,14 +6754,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__0" - // InternalVampireLanguage.g:1934:1: rule__VLSConfirmations__Group_2__0 : rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 ; + // InternalVampireLanguage.g:1965:1: rule__VLSConfirmations__Group_2__0 : rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 ; public final void rule__VLSConfirmations__Group_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1938:1: ( rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 ) - // InternalVampireLanguage.g:1939:2: rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 + // InternalVampireLanguage.g:1969:1: ( rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 ) + // InternalVampireLanguage.g:1970:2: rule__VLSConfirmations__Group_2__0__Impl rule__VLSConfirmations__Group_2__1 { pushFollow(FOLLOW_15); rule__VLSConfirmations__Group_2__0__Impl(); @@ -6696,21 +6792,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__0__Impl" - // InternalVampireLanguage.g:1946:1: rule__VLSConfirmations__Group_2__0__Impl : ( () ) ; + // InternalVampireLanguage.g:1977:1: rule__VLSConfirmations__Group_2__0__Impl : ( () ) ; public final void rule__VLSConfirmations__Group_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1950:1: ( ( () ) ) - // InternalVampireLanguage.g:1951:1: ( () ) + // InternalVampireLanguage.g:1981:1: ( ( () ) ) + // InternalVampireLanguage.g:1982:1: ( () ) { - // InternalVampireLanguage.g:1951:1: ( () ) - // InternalVampireLanguage.g:1952:2: () + // InternalVampireLanguage.g:1982:1: ( () ) + // InternalVampireLanguage.g:1983:2: () { before(grammarAccess.getVLSConfirmationsAccess().getVLSTryingAction_2_0()); - // InternalVampireLanguage.g:1953:2: () - // InternalVampireLanguage.g:1953:3: + // InternalVampireLanguage.g:1984:2: () + // InternalVampireLanguage.g:1984:3: { } @@ -6733,14 +6829,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__1" - // InternalVampireLanguage.g:1961:1: rule__VLSConfirmations__Group_2__1 : rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 ; + // InternalVampireLanguage.g:1992:1: rule__VLSConfirmations__Group_2__1 : rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 ; public final void rule__VLSConfirmations__Group_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1965:1: ( rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 ) - // InternalVampireLanguage.g:1966:2: rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 + // InternalVampireLanguage.g:1996:1: ( rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 ) + // InternalVampireLanguage.g:1997:2: rule__VLSConfirmations__Group_2__1__Impl rule__VLSConfirmations__Group_2__2 { pushFollow(FOLLOW_16); rule__VLSConfirmations__Group_2__1__Impl(); @@ -6771,17 +6867,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__1__Impl" - // InternalVampireLanguage.g:1973:1: rule__VLSConfirmations__Group_2__1__Impl : ( 'TRYING' ) ; + // InternalVampireLanguage.g:2004:1: rule__VLSConfirmations__Group_2__1__Impl : ( 'TRYING' ) ; public final void rule__VLSConfirmations__Group_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1977:1: ( ( 'TRYING' ) ) - // InternalVampireLanguage.g:1978:1: ( 'TRYING' ) + // InternalVampireLanguage.g:2008:1: ( ( 'TRYING' ) ) + // InternalVampireLanguage.g:2009:1: ( 'TRYING' ) { - // InternalVampireLanguage.g:1978:1: ( 'TRYING' ) - // InternalVampireLanguage.g:1979:2: 'TRYING' + // InternalVampireLanguage.g:2009:1: ( 'TRYING' ) + // InternalVampireLanguage.g:2010:2: 'TRYING' { before(grammarAccess.getVLSConfirmationsAccess().getTRYINGKeyword_2_1()); match(input,48,FOLLOW_2); @@ -6808,14 +6904,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__2" - // InternalVampireLanguage.g:1988:1: rule__VLSConfirmations__Group_2__2 : rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 ; + // InternalVampireLanguage.g:2019:1: rule__VLSConfirmations__Group_2__2 : rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 ; public final void rule__VLSConfirmations__Group_2__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:1992:1: ( rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 ) - // InternalVampireLanguage.g:1993:2: rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 + // InternalVampireLanguage.g:2023:1: ( rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 ) + // InternalVampireLanguage.g:2024:2: rule__VLSConfirmations__Group_2__2__Impl rule__VLSConfirmations__Group_2__3 { pushFollow(FOLLOW_17); rule__VLSConfirmations__Group_2__2__Impl(); @@ -6846,17 +6942,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__2__Impl" - // InternalVampireLanguage.g:2000:1: rule__VLSConfirmations__Group_2__2__Impl : ( '[' ) ; + // InternalVampireLanguage.g:2031:1: rule__VLSConfirmations__Group_2__2__Impl : ( '[' ) ; public final void rule__VLSConfirmations__Group_2__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2004:1: ( ( '[' ) ) - // InternalVampireLanguage.g:2005:1: ( '[' ) + // InternalVampireLanguage.g:2035:1: ( ( '[' ) ) + // InternalVampireLanguage.g:2036:1: ( '[' ) { - // InternalVampireLanguage.g:2005:1: ( '[' ) - // InternalVampireLanguage.g:2006:2: '[' + // InternalVampireLanguage.g:2036:1: ( '[' ) + // InternalVampireLanguage.g:2037:2: '[' { before(grammarAccess.getVLSConfirmationsAccess().getLeftSquareBracketKeyword_2_2()); match(input,49,FOLLOW_2); @@ -6883,14 +6979,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__3" - // InternalVampireLanguage.g:2015:1: rule__VLSConfirmations__Group_2__3 : rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 ; + // InternalVampireLanguage.g:2046:1: rule__VLSConfirmations__Group_2__3 : rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 ; public final void rule__VLSConfirmations__Group_2__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2019:1: ( rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 ) - // InternalVampireLanguage.g:2020:2: rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 + // InternalVampireLanguage.g:2050:1: ( rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 ) + // InternalVampireLanguage.g:2051:2: rule__VLSConfirmations__Group_2__3__Impl rule__VLSConfirmations__Group_2__4 { pushFollow(FOLLOW_18); rule__VLSConfirmations__Group_2__3__Impl(); @@ -6921,21 +7017,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__3__Impl" - // InternalVampireLanguage.g:2027:1: rule__VLSConfirmations__Group_2__3__Impl : ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) ; + // InternalVampireLanguage.g:2058:1: rule__VLSConfirmations__Group_2__3__Impl : ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) ; public final void rule__VLSConfirmations__Group_2__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2031:1: ( ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) ) - // InternalVampireLanguage.g:2032:1: ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) + // InternalVampireLanguage.g:2062:1: ( ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) ) + // InternalVampireLanguage.g:2063:1: ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) { - // InternalVampireLanguage.g:2032:1: ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) - // InternalVampireLanguage.g:2033:2: ( rule__VLSConfirmations__NameAssignment_2_3 ) + // InternalVampireLanguage.g:2063:1: ( ( rule__VLSConfirmations__NameAssignment_2_3 ) ) + // InternalVampireLanguage.g:2064:2: ( rule__VLSConfirmations__NameAssignment_2_3 ) { before(grammarAccess.getVLSConfirmationsAccess().getNameAssignment_2_3()); - // InternalVampireLanguage.g:2034:2: ( rule__VLSConfirmations__NameAssignment_2_3 ) - // InternalVampireLanguage.g:2034:3: rule__VLSConfirmations__NameAssignment_2_3 + // InternalVampireLanguage.g:2065:2: ( rule__VLSConfirmations__NameAssignment_2_3 ) + // InternalVampireLanguage.g:2065:3: rule__VLSConfirmations__NameAssignment_2_3 { pushFollow(FOLLOW_2); rule__VLSConfirmations__NameAssignment_2_3(); @@ -6968,14 +7064,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__4" - // InternalVampireLanguage.g:2042:1: rule__VLSConfirmations__Group_2__4 : rule__VLSConfirmations__Group_2__4__Impl ; + // InternalVampireLanguage.g:2073:1: rule__VLSConfirmations__Group_2__4 : rule__VLSConfirmations__Group_2__4__Impl ; public final void rule__VLSConfirmations__Group_2__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2046:1: ( rule__VLSConfirmations__Group_2__4__Impl ) - // InternalVampireLanguage.g:2047:2: rule__VLSConfirmations__Group_2__4__Impl + // InternalVampireLanguage.g:2077:1: ( rule__VLSConfirmations__Group_2__4__Impl ) + // InternalVampireLanguage.g:2078:2: rule__VLSConfirmations__Group_2__4__Impl { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_2__4__Impl(); @@ -7001,17 +7097,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_2__4__Impl" - // InternalVampireLanguage.g:2053:1: rule__VLSConfirmations__Group_2__4__Impl : ( ']' ) ; + // InternalVampireLanguage.g:2084:1: rule__VLSConfirmations__Group_2__4__Impl : ( ']' ) ; public final void rule__VLSConfirmations__Group_2__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2057:1: ( ( ']' ) ) - // InternalVampireLanguage.g:2058:1: ( ']' ) + // InternalVampireLanguage.g:2088:1: ( ( ']' ) ) + // InternalVampireLanguage.g:2089:1: ( ']' ) { - // InternalVampireLanguage.g:2058:1: ( ']' ) - // InternalVampireLanguage.g:2059:2: ']' + // InternalVampireLanguage.g:2089:1: ( ']' ) + // InternalVampireLanguage.g:2090:2: ']' { before(grammarAccess.getVLSConfirmationsAccess().getRightSquareBracketKeyword_2_4()); match(input,50,FOLLOW_2); @@ -7038,14 +7134,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__0" - // InternalVampireLanguage.g:2069:1: rule__VLSConfirmations__Group_3__0 : rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 ; + // InternalVampireLanguage.g:2100:1: rule__VLSConfirmations__Group_3__0 : rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 ; public final void rule__VLSConfirmations__Group_3__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2073:1: ( rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 ) - // InternalVampireLanguage.g:2074:2: rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 + // InternalVampireLanguage.g:2104:1: ( rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 ) + // InternalVampireLanguage.g:2105:2: rule__VLSConfirmations__Group_3__0__Impl rule__VLSConfirmations__Group_3__1 { pushFollow(FOLLOW_19); rule__VLSConfirmations__Group_3__0__Impl(); @@ -7076,21 +7172,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__0__Impl" - // InternalVampireLanguage.g:2081:1: rule__VLSConfirmations__Group_3__0__Impl : ( () ) ; + // InternalVampireLanguage.g:2112:1: rule__VLSConfirmations__Group_3__0__Impl : ( () ) ; public final void rule__VLSConfirmations__Group_3__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2085:1: ( ( () ) ) - // InternalVampireLanguage.g:2086:1: ( () ) + // InternalVampireLanguage.g:2116:1: ( ( () ) ) + // InternalVampireLanguage.g:2117:1: ( () ) { - // InternalVampireLanguage.g:2086:1: ( () ) - // InternalVampireLanguage.g:2087:2: () + // InternalVampireLanguage.g:2117:1: ( () ) + // InternalVampireLanguage.g:2118:2: () { before(grammarAccess.getVLSConfirmationsAccess().getVLSFiniteModelAction_3_0()); - // InternalVampireLanguage.g:2088:2: () - // InternalVampireLanguage.g:2088:3: + // InternalVampireLanguage.g:2119:2: () + // InternalVampireLanguage.g:2119:3: { } @@ -7113,14 +7209,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__1" - // InternalVampireLanguage.g:2096:1: rule__VLSConfirmations__Group_3__1 : rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 ; + // InternalVampireLanguage.g:2127:1: rule__VLSConfirmations__Group_3__1 : rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 ; public final void rule__VLSConfirmations__Group_3__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2100:1: ( rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 ) - // InternalVampireLanguage.g:2101:2: rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 + // InternalVampireLanguage.g:2131:1: ( rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 ) + // InternalVampireLanguage.g:2132:2: rule__VLSConfirmations__Group_3__1__Impl rule__VLSConfirmations__Group_3__2 { pushFollow(FOLLOW_20); rule__VLSConfirmations__Group_3__1__Impl(); @@ -7151,17 +7247,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__1__Impl" - // InternalVampireLanguage.g:2108:1: rule__VLSConfirmations__Group_3__1__Impl : ( 'Finite' ) ; + // InternalVampireLanguage.g:2139:1: rule__VLSConfirmations__Group_3__1__Impl : ( 'Finite' ) ; public final void rule__VLSConfirmations__Group_3__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2112:1: ( ( 'Finite' ) ) - // InternalVampireLanguage.g:2113:1: ( 'Finite' ) + // InternalVampireLanguage.g:2143:1: ( ( 'Finite' ) ) + // InternalVampireLanguage.g:2144:1: ( 'Finite' ) { - // InternalVampireLanguage.g:2113:1: ( 'Finite' ) - // InternalVampireLanguage.g:2114:2: 'Finite' + // InternalVampireLanguage.g:2144:1: ( 'Finite' ) + // InternalVampireLanguage.g:2145:2: 'Finite' { before(grammarAccess.getVLSConfirmationsAccess().getFiniteKeyword_3_1()); match(input,51,FOLLOW_2); @@ -7188,14 +7284,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__2" - // InternalVampireLanguage.g:2123:1: rule__VLSConfirmations__Group_3__2 : rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 ; + // InternalVampireLanguage.g:2154:1: rule__VLSConfirmations__Group_3__2 : rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 ; public final void rule__VLSConfirmations__Group_3__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2127:1: ( rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 ) - // InternalVampireLanguage.g:2128:2: rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 + // InternalVampireLanguage.g:2158:1: ( rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 ) + // InternalVampireLanguage.g:2159:2: rule__VLSConfirmations__Group_3__2__Impl rule__VLSConfirmations__Group_3__3 { pushFollow(FOLLOW_21); rule__VLSConfirmations__Group_3__2__Impl(); @@ -7226,17 +7322,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__2__Impl" - // InternalVampireLanguage.g:2135:1: rule__VLSConfirmations__Group_3__2__Impl : ( 'Model' ) ; + // InternalVampireLanguage.g:2166:1: rule__VLSConfirmations__Group_3__2__Impl : ( 'Model' ) ; public final void rule__VLSConfirmations__Group_3__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2139:1: ( ( 'Model' ) ) - // InternalVampireLanguage.g:2140:1: ( 'Model' ) + // InternalVampireLanguage.g:2170:1: ( ( 'Model' ) ) + // InternalVampireLanguage.g:2171:1: ( 'Model' ) { - // InternalVampireLanguage.g:2140:1: ( 'Model' ) - // InternalVampireLanguage.g:2141:2: 'Model' + // InternalVampireLanguage.g:2171:1: ( 'Model' ) + // InternalVampireLanguage.g:2172:2: 'Model' { before(grammarAccess.getVLSConfirmationsAccess().getModelKeyword_3_2()); match(input,52,FOLLOW_2); @@ -7263,14 +7359,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__3" - // InternalVampireLanguage.g:2150:1: rule__VLSConfirmations__Group_3__3 : rule__VLSConfirmations__Group_3__3__Impl ; + // InternalVampireLanguage.g:2181:1: rule__VLSConfirmations__Group_3__3 : rule__VLSConfirmations__Group_3__3__Impl ; public final void rule__VLSConfirmations__Group_3__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2154:1: ( rule__VLSConfirmations__Group_3__3__Impl ) - // InternalVampireLanguage.g:2155:2: rule__VLSConfirmations__Group_3__3__Impl + // InternalVampireLanguage.g:2185:1: ( rule__VLSConfirmations__Group_3__3__Impl ) + // InternalVampireLanguage.g:2186:2: rule__VLSConfirmations__Group_3__3__Impl { pushFollow(FOLLOW_2); rule__VLSConfirmations__Group_3__3__Impl(); @@ -7296,17 +7392,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__Group_3__3__Impl" - // InternalVampireLanguage.g:2161:1: rule__VLSConfirmations__Group_3__3__Impl : ( 'Found!' ) ; + // InternalVampireLanguage.g:2192:1: rule__VLSConfirmations__Group_3__3__Impl : ( 'Found!' ) ; public final void rule__VLSConfirmations__Group_3__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2165:1: ( ( 'Found!' ) ) - // InternalVampireLanguage.g:2166:1: ( 'Found!' ) + // InternalVampireLanguage.g:2196:1: ( ( 'Found!' ) ) + // InternalVampireLanguage.g:2197:1: ( 'Found!' ) { - // InternalVampireLanguage.g:2166:1: ( 'Found!' ) - // InternalVampireLanguage.g:2167:2: 'Found!' + // InternalVampireLanguage.g:2197:1: ( 'Found!' ) + // InternalVampireLanguage.g:2198:2: 'Found!' { before(grammarAccess.getVLSConfirmationsAccess().getFoundKeyword_3_3()); match(input,53,FOLLOW_2); @@ -7333,14 +7429,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__0" - // InternalVampireLanguage.g:2177:1: rule__VLSFofFormula__Group__0 : rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 ; + // InternalVampireLanguage.g:2208:1: rule__VLSFofFormula__Group__0 : rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 ; public final void rule__VLSFofFormula__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2181:1: ( rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 ) - // InternalVampireLanguage.g:2182:2: rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 + // InternalVampireLanguage.g:2212:1: ( rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 ) + // InternalVampireLanguage.g:2213:2: rule__VLSFofFormula__Group__0__Impl rule__VLSFofFormula__Group__1 { pushFollow(FOLLOW_22); rule__VLSFofFormula__Group__0__Impl(); @@ -7371,17 +7467,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__0__Impl" - // InternalVampireLanguage.g:2189:1: rule__VLSFofFormula__Group__0__Impl : ( 'fof' ) ; + // InternalVampireLanguage.g:2220:1: rule__VLSFofFormula__Group__0__Impl : ( 'fof' ) ; public final void rule__VLSFofFormula__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2193:1: ( ( 'fof' ) ) - // InternalVampireLanguage.g:2194:1: ( 'fof' ) + // InternalVampireLanguage.g:2224:1: ( ( 'fof' ) ) + // InternalVampireLanguage.g:2225:1: ( 'fof' ) { - // InternalVampireLanguage.g:2194:1: ( 'fof' ) - // InternalVampireLanguage.g:2195:2: 'fof' + // InternalVampireLanguage.g:2225:1: ( 'fof' ) + // InternalVampireLanguage.g:2226:2: 'fof' { before(grammarAccess.getVLSFofFormulaAccess().getFofKeyword_0()); match(input,54,FOLLOW_2); @@ -7408,14 +7504,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__1" - // InternalVampireLanguage.g:2204:1: rule__VLSFofFormula__Group__1 : rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 ; + // InternalVampireLanguage.g:2235:1: rule__VLSFofFormula__Group__1 : rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 ; public final void rule__VLSFofFormula__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2208:1: ( rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 ) - // InternalVampireLanguage.g:2209:2: rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 + // InternalVampireLanguage.g:2239:1: ( rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 ) + // InternalVampireLanguage.g:2240:2: rule__VLSFofFormula__Group__1__Impl rule__VLSFofFormula__Group__2 { pushFollow(FOLLOW_23); rule__VLSFofFormula__Group__1__Impl(); @@ -7446,17 +7542,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__1__Impl" - // InternalVampireLanguage.g:2216:1: rule__VLSFofFormula__Group__1__Impl : ( '(' ) ; + // InternalVampireLanguage.g:2247:1: rule__VLSFofFormula__Group__1__Impl : ( '(' ) ; public final void rule__VLSFofFormula__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2220:1: ( ( '(' ) ) - // InternalVampireLanguage.g:2221:1: ( '(' ) + // InternalVampireLanguage.g:2251:1: ( ( '(' ) ) + // InternalVampireLanguage.g:2252:1: ( '(' ) { - // InternalVampireLanguage.g:2221:1: ( '(' ) - // InternalVampireLanguage.g:2222:2: '(' + // InternalVampireLanguage.g:2252:1: ( '(' ) + // InternalVampireLanguage.g:2253:2: '(' { before(grammarAccess.getVLSFofFormulaAccess().getLeftParenthesisKeyword_1()); match(input,55,FOLLOW_2); @@ -7483,14 +7579,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__2" - // InternalVampireLanguage.g:2231:1: rule__VLSFofFormula__Group__2 : rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 ; + // InternalVampireLanguage.g:2262:1: rule__VLSFofFormula__Group__2 : rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 ; public final void rule__VLSFofFormula__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2235:1: ( rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 ) - // InternalVampireLanguage.g:2236:2: rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 + // InternalVampireLanguage.g:2266:1: ( rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 ) + // InternalVampireLanguage.g:2267:2: rule__VLSFofFormula__Group__2__Impl rule__VLSFofFormula__Group__3 { pushFollow(FOLLOW_24); rule__VLSFofFormula__Group__2__Impl(); @@ -7521,21 +7617,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__2__Impl" - // InternalVampireLanguage.g:2243:1: rule__VLSFofFormula__Group__2__Impl : ( ( rule__VLSFofFormula__NameAssignment_2 ) ) ; + // InternalVampireLanguage.g:2274:1: rule__VLSFofFormula__Group__2__Impl : ( ( rule__VLSFofFormula__NameAssignment_2 ) ) ; public final void rule__VLSFofFormula__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2247:1: ( ( ( rule__VLSFofFormula__NameAssignment_2 ) ) ) - // InternalVampireLanguage.g:2248:1: ( ( rule__VLSFofFormula__NameAssignment_2 ) ) + // InternalVampireLanguage.g:2278:1: ( ( ( rule__VLSFofFormula__NameAssignment_2 ) ) ) + // InternalVampireLanguage.g:2279:1: ( ( rule__VLSFofFormula__NameAssignment_2 ) ) { - // InternalVampireLanguage.g:2248:1: ( ( rule__VLSFofFormula__NameAssignment_2 ) ) - // InternalVampireLanguage.g:2249:2: ( rule__VLSFofFormula__NameAssignment_2 ) + // InternalVampireLanguage.g:2279:1: ( ( rule__VLSFofFormula__NameAssignment_2 ) ) + // InternalVampireLanguage.g:2280:2: ( rule__VLSFofFormula__NameAssignment_2 ) { before(grammarAccess.getVLSFofFormulaAccess().getNameAssignment_2()); - // InternalVampireLanguage.g:2250:2: ( rule__VLSFofFormula__NameAssignment_2 ) - // InternalVampireLanguage.g:2250:3: rule__VLSFofFormula__NameAssignment_2 + // InternalVampireLanguage.g:2281:2: ( rule__VLSFofFormula__NameAssignment_2 ) + // InternalVampireLanguage.g:2281:3: rule__VLSFofFormula__NameAssignment_2 { pushFollow(FOLLOW_2); rule__VLSFofFormula__NameAssignment_2(); @@ -7568,14 +7664,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__3" - // InternalVampireLanguage.g:2258:1: rule__VLSFofFormula__Group__3 : rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 ; + // InternalVampireLanguage.g:2289:1: rule__VLSFofFormula__Group__3 : rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 ; public final void rule__VLSFofFormula__Group__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2262:1: ( rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 ) - // InternalVampireLanguage.g:2263:2: rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 + // InternalVampireLanguage.g:2293:1: ( rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 ) + // InternalVampireLanguage.g:2294:2: rule__VLSFofFormula__Group__3__Impl rule__VLSFofFormula__Group__4 { pushFollow(FOLLOW_25); rule__VLSFofFormula__Group__3__Impl(); @@ -7606,17 +7702,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__3__Impl" - // InternalVampireLanguage.g:2270:1: rule__VLSFofFormula__Group__3__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2301:1: rule__VLSFofFormula__Group__3__Impl : ( ',' ) ; public final void rule__VLSFofFormula__Group__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2274:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2275:1: ( ',' ) + // InternalVampireLanguage.g:2305:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2306:1: ( ',' ) { - // InternalVampireLanguage.g:2275:1: ( ',' ) - // InternalVampireLanguage.g:2276:2: ',' + // InternalVampireLanguage.g:2306:1: ( ',' ) + // InternalVampireLanguage.g:2307:2: ',' { before(grammarAccess.getVLSFofFormulaAccess().getCommaKeyword_3()); match(input,56,FOLLOW_2); @@ -7643,14 +7739,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__4" - // InternalVampireLanguage.g:2285:1: rule__VLSFofFormula__Group__4 : rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 ; + // InternalVampireLanguage.g:2316:1: rule__VLSFofFormula__Group__4 : rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 ; public final void rule__VLSFofFormula__Group__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2289:1: ( rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 ) - // InternalVampireLanguage.g:2290:2: rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 + // InternalVampireLanguage.g:2320:1: ( rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 ) + // InternalVampireLanguage.g:2321:2: rule__VLSFofFormula__Group__4__Impl rule__VLSFofFormula__Group__5 { pushFollow(FOLLOW_24); rule__VLSFofFormula__Group__4__Impl(); @@ -7681,21 +7777,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__4__Impl" - // InternalVampireLanguage.g:2297:1: rule__VLSFofFormula__Group__4__Impl : ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) ; + // InternalVampireLanguage.g:2328:1: rule__VLSFofFormula__Group__4__Impl : ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) ; public final void rule__VLSFofFormula__Group__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2301:1: ( ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) ) - // InternalVampireLanguage.g:2302:1: ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) + // InternalVampireLanguage.g:2332:1: ( ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) ) + // InternalVampireLanguage.g:2333:1: ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) { - // InternalVampireLanguage.g:2302:1: ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) - // InternalVampireLanguage.g:2303:2: ( rule__VLSFofFormula__FofRoleAssignment_4 ) + // InternalVampireLanguage.g:2333:1: ( ( rule__VLSFofFormula__FofRoleAssignment_4 ) ) + // InternalVampireLanguage.g:2334:2: ( rule__VLSFofFormula__FofRoleAssignment_4 ) { before(grammarAccess.getVLSFofFormulaAccess().getFofRoleAssignment_4()); - // InternalVampireLanguage.g:2304:2: ( rule__VLSFofFormula__FofRoleAssignment_4 ) - // InternalVampireLanguage.g:2304:3: rule__VLSFofFormula__FofRoleAssignment_4 + // InternalVampireLanguage.g:2335:2: ( rule__VLSFofFormula__FofRoleAssignment_4 ) + // InternalVampireLanguage.g:2335:3: rule__VLSFofFormula__FofRoleAssignment_4 { pushFollow(FOLLOW_2); rule__VLSFofFormula__FofRoleAssignment_4(); @@ -7728,14 +7824,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__5" - // InternalVampireLanguage.g:2312:1: rule__VLSFofFormula__Group__5 : rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 ; + // InternalVampireLanguage.g:2343:1: rule__VLSFofFormula__Group__5 : rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 ; public final void rule__VLSFofFormula__Group__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2316:1: ( rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 ) - // InternalVampireLanguage.g:2317:2: rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 + // InternalVampireLanguage.g:2347:1: ( rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 ) + // InternalVampireLanguage.g:2348:2: rule__VLSFofFormula__Group__5__Impl rule__VLSFofFormula__Group__6 { pushFollow(FOLLOW_26); rule__VLSFofFormula__Group__5__Impl(); @@ -7766,17 +7862,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__5__Impl" - // InternalVampireLanguage.g:2324:1: rule__VLSFofFormula__Group__5__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2355:1: rule__VLSFofFormula__Group__5__Impl : ( ',' ) ; public final void rule__VLSFofFormula__Group__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2328:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2329:1: ( ',' ) + // InternalVampireLanguage.g:2359:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2360:1: ( ',' ) { - // InternalVampireLanguage.g:2329:1: ( ',' ) - // InternalVampireLanguage.g:2330:2: ',' + // InternalVampireLanguage.g:2360:1: ( ',' ) + // InternalVampireLanguage.g:2361:2: ',' { before(grammarAccess.getVLSFofFormulaAccess().getCommaKeyword_5()); match(input,56,FOLLOW_2); @@ -7803,14 +7899,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__6" - // InternalVampireLanguage.g:2339:1: rule__VLSFofFormula__Group__6 : rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 ; + // InternalVampireLanguage.g:2370:1: rule__VLSFofFormula__Group__6 : rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 ; public final void rule__VLSFofFormula__Group__6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2343:1: ( rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 ) - // InternalVampireLanguage.g:2344:2: rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 + // InternalVampireLanguage.g:2374:1: ( rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 ) + // InternalVampireLanguage.g:2375:2: rule__VLSFofFormula__Group__6__Impl rule__VLSFofFormula__Group__7 { pushFollow(FOLLOW_27); rule__VLSFofFormula__Group__6__Impl(); @@ -7841,21 +7937,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__6__Impl" - // InternalVampireLanguage.g:2351:1: rule__VLSFofFormula__Group__6__Impl : ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) ; + // InternalVampireLanguage.g:2382:1: rule__VLSFofFormula__Group__6__Impl : ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) ; public final void rule__VLSFofFormula__Group__6__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2355:1: ( ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) ) - // InternalVampireLanguage.g:2356:1: ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) + // InternalVampireLanguage.g:2386:1: ( ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) ) + // InternalVampireLanguage.g:2387:1: ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) { - // InternalVampireLanguage.g:2356:1: ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) - // InternalVampireLanguage.g:2357:2: ( rule__VLSFofFormula__FofFormulaAssignment_6 ) + // InternalVampireLanguage.g:2387:1: ( ( rule__VLSFofFormula__FofFormulaAssignment_6 ) ) + // InternalVampireLanguage.g:2388:2: ( rule__VLSFofFormula__FofFormulaAssignment_6 ) { before(grammarAccess.getVLSFofFormulaAccess().getFofFormulaAssignment_6()); - // InternalVampireLanguage.g:2358:2: ( rule__VLSFofFormula__FofFormulaAssignment_6 ) - // InternalVampireLanguage.g:2358:3: rule__VLSFofFormula__FofFormulaAssignment_6 + // InternalVampireLanguage.g:2389:2: ( rule__VLSFofFormula__FofFormulaAssignment_6 ) + // InternalVampireLanguage.g:2389:3: rule__VLSFofFormula__FofFormulaAssignment_6 { pushFollow(FOLLOW_2); rule__VLSFofFormula__FofFormulaAssignment_6(); @@ -7888,14 +7984,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__7" - // InternalVampireLanguage.g:2366:1: rule__VLSFofFormula__Group__7 : rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 ; + // InternalVampireLanguage.g:2397:1: rule__VLSFofFormula__Group__7 : rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 ; public final void rule__VLSFofFormula__Group__7() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2370:1: ( rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 ) - // InternalVampireLanguage.g:2371:2: rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 + // InternalVampireLanguage.g:2401:1: ( rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 ) + // InternalVampireLanguage.g:2402:2: rule__VLSFofFormula__Group__7__Impl rule__VLSFofFormula__Group__8 { pushFollow(FOLLOW_27); rule__VLSFofFormula__Group__7__Impl(); @@ -7926,20 +8022,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__7__Impl" - // InternalVampireLanguage.g:2378:1: rule__VLSFofFormula__Group__7__Impl : ( ( rule__VLSFofFormula__Group_7__0 )? ) ; + // InternalVampireLanguage.g:2409:1: rule__VLSFofFormula__Group__7__Impl : ( ( rule__VLSFofFormula__Group_7__0 )? ) ; public final void rule__VLSFofFormula__Group__7__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2382:1: ( ( ( rule__VLSFofFormula__Group_7__0 )? ) ) - // InternalVampireLanguage.g:2383:1: ( ( rule__VLSFofFormula__Group_7__0 )? ) + // InternalVampireLanguage.g:2413:1: ( ( ( rule__VLSFofFormula__Group_7__0 )? ) ) + // InternalVampireLanguage.g:2414:1: ( ( rule__VLSFofFormula__Group_7__0 )? ) { - // InternalVampireLanguage.g:2383:1: ( ( rule__VLSFofFormula__Group_7__0 )? ) - // InternalVampireLanguage.g:2384:2: ( rule__VLSFofFormula__Group_7__0 )? + // InternalVampireLanguage.g:2414:1: ( ( rule__VLSFofFormula__Group_7__0 )? ) + // InternalVampireLanguage.g:2415:2: ( rule__VLSFofFormula__Group_7__0 )? { before(grammarAccess.getVLSFofFormulaAccess().getGroup_7()); - // InternalVampireLanguage.g:2385:2: ( rule__VLSFofFormula__Group_7__0 )? + // InternalVampireLanguage.g:2416:2: ( rule__VLSFofFormula__Group_7__0 )? int alt29=2; int LA29_0 = input.LA(1); @@ -7948,7 +8044,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt29) { case 1 : - // InternalVampireLanguage.g:2385:3: rule__VLSFofFormula__Group_7__0 + // InternalVampireLanguage.g:2416:3: rule__VLSFofFormula__Group_7__0 { pushFollow(FOLLOW_2); rule__VLSFofFormula__Group_7__0(); @@ -7984,14 +8080,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__8" - // InternalVampireLanguage.g:2393:1: rule__VLSFofFormula__Group__8 : rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 ; + // InternalVampireLanguage.g:2424:1: rule__VLSFofFormula__Group__8 : rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 ; public final void rule__VLSFofFormula__Group__8() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2397:1: ( rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 ) - // InternalVampireLanguage.g:2398:2: rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 + // InternalVampireLanguage.g:2428:1: ( rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 ) + // InternalVampireLanguage.g:2429:2: rule__VLSFofFormula__Group__8__Impl rule__VLSFofFormula__Group__9 { pushFollow(FOLLOW_28); rule__VLSFofFormula__Group__8__Impl(); @@ -8022,17 +8118,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__8__Impl" - // InternalVampireLanguage.g:2405:1: rule__VLSFofFormula__Group__8__Impl : ( ')' ) ; + // InternalVampireLanguage.g:2436:1: rule__VLSFofFormula__Group__8__Impl : ( ')' ) ; public final void rule__VLSFofFormula__Group__8__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2409:1: ( ( ')' ) ) - // InternalVampireLanguage.g:2410:1: ( ')' ) + // InternalVampireLanguage.g:2440:1: ( ( ')' ) ) + // InternalVampireLanguage.g:2441:1: ( ')' ) { - // InternalVampireLanguage.g:2410:1: ( ')' ) - // InternalVampireLanguage.g:2411:2: ')' + // InternalVampireLanguage.g:2441:1: ( ')' ) + // InternalVampireLanguage.g:2442:2: ')' { before(grammarAccess.getVLSFofFormulaAccess().getRightParenthesisKeyword_8()); match(input,57,FOLLOW_2); @@ -8059,14 +8155,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__9" - // InternalVampireLanguage.g:2420:1: rule__VLSFofFormula__Group__9 : rule__VLSFofFormula__Group__9__Impl ; + // InternalVampireLanguage.g:2451:1: rule__VLSFofFormula__Group__9 : rule__VLSFofFormula__Group__9__Impl ; public final void rule__VLSFofFormula__Group__9() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2424:1: ( rule__VLSFofFormula__Group__9__Impl ) - // InternalVampireLanguage.g:2425:2: rule__VLSFofFormula__Group__9__Impl + // InternalVampireLanguage.g:2455:1: ( rule__VLSFofFormula__Group__9__Impl ) + // InternalVampireLanguage.g:2456:2: rule__VLSFofFormula__Group__9__Impl { pushFollow(FOLLOW_2); rule__VLSFofFormula__Group__9__Impl(); @@ -8092,17 +8188,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group__9__Impl" - // InternalVampireLanguage.g:2431:1: rule__VLSFofFormula__Group__9__Impl : ( '.' ) ; + // InternalVampireLanguage.g:2462:1: rule__VLSFofFormula__Group__9__Impl : ( '.' ) ; public final void rule__VLSFofFormula__Group__9__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2435:1: ( ( '.' ) ) - // InternalVampireLanguage.g:2436:1: ( '.' ) + // InternalVampireLanguage.g:2466:1: ( ( '.' ) ) + // InternalVampireLanguage.g:2467:1: ( '.' ) { - // InternalVampireLanguage.g:2436:1: ( '.' ) - // InternalVampireLanguage.g:2437:2: '.' + // InternalVampireLanguage.g:2467:1: ( '.' ) + // InternalVampireLanguage.g:2468:2: '.' { before(grammarAccess.getVLSFofFormulaAccess().getFullStopKeyword_9()); match(input,58,FOLLOW_2); @@ -8129,14 +8225,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group_7__0" - // InternalVampireLanguage.g:2447:1: rule__VLSFofFormula__Group_7__0 : rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 ; + // InternalVampireLanguage.g:2478:1: rule__VLSFofFormula__Group_7__0 : rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 ; public final void rule__VLSFofFormula__Group_7__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2451:1: ( rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 ) - // InternalVampireLanguage.g:2452:2: rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 + // InternalVampireLanguage.g:2482:1: ( rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 ) + // InternalVampireLanguage.g:2483:2: rule__VLSFofFormula__Group_7__0__Impl rule__VLSFofFormula__Group_7__1 { pushFollow(FOLLOW_29); rule__VLSFofFormula__Group_7__0__Impl(); @@ -8167,17 +8263,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group_7__0__Impl" - // InternalVampireLanguage.g:2459:1: rule__VLSFofFormula__Group_7__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2490:1: rule__VLSFofFormula__Group_7__0__Impl : ( ',' ) ; public final void rule__VLSFofFormula__Group_7__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2463:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2464:1: ( ',' ) + // InternalVampireLanguage.g:2494:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2495:1: ( ',' ) { - // InternalVampireLanguage.g:2464:1: ( ',' ) - // InternalVampireLanguage.g:2465:2: ',' + // InternalVampireLanguage.g:2495:1: ( ',' ) + // InternalVampireLanguage.g:2496:2: ',' { before(grammarAccess.getVLSFofFormulaAccess().getCommaKeyword_7_0()); match(input,56,FOLLOW_2); @@ -8204,14 +8300,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group_7__1" - // InternalVampireLanguage.g:2474:1: rule__VLSFofFormula__Group_7__1 : rule__VLSFofFormula__Group_7__1__Impl ; + // InternalVampireLanguage.g:2505:1: rule__VLSFofFormula__Group_7__1 : rule__VLSFofFormula__Group_7__1__Impl ; public final void rule__VLSFofFormula__Group_7__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2478:1: ( rule__VLSFofFormula__Group_7__1__Impl ) - // InternalVampireLanguage.g:2479:2: rule__VLSFofFormula__Group_7__1__Impl + // InternalVampireLanguage.g:2509:1: ( rule__VLSFofFormula__Group_7__1__Impl ) + // InternalVampireLanguage.g:2510:2: rule__VLSFofFormula__Group_7__1__Impl { pushFollow(FOLLOW_2); rule__VLSFofFormula__Group_7__1__Impl(); @@ -8237,21 +8333,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__Group_7__1__Impl" - // InternalVampireLanguage.g:2485:1: rule__VLSFofFormula__Group_7__1__Impl : ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) ; + // InternalVampireLanguage.g:2516:1: rule__VLSFofFormula__Group_7__1__Impl : ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) ; public final void rule__VLSFofFormula__Group_7__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2489:1: ( ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) ) - // InternalVampireLanguage.g:2490:1: ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) + // InternalVampireLanguage.g:2520:1: ( ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) ) + // InternalVampireLanguage.g:2521:1: ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) { - // InternalVampireLanguage.g:2490:1: ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) - // InternalVampireLanguage.g:2491:2: ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) + // InternalVampireLanguage.g:2521:1: ( ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) ) + // InternalVampireLanguage.g:2522:2: ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) { before(grammarAccess.getVLSFofFormulaAccess().getAnnotationsAssignment_7_1()); - // InternalVampireLanguage.g:2492:2: ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) - // InternalVampireLanguage.g:2492:3: rule__VLSFofFormula__AnnotationsAssignment_7_1 + // InternalVampireLanguage.g:2523:2: ( rule__VLSFofFormula__AnnotationsAssignment_7_1 ) + // InternalVampireLanguage.g:2523:3: rule__VLSFofFormula__AnnotationsAssignment_7_1 { pushFollow(FOLLOW_2); rule__VLSFofFormula__AnnotationsAssignment_7_1(); @@ -8284,14 +8380,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__0" - // InternalVampireLanguage.g:2501:1: rule__VLSTffFormula__Group__0 : rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 ; + // InternalVampireLanguage.g:2532:1: rule__VLSTffFormula__Group__0 : rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 ; public final void rule__VLSTffFormula__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2505:1: ( rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 ) - // InternalVampireLanguage.g:2506:2: rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 + // InternalVampireLanguage.g:2536:1: ( rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 ) + // InternalVampireLanguage.g:2537:2: rule__VLSTffFormula__Group__0__Impl rule__VLSTffFormula__Group__1 { pushFollow(FOLLOW_22); rule__VLSTffFormula__Group__0__Impl(); @@ -8322,17 +8418,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__0__Impl" - // InternalVampireLanguage.g:2513:1: rule__VLSTffFormula__Group__0__Impl : ( 'tff' ) ; + // InternalVampireLanguage.g:2544:1: rule__VLSTffFormula__Group__0__Impl : ( 'tff' ) ; public final void rule__VLSTffFormula__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2517:1: ( ( 'tff' ) ) - // InternalVampireLanguage.g:2518:1: ( 'tff' ) + // InternalVampireLanguage.g:2548:1: ( ( 'tff' ) ) + // InternalVampireLanguage.g:2549:1: ( 'tff' ) { - // InternalVampireLanguage.g:2518:1: ( 'tff' ) - // InternalVampireLanguage.g:2519:2: 'tff' + // InternalVampireLanguage.g:2549:1: ( 'tff' ) + // InternalVampireLanguage.g:2550:2: 'tff' { before(grammarAccess.getVLSTffFormulaAccess().getTffKeyword_0()); match(input,59,FOLLOW_2); @@ -8359,14 +8455,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__1" - // InternalVampireLanguage.g:2528:1: rule__VLSTffFormula__Group__1 : rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 ; + // InternalVampireLanguage.g:2559:1: rule__VLSTffFormula__Group__1 : rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 ; public final void rule__VLSTffFormula__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2532:1: ( rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 ) - // InternalVampireLanguage.g:2533:2: rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 + // InternalVampireLanguage.g:2563:1: ( rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 ) + // InternalVampireLanguage.g:2564:2: rule__VLSTffFormula__Group__1__Impl rule__VLSTffFormula__Group__2 { pushFollow(FOLLOW_30); rule__VLSTffFormula__Group__1__Impl(); @@ -8397,17 +8493,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__1__Impl" - // InternalVampireLanguage.g:2540:1: rule__VLSTffFormula__Group__1__Impl : ( '(' ) ; + // InternalVampireLanguage.g:2571:1: rule__VLSTffFormula__Group__1__Impl : ( '(' ) ; public final void rule__VLSTffFormula__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2544:1: ( ( '(' ) ) - // InternalVampireLanguage.g:2545:1: ( '(' ) + // InternalVampireLanguage.g:2575:1: ( ( '(' ) ) + // InternalVampireLanguage.g:2576:1: ( '(' ) { - // InternalVampireLanguage.g:2545:1: ( '(' ) - // InternalVampireLanguage.g:2546:2: '(' + // InternalVampireLanguage.g:2576:1: ( '(' ) + // InternalVampireLanguage.g:2577:2: '(' { before(grammarAccess.getVLSTffFormulaAccess().getLeftParenthesisKeyword_1()); match(input,55,FOLLOW_2); @@ -8434,14 +8530,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__2" - // InternalVampireLanguage.g:2555:1: rule__VLSTffFormula__Group__2 : rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 ; + // InternalVampireLanguage.g:2586:1: rule__VLSTffFormula__Group__2 : rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 ; public final void rule__VLSTffFormula__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2559:1: ( rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 ) - // InternalVampireLanguage.g:2560:2: rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 + // InternalVampireLanguage.g:2590:1: ( rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 ) + // InternalVampireLanguage.g:2591:2: rule__VLSTffFormula__Group__2__Impl rule__VLSTffFormula__Group__3 { pushFollow(FOLLOW_24); rule__VLSTffFormula__Group__2__Impl(); @@ -8472,21 +8568,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__2__Impl" - // InternalVampireLanguage.g:2567:1: rule__VLSTffFormula__Group__2__Impl : ( ( rule__VLSTffFormula__NameAssignment_2 ) ) ; + // InternalVampireLanguage.g:2598:1: rule__VLSTffFormula__Group__2__Impl : ( ( rule__VLSTffFormula__NameAssignment_2 ) ) ; public final void rule__VLSTffFormula__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2571:1: ( ( ( rule__VLSTffFormula__NameAssignment_2 ) ) ) - // InternalVampireLanguage.g:2572:1: ( ( rule__VLSTffFormula__NameAssignment_2 ) ) + // InternalVampireLanguage.g:2602:1: ( ( ( rule__VLSTffFormula__NameAssignment_2 ) ) ) + // InternalVampireLanguage.g:2603:1: ( ( rule__VLSTffFormula__NameAssignment_2 ) ) { - // InternalVampireLanguage.g:2572:1: ( ( rule__VLSTffFormula__NameAssignment_2 ) ) - // InternalVampireLanguage.g:2573:2: ( rule__VLSTffFormula__NameAssignment_2 ) + // InternalVampireLanguage.g:2603:1: ( ( rule__VLSTffFormula__NameAssignment_2 ) ) + // InternalVampireLanguage.g:2604:2: ( rule__VLSTffFormula__NameAssignment_2 ) { before(grammarAccess.getVLSTffFormulaAccess().getNameAssignment_2()); - // InternalVampireLanguage.g:2574:2: ( rule__VLSTffFormula__NameAssignment_2 ) - // InternalVampireLanguage.g:2574:3: rule__VLSTffFormula__NameAssignment_2 + // InternalVampireLanguage.g:2605:2: ( rule__VLSTffFormula__NameAssignment_2 ) + // InternalVampireLanguage.g:2605:3: rule__VLSTffFormula__NameAssignment_2 { pushFollow(FOLLOW_2); rule__VLSTffFormula__NameAssignment_2(); @@ -8519,14 +8615,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__3" - // InternalVampireLanguage.g:2582:1: rule__VLSTffFormula__Group__3 : rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 ; + // InternalVampireLanguage.g:2613:1: rule__VLSTffFormula__Group__3 : rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 ; public final void rule__VLSTffFormula__Group__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2586:1: ( rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 ) - // InternalVampireLanguage.g:2587:2: rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 + // InternalVampireLanguage.g:2617:1: ( rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 ) + // InternalVampireLanguage.g:2618:2: rule__VLSTffFormula__Group__3__Impl rule__VLSTffFormula__Group__4 { pushFollow(FOLLOW_25); rule__VLSTffFormula__Group__3__Impl(); @@ -8557,17 +8653,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__3__Impl" - // InternalVampireLanguage.g:2594:1: rule__VLSTffFormula__Group__3__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2625:1: rule__VLSTffFormula__Group__3__Impl : ( ',' ) ; public final void rule__VLSTffFormula__Group__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2598:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2599:1: ( ',' ) + // InternalVampireLanguage.g:2629:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2630:1: ( ',' ) { - // InternalVampireLanguage.g:2599:1: ( ',' ) - // InternalVampireLanguage.g:2600:2: ',' + // InternalVampireLanguage.g:2630:1: ( ',' ) + // InternalVampireLanguage.g:2631:2: ',' { before(grammarAccess.getVLSTffFormulaAccess().getCommaKeyword_3()); match(input,56,FOLLOW_2); @@ -8594,14 +8690,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__4" - // InternalVampireLanguage.g:2609:1: rule__VLSTffFormula__Group__4 : rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 ; + // InternalVampireLanguage.g:2640:1: rule__VLSTffFormula__Group__4 : rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 ; public final void rule__VLSTffFormula__Group__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2613:1: ( rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 ) - // InternalVampireLanguage.g:2614:2: rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 + // InternalVampireLanguage.g:2644:1: ( rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 ) + // InternalVampireLanguage.g:2645:2: rule__VLSTffFormula__Group__4__Impl rule__VLSTffFormula__Group__5 { pushFollow(FOLLOW_24); rule__VLSTffFormula__Group__4__Impl(); @@ -8632,21 +8728,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__4__Impl" - // InternalVampireLanguage.g:2621:1: rule__VLSTffFormula__Group__4__Impl : ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) ; + // InternalVampireLanguage.g:2652:1: rule__VLSTffFormula__Group__4__Impl : ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) ; public final void rule__VLSTffFormula__Group__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2625:1: ( ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) ) - // InternalVampireLanguage.g:2626:1: ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) + // InternalVampireLanguage.g:2656:1: ( ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) ) + // InternalVampireLanguage.g:2657:1: ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) { - // InternalVampireLanguage.g:2626:1: ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) - // InternalVampireLanguage.g:2627:2: ( rule__VLSTffFormula__TffRoleAssignment_4 ) + // InternalVampireLanguage.g:2657:1: ( ( rule__VLSTffFormula__TffRoleAssignment_4 ) ) + // InternalVampireLanguage.g:2658:2: ( rule__VLSTffFormula__TffRoleAssignment_4 ) { before(grammarAccess.getVLSTffFormulaAccess().getTffRoleAssignment_4()); - // InternalVampireLanguage.g:2628:2: ( rule__VLSTffFormula__TffRoleAssignment_4 ) - // InternalVampireLanguage.g:2628:3: rule__VLSTffFormula__TffRoleAssignment_4 + // InternalVampireLanguage.g:2659:2: ( rule__VLSTffFormula__TffRoleAssignment_4 ) + // InternalVampireLanguage.g:2659:3: rule__VLSTffFormula__TffRoleAssignment_4 { pushFollow(FOLLOW_2); rule__VLSTffFormula__TffRoleAssignment_4(); @@ -8679,16 +8775,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__5" - // InternalVampireLanguage.g:2636:1: rule__VLSTffFormula__Group__5 : rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 ; + // InternalVampireLanguage.g:2667:1: rule__VLSTffFormula__Group__5 : rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 ; public final void rule__VLSTffFormula__Group__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2640:1: ( rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 ) - // InternalVampireLanguage.g:2641:2: rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 + // InternalVampireLanguage.g:2671:1: ( rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 ) + // InternalVampireLanguage.g:2672:2: rule__VLSTffFormula__Group__5__Impl rule__VLSTffFormula__Group__6 { - pushFollow(FOLLOW_26); + pushFollow(FOLLOW_31); rule__VLSTffFormula__Group__5__Impl(); state._fsp--; @@ -8717,17 +8813,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__5__Impl" - // InternalVampireLanguage.g:2648:1: rule__VLSTffFormula__Group__5__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2679:1: rule__VLSTffFormula__Group__5__Impl : ( ',' ) ; public final void rule__VLSTffFormula__Group__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2652:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2653:1: ( ',' ) + // InternalVampireLanguage.g:2683:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2684:1: ( ',' ) { - // InternalVampireLanguage.g:2653:1: ( ',' ) - // InternalVampireLanguage.g:2654:2: ',' + // InternalVampireLanguage.g:2684:1: ( ',' ) + // InternalVampireLanguage.g:2685:2: ',' { before(grammarAccess.getVLSTffFormulaAccess().getCommaKeyword_5()); match(input,56,FOLLOW_2); @@ -8754,14 +8850,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__6" - // InternalVampireLanguage.g:2663:1: rule__VLSTffFormula__Group__6 : rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 ; + // InternalVampireLanguage.g:2694:1: rule__VLSTffFormula__Group__6 : rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 ; public final void rule__VLSTffFormula__Group__6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2667:1: ( rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 ) - // InternalVampireLanguage.g:2668:2: rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 + // InternalVampireLanguage.g:2698:1: ( rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 ) + // InternalVampireLanguage.g:2699:2: rule__VLSTffFormula__Group__6__Impl rule__VLSTffFormula__Group__7 { pushFollow(FOLLOW_27); rule__VLSTffFormula__Group__6__Impl(); @@ -8792,21 +8888,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__6__Impl" - // InternalVampireLanguage.g:2675:1: rule__VLSTffFormula__Group__6__Impl : ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) ; + // InternalVampireLanguage.g:2706:1: rule__VLSTffFormula__Group__6__Impl : ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) ; public final void rule__VLSTffFormula__Group__6__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2679:1: ( ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) ) - // InternalVampireLanguage.g:2680:1: ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) + // InternalVampireLanguage.g:2710:1: ( ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) ) + // InternalVampireLanguage.g:2711:1: ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) { - // InternalVampireLanguage.g:2680:1: ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) - // InternalVampireLanguage.g:2681:2: ( rule__VLSTffFormula__FofFormulaAssignment_6 ) + // InternalVampireLanguage.g:2711:1: ( ( rule__VLSTffFormula__FofFormulaAssignment_6 ) ) + // InternalVampireLanguage.g:2712:2: ( rule__VLSTffFormula__FofFormulaAssignment_6 ) { before(grammarAccess.getVLSTffFormulaAccess().getFofFormulaAssignment_6()); - // InternalVampireLanguage.g:2682:2: ( rule__VLSTffFormula__FofFormulaAssignment_6 ) - // InternalVampireLanguage.g:2682:3: rule__VLSTffFormula__FofFormulaAssignment_6 + // InternalVampireLanguage.g:2713:2: ( rule__VLSTffFormula__FofFormulaAssignment_6 ) + // InternalVampireLanguage.g:2713:3: rule__VLSTffFormula__FofFormulaAssignment_6 { pushFollow(FOLLOW_2); rule__VLSTffFormula__FofFormulaAssignment_6(); @@ -8839,14 +8935,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__7" - // InternalVampireLanguage.g:2690:1: rule__VLSTffFormula__Group__7 : rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 ; + // InternalVampireLanguage.g:2721:1: rule__VLSTffFormula__Group__7 : rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 ; public final void rule__VLSTffFormula__Group__7() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2694:1: ( rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 ) - // InternalVampireLanguage.g:2695:2: rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 + // InternalVampireLanguage.g:2725:1: ( rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 ) + // InternalVampireLanguage.g:2726:2: rule__VLSTffFormula__Group__7__Impl rule__VLSTffFormula__Group__8 { pushFollow(FOLLOW_27); rule__VLSTffFormula__Group__7__Impl(); @@ -8877,20 +8973,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__7__Impl" - // InternalVampireLanguage.g:2702:1: rule__VLSTffFormula__Group__7__Impl : ( ( rule__VLSTffFormula__Group_7__0 )? ) ; + // InternalVampireLanguage.g:2733:1: rule__VLSTffFormula__Group__7__Impl : ( ( rule__VLSTffFormula__Group_7__0 )? ) ; public final void rule__VLSTffFormula__Group__7__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2706:1: ( ( ( rule__VLSTffFormula__Group_7__0 )? ) ) - // InternalVampireLanguage.g:2707:1: ( ( rule__VLSTffFormula__Group_7__0 )? ) + // InternalVampireLanguage.g:2737:1: ( ( ( rule__VLSTffFormula__Group_7__0 )? ) ) + // InternalVampireLanguage.g:2738:1: ( ( rule__VLSTffFormula__Group_7__0 )? ) { - // InternalVampireLanguage.g:2707:1: ( ( rule__VLSTffFormula__Group_7__0 )? ) - // InternalVampireLanguage.g:2708:2: ( rule__VLSTffFormula__Group_7__0 )? + // InternalVampireLanguage.g:2738:1: ( ( rule__VLSTffFormula__Group_7__0 )? ) + // InternalVampireLanguage.g:2739:2: ( rule__VLSTffFormula__Group_7__0 )? { before(grammarAccess.getVLSTffFormulaAccess().getGroup_7()); - // InternalVampireLanguage.g:2709:2: ( rule__VLSTffFormula__Group_7__0 )? + // InternalVampireLanguage.g:2740:2: ( rule__VLSTffFormula__Group_7__0 )? int alt30=2; int LA30_0 = input.LA(1); @@ -8899,7 +8995,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt30) { case 1 : - // InternalVampireLanguage.g:2709:3: rule__VLSTffFormula__Group_7__0 + // InternalVampireLanguage.g:2740:3: rule__VLSTffFormula__Group_7__0 { pushFollow(FOLLOW_2); rule__VLSTffFormula__Group_7__0(); @@ -8935,14 +9031,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__8" - // InternalVampireLanguage.g:2717:1: rule__VLSTffFormula__Group__8 : rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 ; + // InternalVampireLanguage.g:2748:1: rule__VLSTffFormula__Group__8 : rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 ; public final void rule__VLSTffFormula__Group__8() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2721:1: ( rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 ) - // InternalVampireLanguage.g:2722:2: rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 + // InternalVampireLanguage.g:2752:1: ( rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 ) + // InternalVampireLanguage.g:2753:2: rule__VLSTffFormula__Group__8__Impl rule__VLSTffFormula__Group__9 { pushFollow(FOLLOW_28); rule__VLSTffFormula__Group__8__Impl(); @@ -8973,17 +9069,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__8__Impl" - // InternalVampireLanguage.g:2729:1: rule__VLSTffFormula__Group__8__Impl : ( ')' ) ; + // InternalVampireLanguage.g:2760:1: rule__VLSTffFormula__Group__8__Impl : ( ')' ) ; public final void rule__VLSTffFormula__Group__8__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2733:1: ( ( ')' ) ) - // InternalVampireLanguage.g:2734:1: ( ')' ) + // InternalVampireLanguage.g:2764:1: ( ( ')' ) ) + // InternalVampireLanguage.g:2765:1: ( ')' ) { - // InternalVampireLanguage.g:2734:1: ( ')' ) - // InternalVampireLanguage.g:2735:2: ')' + // InternalVampireLanguage.g:2765:1: ( ')' ) + // InternalVampireLanguage.g:2766:2: ')' { before(grammarAccess.getVLSTffFormulaAccess().getRightParenthesisKeyword_8()); match(input,57,FOLLOW_2); @@ -9010,14 +9106,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__9" - // InternalVampireLanguage.g:2744:1: rule__VLSTffFormula__Group__9 : rule__VLSTffFormula__Group__9__Impl ; + // InternalVampireLanguage.g:2775:1: rule__VLSTffFormula__Group__9 : rule__VLSTffFormula__Group__9__Impl ; public final void rule__VLSTffFormula__Group__9() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2748:1: ( rule__VLSTffFormula__Group__9__Impl ) - // InternalVampireLanguage.g:2749:2: rule__VLSTffFormula__Group__9__Impl + // InternalVampireLanguage.g:2779:1: ( rule__VLSTffFormula__Group__9__Impl ) + // InternalVampireLanguage.g:2780:2: rule__VLSTffFormula__Group__9__Impl { pushFollow(FOLLOW_2); rule__VLSTffFormula__Group__9__Impl(); @@ -9043,17 +9139,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group__9__Impl" - // InternalVampireLanguage.g:2755:1: rule__VLSTffFormula__Group__9__Impl : ( '.' ) ; + // InternalVampireLanguage.g:2786:1: rule__VLSTffFormula__Group__9__Impl : ( '.' ) ; public final void rule__VLSTffFormula__Group__9__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2759:1: ( ( '.' ) ) - // InternalVampireLanguage.g:2760:1: ( '.' ) + // InternalVampireLanguage.g:2790:1: ( ( '.' ) ) + // InternalVampireLanguage.g:2791:1: ( '.' ) { - // InternalVampireLanguage.g:2760:1: ( '.' ) - // InternalVampireLanguage.g:2761:2: '.' + // InternalVampireLanguage.g:2791:1: ( '.' ) + // InternalVampireLanguage.g:2792:2: '.' { before(grammarAccess.getVLSTffFormulaAccess().getFullStopKeyword_9()); match(input,58,FOLLOW_2); @@ -9080,14 +9176,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group_7__0" - // InternalVampireLanguage.g:2771:1: rule__VLSTffFormula__Group_7__0 : rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 ; + // InternalVampireLanguage.g:2802:1: rule__VLSTffFormula__Group_7__0 : rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 ; public final void rule__VLSTffFormula__Group_7__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2775:1: ( rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 ) - // InternalVampireLanguage.g:2776:2: rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 + // InternalVampireLanguage.g:2806:1: ( rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 ) + // InternalVampireLanguage.g:2807:2: rule__VLSTffFormula__Group_7__0__Impl rule__VLSTffFormula__Group_7__1 { pushFollow(FOLLOW_29); rule__VLSTffFormula__Group_7__0__Impl(); @@ -9118,17 +9214,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group_7__0__Impl" - // InternalVampireLanguage.g:2783:1: rule__VLSTffFormula__Group_7__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:2814:1: rule__VLSTffFormula__Group_7__0__Impl : ( ',' ) ; public final void rule__VLSTffFormula__Group_7__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2787:1: ( ( ',' ) ) - // InternalVampireLanguage.g:2788:1: ( ',' ) + // InternalVampireLanguage.g:2818:1: ( ( ',' ) ) + // InternalVampireLanguage.g:2819:1: ( ',' ) { - // InternalVampireLanguage.g:2788:1: ( ',' ) - // InternalVampireLanguage.g:2789:2: ',' + // InternalVampireLanguage.g:2819:1: ( ',' ) + // InternalVampireLanguage.g:2820:2: ',' { before(grammarAccess.getVLSTffFormulaAccess().getCommaKeyword_7_0()); match(input,56,FOLLOW_2); @@ -9155,14 +9251,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group_7__1" - // InternalVampireLanguage.g:2798:1: rule__VLSTffFormula__Group_7__1 : rule__VLSTffFormula__Group_7__1__Impl ; + // InternalVampireLanguage.g:2829:1: rule__VLSTffFormula__Group_7__1 : rule__VLSTffFormula__Group_7__1__Impl ; public final void rule__VLSTffFormula__Group_7__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2802:1: ( rule__VLSTffFormula__Group_7__1__Impl ) - // InternalVampireLanguage.g:2803:2: rule__VLSTffFormula__Group_7__1__Impl + // InternalVampireLanguage.g:2833:1: ( rule__VLSTffFormula__Group_7__1__Impl ) + // InternalVampireLanguage.g:2834:2: rule__VLSTffFormula__Group_7__1__Impl { pushFollow(FOLLOW_2); rule__VLSTffFormula__Group_7__1__Impl(); @@ -9188,21 +9284,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__Group_7__1__Impl" - // InternalVampireLanguage.g:2809:1: rule__VLSTffFormula__Group_7__1__Impl : ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) ; + // InternalVampireLanguage.g:2840:1: rule__VLSTffFormula__Group_7__1__Impl : ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) ; public final void rule__VLSTffFormula__Group_7__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2813:1: ( ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) ) - // InternalVampireLanguage.g:2814:1: ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) + // InternalVampireLanguage.g:2844:1: ( ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) ) + // InternalVampireLanguage.g:2845:1: ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) { - // InternalVampireLanguage.g:2814:1: ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) - // InternalVampireLanguage.g:2815:2: ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) + // InternalVampireLanguage.g:2845:1: ( ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) ) + // InternalVampireLanguage.g:2846:2: ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) { before(grammarAccess.getVLSTffFormulaAccess().getAnnotationsAssignment_7_1()); - // InternalVampireLanguage.g:2816:2: ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) - // InternalVampireLanguage.g:2816:3: rule__VLSTffFormula__AnnotationsAssignment_7_1 + // InternalVampireLanguage.g:2847:2: ( rule__VLSTffFormula__AnnotationsAssignment_7_1 ) + // InternalVampireLanguage.g:2847:3: rule__VLSTffFormula__AnnotationsAssignment_7_1 { pushFollow(FOLLOW_2); rule__VLSTffFormula__AnnotationsAssignment_7_1(); @@ -9235,16 +9331,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffDeclPred__Group_0__0" - // InternalVampireLanguage.g:2825:1: rule__VLSTffDeclPred__Group_0__0 : rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 ; + // InternalVampireLanguage.g:2856:1: rule__VLSTffDeclPred__Group_0__0 : rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 ; public final void rule__VLSTffDeclPred__Group_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2829:1: ( rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 ) - // InternalVampireLanguage.g:2830:2: rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 + // InternalVampireLanguage.g:2860:1: ( rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 ) + // InternalVampireLanguage.g:2861:2: rule__VLSTffDeclPred__Group_0__0__Impl rule__VLSTffDeclPred__Group_0__1 { - pushFollow(FOLLOW_31); + pushFollow(FOLLOW_32); rule__VLSTffDeclPred__Group_0__0__Impl(); state._fsp--; @@ -9273,17 +9369,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffDeclPred__Group_0__0__Impl" - // InternalVampireLanguage.g:2837:1: rule__VLSTffDeclPred__Group_0__0__Impl : ( 'declare_' ) ; + // InternalVampireLanguage.g:2868:1: rule__VLSTffDeclPred__Group_0__0__Impl : ( 'declare_' ) ; public final void rule__VLSTffDeclPred__Group_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2841:1: ( ( 'declare_' ) ) - // InternalVampireLanguage.g:2842:1: ( 'declare_' ) + // InternalVampireLanguage.g:2872:1: ( ( 'declare_' ) ) + // InternalVampireLanguage.g:2873:1: ( 'declare_' ) { - // InternalVampireLanguage.g:2842:1: ( 'declare_' ) - // InternalVampireLanguage.g:2843:2: 'declare_' + // InternalVampireLanguage.g:2873:1: ( 'declare_' ) + // InternalVampireLanguage.g:2874:2: 'declare_' { before(grammarAccess.getVLSTffDeclPredAccess().getDeclare_Keyword_0_0()); match(input,60,FOLLOW_2); @@ -9310,14 +9406,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffDeclPred__Group_0__1" - // InternalVampireLanguage.g:2852:1: rule__VLSTffDeclPred__Group_0__1 : rule__VLSTffDeclPred__Group_0__1__Impl ; + // InternalVampireLanguage.g:2883:1: rule__VLSTffDeclPred__Group_0__1 : rule__VLSTffDeclPred__Group_0__1__Impl ; public final void rule__VLSTffDeclPred__Group_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2856:1: ( rule__VLSTffDeclPred__Group_0__1__Impl ) - // InternalVampireLanguage.g:2857:2: rule__VLSTffDeclPred__Group_0__1__Impl + // InternalVampireLanguage.g:2887:1: ( rule__VLSTffDeclPred__Group_0__1__Impl ) + // InternalVampireLanguage.g:2888:2: rule__VLSTffDeclPred__Group_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSTffDeclPred__Group_0__1__Impl(); @@ -9343,17 +9439,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffDeclPred__Group_0__1__Impl" - // InternalVampireLanguage.g:2863:1: rule__VLSTffDeclPred__Group_0__1__Impl : ( RULE_DOLLAR_ID ) ; + // InternalVampireLanguage.g:2894:1: rule__VLSTffDeclPred__Group_0__1__Impl : ( RULE_DOLLAR_ID ) ; public final void rule__VLSTffDeclPred__Group_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2867:1: ( ( RULE_DOLLAR_ID ) ) - // InternalVampireLanguage.g:2868:1: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:2898:1: ( ( RULE_DOLLAR_ID ) ) + // InternalVampireLanguage.g:2899:1: ( RULE_DOLLAR_ID ) { - // InternalVampireLanguage.g:2868:1: ( RULE_DOLLAR_ID ) - // InternalVampireLanguage.g:2869:2: RULE_DOLLAR_ID + // InternalVampireLanguage.g:2899:1: ( RULE_DOLLAR_ID ) + // InternalVampireLanguage.g:2900:2: RULE_DOLLAR_ID { before(grammarAccess.getVLSTffDeclPredAccess().getDOLLAR_IDTerminalRuleCall_0_1()); match(input,RULE_DOLLAR_ID,FOLLOW_2); @@ -9380,14 +9476,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__0" - // InternalVampireLanguage.g:2879:1: rule__VLSAnnotation__Group__0 : rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 ; + // InternalVampireLanguage.g:2910:1: rule__VLSAnnotation__Group__0 : rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 ; public final void rule__VLSAnnotation__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2883:1: ( rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 ) - // InternalVampireLanguage.g:2884:2: rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 + // InternalVampireLanguage.g:2914:1: ( rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 ) + // InternalVampireLanguage.g:2915:2: rule__VLSAnnotation__Group__0__Impl rule__VLSAnnotation__Group__1 { pushFollow(FOLLOW_29); rule__VLSAnnotation__Group__0__Impl(); @@ -9418,20 +9514,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__0__Impl" - // InternalVampireLanguage.g:2891:1: rule__VLSAnnotation__Group__0__Impl : ( ( '[' )? ) ; + // InternalVampireLanguage.g:2922:1: rule__VLSAnnotation__Group__0__Impl : ( ( '[' )? ) ; public final void rule__VLSAnnotation__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2895:1: ( ( ( '[' )? ) ) - // InternalVampireLanguage.g:2896:1: ( ( '[' )? ) + // InternalVampireLanguage.g:2926:1: ( ( ( '[' )? ) ) + // InternalVampireLanguage.g:2927:1: ( ( '[' )? ) { - // InternalVampireLanguage.g:2896:1: ( ( '[' )? ) - // InternalVampireLanguage.g:2897:2: ( '[' )? + // InternalVampireLanguage.g:2927:1: ( ( '[' )? ) + // InternalVampireLanguage.g:2928:2: ( '[' )? { before(grammarAccess.getVLSAnnotationAccess().getLeftSquareBracketKeyword_0()); - // InternalVampireLanguage.g:2898:2: ( '[' )? + // InternalVampireLanguage.g:2929:2: ( '[' )? int alt31=2; int LA31_0 = input.LA(1); @@ -9440,7 +9536,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt31) { case 1 : - // InternalVampireLanguage.g:2898:3: '[' + // InternalVampireLanguage.g:2929:3: '[' { match(input,49,FOLLOW_2); @@ -9472,14 +9568,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__1" - // InternalVampireLanguage.g:2906:1: rule__VLSAnnotation__Group__1 : rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 ; + // InternalVampireLanguage.g:2937:1: rule__VLSAnnotation__Group__1 : rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 ; public final void rule__VLSAnnotation__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2910:1: ( rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 ) - // InternalVampireLanguage.g:2911:2: rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 + // InternalVampireLanguage.g:2941:1: ( rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 ) + // InternalVampireLanguage.g:2942:2: rule__VLSAnnotation__Group__1__Impl rule__VLSAnnotation__Group__2 { pushFollow(FOLLOW_29); rule__VLSAnnotation__Group__1__Impl(); @@ -9510,20 +9606,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__1__Impl" - // InternalVampireLanguage.g:2918:1: rule__VLSAnnotation__Group__1__Impl : ( ( rule__VLSAnnotation__NameAssignment_1 )? ) ; + // InternalVampireLanguage.g:2949:1: rule__VLSAnnotation__Group__1__Impl : ( ( rule__VLSAnnotation__NameAssignment_1 )? ) ; public final void rule__VLSAnnotation__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2922:1: ( ( ( rule__VLSAnnotation__NameAssignment_1 )? ) ) - // InternalVampireLanguage.g:2923:1: ( ( rule__VLSAnnotation__NameAssignment_1 )? ) + // InternalVampireLanguage.g:2953:1: ( ( ( rule__VLSAnnotation__NameAssignment_1 )? ) ) + // InternalVampireLanguage.g:2954:1: ( ( rule__VLSAnnotation__NameAssignment_1 )? ) { - // InternalVampireLanguage.g:2923:1: ( ( rule__VLSAnnotation__NameAssignment_1 )? ) - // InternalVampireLanguage.g:2924:2: ( rule__VLSAnnotation__NameAssignment_1 )? + // InternalVampireLanguage.g:2954:1: ( ( rule__VLSAnnotation__NameAssignment_1 )? ) + // InternalVampireLanguage.g:2955:2: ( rule__VLSAnnotation__NameAssignment_1 )? { before(grammarAccess.getVLSAnnotationAccess().getNameAssignment_1()); - // InternalVampireLanguage.g:2925:2: ( rule__VLSAnnotation__NameAssignment_1 )? + // InternalVampireLanguage.g:2956:2: ( rule__VLSAnnotation__NameAssignment_1 )? int alt32=2; int LA32_0 = input.LA(1); @@ -9532,7 +9628,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt32) { case 1 : - // InternalVampireLanguage.g:2925:3: rule__VLSAnnotation__NameAssignment_1 + // InternalVampireLanguage.g:2956:3: rule__VLSAnnotation__NameAssignment_1 { pushFollow(FOLLOW_2); rule__VLSAnnotation__NameAssignment_1(); @@ -9568,14 +9664,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__2" - // InternalVampireLanguage.g:2933:1: rule__VLSAnnotation__Group__2 : rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 ; + // InternalVampireLanguage.g:2964:1: rule__VLSAnnotation__Group__2 : rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 ; public final void rule__VLSAnnotation__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2937:1: ( rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 ) - // InternalVampireLanguage.g:2938:2: rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 + // InternalVampireLanguage.g:2968:1: ( rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 ) + // InternalVampireLanguage.g:2969:2: rule__VLSAnnotation__Group__2__Impl rule__VLSAnnotation__Group__3 { pushFollow(FOLLOW_29); rule__VLSAnnotation__Group__2__Impl(); @@ -9606,20 +9702,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__2__Impl" - // InternalVampireLanguage.g:2945:1: rule__VLSAnnotation__Group__2__Impl : ( ( rule__VLSAnnotation__Group_2__0 )? ) ; + // InternalVampireLanguage.g:2976:1: rule__VLSAnnotation__Group__2__Impl : ( ( rule__VLSAnnotation__Group_2__0 )? ) ; public final void rule__VLSAnnotation__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2949:1: ( ( ( rule__VLSAnnotation__Group_2__0 )? ) ) - // InternalVampireLanguage.g:2950:1: ( ( rule__VLSAnnotation__Group_2__0 )? ) + // InternalVampireLanguage.g:2980:1: ( ( ( rule__VLSAnnotation__Group_2__0 )? ) ) + // InternalVampireLanguage.g:2981:1: ( ( rule__VLSAnnotation__Group_2__0 )? ) { - // InternalVampireLanguage.g:2950:1: ( ( rule__VLSAnnotation__Group_2__0 )? ) - // InternalVampireLanguage.g:2951:2: ( rule__VLSAnnotation__Group_2__0 )? + // InternalVampireLanguage.g:2981:1: ( ( rule__VLSAnnotation__Group_2__0 )? ) + // InternalVampireLanguage.g:2982:2: ( rule__VLSAnnotation__Group_2__0 )? { before(grammarAccess.getVLSAnnotationAccess().getGroup_2()); - // InternalVampireLanguage.g:2952:2: ( rule__VLSAnnotation__Group_2__0 )? + // InternalVampireLanguage.g:2983:2: ( rule__VLSAnnotation__Group_2__0 )? int alt33=2; int LA33_0 = input.LA(1); @@ -9628,7 +9724,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt33) { case 1 : - // InternalVampireLanguage.g:2952:3: rule__VLSAnnotation__Group_2__0 + // InternalVampireLanguage.g:2983:3: rule__VLSAnnotation__Group_2__0 { pushFollow(FOLLOW_2); rule__VLSAnnotation__Group_2__0(); @@ -9664,14 +9760,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__3" - // InternalVampireLanguage.g:2960:1: rule__VLSAnnotation__Group__3 : rule__VLSAnnotation__Group__3__Impl ; + // InternalVampireLanguage.g:2991:1: rule__VLSAnnotation__Group__3 : rule__VLSAnnotation__Group__3__Impl ; public final void rule__VLSAnnotation__Group__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2964:1: ( rule__VLSAnnotation__Group__3__Impl ) - // InternalVampireLanguage.g:2965:2: rule__VLSAnnotation__Group__3__Impl + // InternalVampireLanguage.g:2995:1: ( rule__VLSAnnotation__Group__3__Impl ) + // InternalVampireLanguage.g:2996:2: rule__VLSAnnotation__Group__3__Impl { pushFollow(FOLLOW_2); rule__VLSAnnotation__Group__3__Impl(); @@ -9697,20 +9793,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group__3__Impl" - // InternalVampireLanguage.g:2971:1: rule__VLSAnnotation__Group__3__Impl : ( ( ']' )? ) ; + // InternalVampireLanguage.g:3002:1: rule__VLSAnnotation__Group__3__Impl : ( ( ']' )? ) ; public final void rule__VLSAnnotation__Group__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2975:1: ( ( ( ']' )? ) ) - // InternalVampireLanguage.g:2976:1: ( ( ']' )? ) + // InternalVampireLanguage.g:3006:1: ( ( ( ']' )? ) ) + // InternalVampireLanguage.g:3007:1: ( ( ']' )? ) { - // InternalVampireLanguage.g:2976:1: ( ( ']' )? ) - // InternalVampireLanguage.g:2977:2: ( ']' )? + // InternalVampireLanguage.g:3007:1: ( ( ']' )? ) + // InternalVampireLanguage.g:3008:2: ( ']' )? { before(grammarAccess.getVLSAnnotationAccess().getRightSquareBracketKeyword_3()); - // InternalVampireLanguage.g:2978:2: ( ']' )? + // InternalVampireLanguage.g:3009:2: ( ']' )? int alt34=2; int LA34_0 = input.LA(1); @@ -9719,7 +9815,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt34) { case 1 : - // InternalVampireLanguage.g:2978:3: ']' + // InternalVampireLanguage.g:3009:3: ']' { match(input,50,FOLLOW_2); @@ -9751,14 +9847,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__0" - // InternalVampireLanguage.g:2987:1: rule__VLSAnnotation__Group_2__0 : rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 ; + // InternalVampireLanguage.g:3018:1: rule__VLSAnnotation__Group_2__0 : rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 ; public final void rule__VLSAnnotation__Group_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:2991:1: ( rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 ) - // InternalVampireLanguage.g:2992:2: rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 + // InternalVampireLanguage.g:3022:1: ( rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 ) + // InternalVampireLanguage.g:3023:2: rule__VLSAnnotation__Group_2__0__Impl rule__VLSAnnotation__Group_2__1 { pushFollow(FOLLOW_29); rule__VLSAnnotation__Group_2__0__Impl(); @@ -9789,17 +9885,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__0__Impl" - // InternalVampireLanguage.g:2999:1: rule__VLSAnnotation__Group_2__0__Impl : ( '(' ) ; + // InternalVampireLanguage.g:3030:1: rule__VLSAnnotation__Group_2__0__Impl : ( '(' ) ; public final void rule__VLSAnnotation__Group_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3003:1: ( ( '(' ) ) - // InternalVampireLanguage.g:3004:1: ( '(' ) + // InternalVampireLanguage.g:3034:1: ( ( '(' ) ) + // InternalVampireLanguage.g:3035:1: ( '(' ) { - // InternalVampireLanguage.g:3004:1: ( '(' ) - // InternalVampireLanguage.g:3005:2: '(' + // InternalVampireLanguage.g:3035:1: ( '(' ) + // InternalVampireLanguage.g:3036:2: '(' { before(grammarAccess.getVLSAnnotationAccess().getLeftParenthesisKeyword_2_0()); match(input,55,FOLLOW_2); @@ -9826,16 +9922,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__1" - // InternalVampireLanguage.g:3014:1: rule__VLSAnnotation__Group_2__1 : rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 ; + // InternalVampireLanguage.g:3045:1: rule__VLSAnnotation__Group_2__1 : rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 ; public final void rule__VLSAnnotation__Group_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3018:1: ( rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 ) - // InternalVampireLanguage.g:3019:2: rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 + // InternalVampireLanguage.g:3049:1: ( rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 ) + // InternalVampireLanguage.g:3050:2: rule__VLSAnnotation__Group_2__1__Impl rule__VLSAnnotation__Group_2__2 { - pushFollow(FOLLOW_32); + pushFollow(FOLLOW_33); rule__VLSAnnotation__Group_2__1__Impl(); state._fsp--; @@ -9864,21 +9960,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__1__Impl" - // InternalVampireLanguage.g:3026:1: rule__VLSAnnotation__Group_2__1__Impl : ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) ; + // InternalVampireLanguage.g:3057:1: rule__VLSAnnotation__Group_2__1__Impl : ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) ; public final void rule__VLSAnnotation__Group_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3030:1: ( ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) ) - // InternalVampireLanguage.g:3031:1: ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) + // InternalVampireLanguage.g:3061:1: ( ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) ) + // InternalVampireLanguage.g:3062:1: ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) { - // InternalVampireLanguage.g:3031:1: ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) - // InternalVampireLanguage.g:3032:2: ( rule__VLSAnnotation__FollowupAssignment_2_1 ) + // InternalVampireLanguage.g:3062:1: ( ( rule__VLSAnnotation__FollowupAssignment_2_1 ) ) + // InternalVampireLanguage.g:3063:2: ( rule__VLSAnnotation__FollowupAssignment_2_1 ) { before(grammarAccess.getVLSAnnotationAccess().getFollowupAssignment_2_1()); - // InternalVampireLanguage.g:3033:2: ( rule__VLSAnnotation__FollowupAssignment_2_1 ) - // InternalVampireLanguage.g:3033:3: rule__VLSAnnotation__FollowupAssignment_2_1 + // InternalVampireLanguage.g:3064:2: ( rule__VLSAnnotation__FollowupAssignment_2_1 ) + // InternalVampireLanguage.g:3064:3: rule__VLSAnnotation__FollowupAssignment_2_1 { pushFollow(FOLLOW_2); rule__VLSAnnotation__FollowupAssignment_2_1(); @@ -9911,14 +10007,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__2" - // InternalVampireLanguage.g:3041:1: rule__VLSAnnotation__Group_2__2 : rule__VLSAnnotation__Group_2__2__Impl ; + // InternalVampireLanguage.g:3072:1: rule__VLSAnnotation__Group_2__2 : rule__VLSAnnotation__Group_2__2__Impl ; public final void rule__VLSAnnotation__Group_2__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3045:1: ( rule__VLSAnnotation__Group_2__2__Impl ) - // InternalVampireLanguage.g:3046:2: rule__VLSAnnotation__Group_2__2__Impl + // InternalVampireLanguage.g:3076:1: ( rule__VLSAnnotation__Group_2__2__Impl ) + // InternalVampireLanguage.g:3077:2: rule__VLSAnnotation__Group_2__2__Impl { pushFollow(FOLLOW_2); rule__VLSAnnotation__Group_2__2__Impl(); @@ -9944,17 +10040,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__Group_2__2__Impl" - // InternalVampireLanguage.g:3052:1: rule__VLSAnnotation__Group_2__2__Impl : ( ')' ) ; + // InternalVampireLanguage.g:3083:1: rule__VLSAnnotation__Group_2__2__Impl : ( ')' ) ; public final void rule__VLSAnnotation__Group_2__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3056:1: ( ( ')' ) ) - // InternalVampireLanguage.g:3057:1: ( ')' ) + // InternalVampireLanguage.g:3087:1: ( ( ')' ) ) + // InternalVampireLanguage.g:3088:1: ( ')' ) { - // InternalVampireLanguage.g:3057:1: ( ')' ) - // InternalVampireLanguage.g:3058:2: ')' + // InternalVampireLanguage.g:3088:1: ( ')' ) + // InternalVampireLanguage.g:3089:2: ')' { before(grammarAccess.getVLSAnnotationAccess().getRightParenthesisKeyword_2_2()); match(input,57,FOLLOW_2); @@ -9981,14 +10077,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group__0" - // InternalVampireLanguage.g:3068:1: rule__VLSAnnotationTerms__Group__0 : rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 ; + // InternalVampireLanguage.g:3099:1: rule__VLSAnnotationTerms__Group__0 : rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 ; public final void rule__VLSAnnotationTerms__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3072:1: ( rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 ) - // InternalVampireLanguage.g:3073:2: rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 + // InternalVampireLanguage.g:3103:1: ( rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 ) + // InternalVampireLanguage.g:3104:2: rule__VLSAnnotationTerms__Group__0__Impl rule__VLSAnnotationTerms__Group__1 { pushFollow(FOLLOW_24); rule__VLSAnnotationTerms__Group__0__Impl(); @@ -10019,21 +10115,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group__0__Impl" - // InternalVampireLanguage.g:3080:1: rule__VLSAnnotationTerms__Group__0__Impl : ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) ; + // InternalVampireLanguage.g:3111:1: rule__VLSAnnotationTerms__Group__0__Impl : ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) ; public final void rule__VLSAnnotationTerms__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3084:1: ( ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) ) - // InternalVampireLanguage.g:3085:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) + // InternalVampireLanguage.g:3115:1: ( ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) ) + // InternalVampireLanguage.g:3116:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) { - // InternalVampireLanguage.g:3085:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) - // InternalVampireLanguage.g:3086:2: ( rule__VLSAnnotationTerms__TermsAssignment_0 ) + // InternalVampireLanguage.g:3116:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_0 ) ) + // InternalVampireLanguage.g:3117:2: ( rule__VLSAnnotationTerms__TermsAssignment_0 ) { before(grammarAccess.getVLSAnnotationTermsAccess().getTermsAssignment_0()); - // InternalVampireLanguage.g:3087:2: ( rule__VLSAnnotationTerms__TermsAssignment_0 ) - // InternalVampireLanguage.g:3087:3: rule__VLSAnnotationTerms__TermsAssignment_0 + // InternalVampireLanguage.g:3118:2: ( rule__VLSAnnotationTerms__TermsAssignment_0 ) + // InternalVampireLanguage.g:3118:3: rule__VLSAnnotationTerms__TermsAssignment_0 { pushFollow(FOLLOW_2); rule__VLSAnnotationTerms__TermsAssignment_0(); @@ -10066,14 +10162,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group__1" - // InternalVampireLanguage.g:3095:1: rule__VLSAnnotationTerms__Group__1 : rule__VLSAnnotationTerms__Group__1__Impl ; + // InternalVampireLanguage.g:3126:1: rule__VLSAnnotationTerms__Group__1 : rule__VLSAnnotationTerms__Group__1__Impl ; public final void rule__VLSAnnotationTerms__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3099:1: ( rule__VLSAnnotationTerms__Group__1__Impl ) - // InternalVampireLanguage.g:3100:2: rule__VLSAnnotationTerms__Group__1__Impl + // InternalVampireLanguage.g:3130:1: ( rule__VLSAnnotationTerms__Group__1__Impl ) + // InternalVampireLanguage.g:3131:2: rule__VLSAnnotationTerms__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSAnnotationTerms__Group__1__Impl(); @@ -10099,20 +10195,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group__1__Impl" - // InternalVampireLanguage.g:3106:1: rule__VLSAnnotationTerms__Group__1__Impl : ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) ; + // InternalVampireLanguage.g:3137:1: rule__VLSAnnotationTerms__Group__1__Impl : ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) ; public final void rule__VLSAnnotationTerms__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3110:1: ( ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) ) - // InternalVampireLanguage.g:3111:1: ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) + // InternalVampireLanguage.g:3141:1: ( ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) ) + // InternalVampireLanguage.g:3142:1: ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) { - // InternalVampireLanguage.g:3111:1: ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) - // InternalVampireLanguage.g:3112:2: ( rule__VLSAnnotationTerms__Group_1__0 )* + // InternalVampireLanguage.g:3142:1: ( ( rule__VLSAnnotationTerms__Group_1__0 )* ) + // InternalVampireLanguage.g:3143:2: ( rule__VLSAnnotationTerms__Group_1__0 )* { before(grammarAccess.getVLSAnnotationTermsAccess().getGroup_1()); - // InternalVampireLanguage.g:3113:2: ( rule__VLSAnnotationTerms__Group_1__0 )* + // InternalVampireLanguage.g:3144:2: ( rule__VLSAnnotationTerms__Group_1__0 )* loop35: do { int alt35=2; @@ -10125,9 +10221,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt35) { case 1 : - // InternalVampireLanguage.g:3113:3: rule__VLSAnnotationTerms__Group_1__0 + // InternalVampireLanguage.g:3144:3: rule__VLSAnnotationTerms__Group_1__0 { - pushFollow(FOLLOW_33); + pushFollow(FOLLOW_34); rule__VLSAnnotationTerms__Group_1__0(); state._fsp--; @@ -10164,14 +10260,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group_1__0" - // InternalVampireLanguage.g:3122:1: rule__VLSAnnotationTerms__Group_1__0 : rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 ; + // InternalVampireLanguage.g:3153:1: rule__VLSAnnotationTerms__Group_1__0 : rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 ; public final void rule__VLSAnnotationTerms__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3126:1: ( rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 ) - // InternalVampireLanguage.g:3127:2: rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 + // InternalVampireLanguage.g:3157:1: ( rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 ) + // InternalVampireLanguage.g:3158:2: rule__VLSAnnotationTerms__Group_1__0__Impl rule__VLSAnnotationTerms__Group_1__1 { pushFollow(FOLLOW_29); rule__VLSAnnotationTerms__Group_1__0__Impl(); @@ -10202,17 +10298,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group_1__0__Impl" - // InternalVampireLanguage.g:3134:1: rule__VLSAnnotationTerms__Group_1__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:3165:1: rule__VLSAnnotationTerms__Group_1__0__Impl : ( ',' ) ; public final void rule__VLSAnnotationTerms__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3138:1: ( ( ',' ) ) - // InternalVampireLanguage.g:3139:1: ( ',' ) + // InternalVampireLanguage.g:3169:1: ( ( ',' ) ) + // InternalVampireLanguage.g:3170:1: ( ',' ) { - // InternalVampireLanguage.g:3139:1: ( ',' ) - // InternalVampireLanguage.g:3140:2: ',' + // InternalVampireLanguage.g:3170:1: ( ',' ) + // InternalVampireLanguage.g:3171:2: ',' { before(grammarAccess.getVLSAnnotationTermsAccess().getCommaKeyword_1_0()); match(input,56,FOLLOW_2); @@ -10239,14 +10335,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group_1__1" - // InternalVampireLanguage.g:3149:1: rule__VLSAnnotationTerms__Group_1__1 : rule__VLSAnnotationTerms__Group_1__1__Impl ; + // InternalVampireLanguage.g:3180:1: rule__VLSAnnotationTerms__Group_1__1 : rule__VLSAnnotationTerms__Group_1__1__Impl ; public final void rule__VLSAnnotationTerms__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3153:1: ( rule__VLSAnnotationTerms__Group_1__1__Impl ) - // InternalVampireLanguage.g:3154:2: rule__VLSAnnotationTerms__Group_1__1__Impl + // InternalVampireLanguage.g:3184:1: ( rule__VLSAnnotationTerms__Group_1__1__Impl ) + // InternalVampireLanguage.g:3185:2: rule__VLSAnnotationTerms__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSAnnotationTerms__Group_1__1__Impl(); @@ -10272,21 +10368,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__Group_1__1__Impl" - // InternalVampireLanguage.g:3160:1: rule__VLSAnnotationTerms__Group_1__1__Impl : ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:3191:1: rule__VLSAnnotationTerms__Group_1__1__Impl : ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) ; public final void rule__VLSAnnotationTerms__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3164:1: ( ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:3165:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) + // InternalVampireLanguage.g:3195:1: ( ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:3196:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) { - // InternalVampireLanguage.g:3165:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) - // InternalVampireLanguage.g:3166:2: ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) + // InternalVampireLanguage.g:3196:1: ( ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) ) + // InternalVampireLanguage.g:3197:2: ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) { before(grammarAccess.getVLSAnnotationTermsAccess().getTermsAssignment_1_1()); - // InternalVampireLanguage.g:3167:2: ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) - // InternalVampireLanguage.g:3167:3: rule__VLSAnnotationTerms__TermsAssignment_1_1 + // InternalVampireLanguage.g:3198:2: ( rule__VLSAnnotationTerms__TermsAssignment_1_1 ) + // InternalVampireLanguage.g:3198:3: rule__VLSAnnotationTerms__TermsAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSAnnotationTerms__TermsAssignment_1_1(); @@ -10319,16 +10415,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__0" - // InternalVampireLanguage.g:3176:1: rule__VLSOtherDeclaration__Group__0 : rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 ; + // InternalVampireLanguage.g:3207:1: rule__VLSOtherDeclaration__Group__0 : rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 ; public final void rule__VLSOtherDeclaration__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3180:1: ( rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 ) - // InternalVampireLanguage.g:3181:2: rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 + // InternalVampireLanguage.g:3211:1: ( rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 ) + // InternalVampireLanguage.g:3212:2: rule__VLSOtherDeclaration__Group__0__Impl rule__VLSOtherDeclaration__Group__1 { - pushFollow(FOLLOW_34); + pushFollow(FOLLOW_35); rule__VLSOtherDeclaration__Group__0__Impl(); state._fsp--; @@ -10357,21 +10453,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__0__Impl" - // InternalVampireLanguage.g:3188:1: rule__VLSOtherDeclaration__Group__0__Impl : ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) ; + // InternalVampireLanguage.g:3219:1: rule__VLSOtherDeclaration__Group__0__Impl : ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) ; public final void rule__VLSOtherDeclaration__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3192:1: ( ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) ) - // InternalVampireLanguage.g:3193:1: ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) + // InternalVampireLanguage.g:3223:1: ( ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) ) + // InternalVampireLanguage.g:3224:1: ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) { - // InternalVampireLanguage.g:3193:1: ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) - // InternalVampireLanguage.g:3194:2: ( rule__VLSOtherDeclaration__NameAssignment_0 ) + // InternalVampireLanguage.g:3224:1: ( ( rule__VLSOtherDeclaration__NameAssignment_0 ) ) + // InternalVampireLanguage.g:3225:2: ( rule__VLSOtherDeclaration__NameAssignment_0 ) { before(grammarAccess.getVLSOtherDeclarationAccess().getNameAssignment_0()); - // InternalVampireLanguage.g:3195:2: ( rule__VLSOtherDeclaration__NameAssignment_0 ) - // InternalVampireLanguage.g:3195:3: rule__VLSOtherDeclaration__NameAssignment_0 + // InternalVampireLanguage.g:3226:2: ( rule__VLSOtherDeclaration__NameAssignment_0 ) + // InternalVampireLanguage.g:3226:3: rule__VLSOtherDeclaration__NameAssignment_0 { pushFollow(FOLLOW_2); rule__VLSOtherDeclaration__NameAssignment_0(); @@ -10404,16 +10500,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__1" - // InternalVampireLanguage.g:3203:1: rule__VLSOtherDeclaration__Group__1 : rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 ; + // InternalVampireLanguage.g:3234:1: rule__VLSOtherDeclaration__Group__1 : rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 ; public final void rule__VLSOtherDeclaration__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3207:1: ( rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 ) - // InternalVampireLanguage.g:3208:2: rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 + // InternalVampireLanguage.g:3238:1: ( rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 ) + // InternalVampireLanguage.g:3239:2: rule__VLSOtherDeclaration__Group__1__Impl rule__VLSOtherDeclaration__Group__2 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSOtherDeclaration__Group__1__Impl(); state._fsp--; @@ -10442,17 +10538,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__1__Impl" - // InternalVampireLanguage.g:3215:1: rule__VLSOtherDeclaration__Group__1__Impl : ( ':' ) ; + // InternalVampireLanguage.g:3246:1: rule__VLSOtherDeclaration__Group__1__Impl : ( ':' ) ; public final void rule__VLSOtherDeclaration__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3219:1: ( ( ':' ) ) - // InternalVampireLanguage.g:3220:1: ( ':' ) + // InternalVampireLanguage.g:3250:1: ( ( ':' ) ) + // InternalVampireLanguage.g:3251:1: ( ':' ) { - // InternalVampireLanguage.g:3220:1: ( ':' ) - // InternalVampireLanguage.g:3221:2: ':' + // InternalVampireLanguage.g:3251:1: ( ':' ) + // InternalVampireLanguage.g:3252:2: ':' { before(grammarAccess.getVLSOtherDeclarationAccess().getColonKeyword_1()); match(input,61,FOLLOW_2); @@ -10479,14 +10575,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__2" - // InternalVampireLanguage.g:3230:1: rule__VLSOtherDeclaration__Group__2 : rule__VLSOtherDeclaration__Group__2__Impl ; + // InternalVampireLanguage.g:3261:1: rule__VLSOtherDeclaration__Group__2 : rule__VLSOtherDeclaration__Group__2__Impl ; public final void rule__VLSOtherDeclaration__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3234:1: ( rule__VLSOtherDeclaration__Group__2__Impl ) - // InternalVampireLanguage.g:3235:2: rule__VLSOtherDeclaration__Group__2__Impl + // InternalVampireLanguage.g:3265:1: ( rule__VLSOtherDeclaration__Group__2__Impl ) + // InternalVampireLanguage.g:3266:2: rule__VLSOtherDeclaration__Group__2__Impl { pushFollow(FOLLOW_2); rule__VLSOtherDeclaration__Group__2__Impl(); @@ -10512,21 +10608,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__Group__2__Impl" - // InternalVampireLanguage.g:3241:1: rule__VLSOtherDeclaration__Group__2__Impl : ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) ; + // InternalVampireLanguage.g:3272:1: rule__VLSOtherDeclaration__Group__2__Impl : ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) ; public final void rule__VLSOtherDeclaration__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3245:1: ( ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) ) - // InternalVampireLanguage.g:3246:1: ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) + // InternalVampireLanguage.g:3276:1: ( ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) ) + // InternalVampireLanguage.g:3277:1: ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) { - // InternalVampireLanguage.g:3246:1: ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) - // InternalVampireLanguage.g:3247:2: ( rule__VLSOtherDeclaration__TypeAssignment_2 ) + // InternalVampireLanguage.g:3277:1: ( ( rule__VLSOtherDeclaration__TypeAssignment_2 ) ) + // InternalVampireLanguage.g:3278:2: ( rule__VLSOtherDeclaration__TypeAssignment_2 ) { before(grammarAccess.getVLSOtherDeclarationAccess().getTypeAssignment_2()); - // InternalVampireLanguage.g:3248:2: ( rule__VLSOtherDeclaration__TypeAssignment_2 ) - // InternalVampireLanguage.g:3248:3: rule__VLSOtherDeclaration__TypeAssignment_2 + // InternalVampireLanguage.g:3279:2: ( rule__VLSOtherDeclaration__TypeAssignment_2 ) + // InternalVampireLanguage.g:3279:3: rule__VLSOtherDeclaration__TypeAssignment_2 { pushFollow(FOLLOW_2); rule__VLSOtherDeclaration__TypeAssignment_2(); @@ -10559,16 +10655,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__0" - // InternalVampireLanguage.g:3257:1: rule__VLSVariableDeclaration__Group__0 : rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 ; + // InternalVampireLanguage.g:3288:1: rule__VLSVariableDeclaration__Group__0 : rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 ; public final void rule__VLSVariableDeclaration__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3261:1: ( rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 ) - // InternalVampireLanguage.g:3262:2: rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 + // InternalVampireLanguage.g:3292:1: ( rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 ) + // InternalVampireLanguage.g:3293:2: rule__VLSVariableDeclaration__Group__0__Impl rule__VLSVariableDeclaration__Group__1 { - pushFollow(FOLLOW_34); + pushFollow(FOLLOW_35); rule__VLSVariableDeclaration__Group__0__Impl(); state._fsp--; @@ -10597,21 +10693,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__0__Impl" - // InternalVampireLanguage.g:3269:1: rule__VLSVariableDeclaration__Group__0__Impl : ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) ; + // InternalVampireLanguage.g:3300:1: rule__VLSVariableDeclaration__Group__0__Impl : ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) ; public final void rule__VLSVariableDeclaration__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3273:1: ( ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) ) - // InternalVampireLanguage.g:3274:1: ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) + // InternalVampireLanguage.g:3304:1: ( ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) ) + // InternalVampireLanguage.g:3305:1: ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) { - // InternalVampireLanguage.g:3274:1: ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) - // InternalVampireLanguage.g:3275:2: ( rule__VLSVariableDeclaration__NameAssignment_0 ) + // InternalVampireLanguage.g:3305:1: ( ( rule__VLSVariableDeclaration__NameAssignment_0 ) ) + // InternalVampireLanguage.g:3306:2: ( rule__VLSVariableDeclaration__NameAssignment_0 ) { before(grammarAccess.getVLSVariableDeclarationAccess().getNameAssignment_0()); - // InternalVampireLanguage.g:3276:2: ( rule__VLSVariableDeclaration__NameAssignment_0 ) - // InternalVampireLanguage.g:3276:3: rule__VLSVariableDeclaration__NameAssignment_0 + // InternalVampireLanguage.g:3307:2: ( rule__VLSVariableDeclaration__NameAssignment_0 ) + // InternalVampireLanguage.g:3307:3: rule__VLSVariableDeclaration__NameAssignment_0 { pushFollow(FOLLOW_2); rule__VLSVariableDeclaration__NameAssignment_0(); @@ -10644,16 +10740,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__1" - // InternalVampireLanguage.g:3284:1: rule__VLSVariableDeclaration__Group__1 : rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 ; + // InternalVampireLanguage.g:3315:1: rule__VLSVariableDeclaration__Group__1 : rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 ; public final void rule__VLSVariableDeclaration__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3288:1: ( rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 ) - // InternalVampireLanguage.g:3289:2: rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 + // InternalVampireLanguage.g:3319:1: ( rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 ) + // InternalVampireLanguage.g:3320:2: rule__VLSVariableDeclaration__Group__1__Impl rule__VLSVariableDeclaration__Group__2 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSVariableDeclaration__Group__1__Impl(); state._fsp--; @@ -10682,17 +10778,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__1__Impl" - // InternalVampireLanguage.g:3296:1: rule__VLSVariableDeclaration__Group__1__Impl : ( ':' ) ; + // InternalVampireLanguage.g:3327:1: rule__VLSVariableDeclaration__Group__1__Impl : ( ':' ) ; public final void rule__VLSVariableDeclaration__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3300:1: ( ( ':' ) ) - // InternalVampireLanguage.g:3301:1: ( ':' ) + // InternalVampireLanguage.g:3331:1: ( ( ':' ) ) + // InternalVampireLanguage.g:3332:1: ( ':' ) { - // InternalVampireLanguage.g:3301:1: ( ':' ) - // InternalVampireLanguage.g:3302:2: ':' + // InternalVampireLanguage.g:3332:1: ( ':' ) + // InternalVampireLanguage.g:3333:2: ':' { before(grammarAccess.getVLSVariableDeclarationAccess().getColonKeyword_1()); match(input,61,FOLLOW_2); @@ -10719,14 +10815,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__2" - // InternalVampireLanguage.g:3311:1: rule__VLSVariableDeclaration__Group__2 : rule__VLSVariableDeclaration__Group__2__Impl ; + // InternalVampireLanguage.g:3342:1: rule__VLSVariableDeclaration__Group__2 : rule__VLSVariableDeclaration__Group__2__Impl ; public final void rule__VLSVariableDeclaration__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3315:1: ( rule__VLSVariableDeclaration__Group__2__Impl ) - // InternalVampireLanguage.g:3316:2: rule__VLSVariableDeclaration__Group__2__Impl + // InternalVampireLanguage.g:3346:1: ( rule__VLSVariableDeclaration__Group__2__Impl ) + // InternalVampireLanguage.g:3347:2: rule__VLSVariableDeclaration__Group__2__Impl { pushFollow(FOLLOW_2); rule__VLSVariableDeclaration__Group__2__Impl(); @@ -10752,21 +10848,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__Group__2__Impl" - // InternalVampireLanguage.g:3322:1: rule__VLSVariableDeclaration__Group__2__Impl : ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) ; + // InternalVampireLanguage.g:3353:1: rule__VLSVariableDeclaration__Group__2__Impl : ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) ; public final void rule__VLSVariableDeclaration__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3326:1: ( ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) ) - // InternalVampireLanguage.g:3327:1: ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) + // InternalVampireLanguage.g:3357:1: ( ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) ) + // InternalVampireLanguage.g:3358:1: ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) { - // InternalVampireLanguage.g:3327:1: ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) - // InternalVampireLanguage.g:3328:2: ( rule__VLSVariableDeclaration__TypeAssignment_2 ) + // InternalVampireLanguage.g:3358:1: ( ( rule__VLSVariableDeclaration__TypeAssignment_2 ) ) + // InternalVampireLanguage.g:3359:2: ( rule__VLSVariableDeclaration__TypeAssignment_2 ) { before(grammarAccess.getVLSVariableDeclarationAccess().getTypeAssignment_2()); - // InternalVampireLanguage.g:3329:2: ( rule__VLSVariableDeclaration__TypeAssignment_2 ) - // InternalVampireLanguage.g:3329:3: rule__VLSVariableDeclaration__TypeAssignment_2 + // InternalVampireLanguage.g:3360:2: ( rule__VLSVariableDeclaration__TypeAssignment_2 ) + // InternalVampireLanguage.g:3360:3: rule__VLSVariableDeclaration__TypeAssignment_2 { pushFollow(FOLLOW_2); rule__VLSVariableDeclaration__TypeAssignment_2(); @@ -10799,16 +10895,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group__0" - // InternalVampireLanguage.g:3338:1: rule__VLSTypeDef__Group__0 : rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 ; + // InternalVampireLanguage.g:3369:1: rule__VLSTypeDef__Group__0 : rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 ; public final void rule__VLSTypeDef__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3342:1: ( rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 ) - // InternalVampireLanguage.g:3343:2: rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 + // InternalVampireLanguage.g:3373:1: ( rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 ) + // InternalVampireLanguage.g:3374:2: rule__VLSTypeDef__Group__0__Impl rule__VLSTypeDef__Group__1 { - pushFollow(FOLLOW_36); + pushFollow(FOLLOW_37); rule__VLSTypeDef__Group__0__Impl(); state._fsp--; @@ -10837,21 +10933,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group__0__Impl" - // InternalVampireLanguage.g:3350:1: rule__VLSTypeDef__Group__0__Impl : ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) ; + // InternalVampireLanguage.g:3381:1: rule__VLSTypeDef__Group__0__Impl : ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) ; public final void rule__VLSTypeDef__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3354:1: ( ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) ) - // InternalVampireLanguage.g:3355:1: ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) + // InternalVampireLanguage.g:3385:1: ( ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) ) + // InternalVampireLanguage.g:3386:1: ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) { - // InternalVampireLanguage.g:3355:1: ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) - // InternalVampireLanguage.g:3356:2: ( rule__VLSTypeDef__TypeSigAssignment_0 ) + // InternalVampireLanguage.g:3386:1: ( ( rule__VLSTypeDef__TypeSigAssignment_0 ) ) + // InternalVampireLanguage.g:3387:2: ( rule__VLSTypeDef__TypeSigAssignment_0 ) { before(grammarAccess.getVLSTypeDefAccess().getTypeSigAssignment_0()); - // InternalVampireLanguage.g:3357:2: ( rule__VLSTypeDef__TypeSigAssignment_0 ) - // InternalVampireLanguage.g:3357:3: rule__VLSTypeDef__TypeSigAssignment_0 + // InternalVampireLanguage.g:3388:2: ( rule__VLSTypeDef__TypeSigAssignment_0 ) + // InternalVampireLanguage.g:3388:3: rule__VLSTypeDef__TypeSigAssignment_0 { pushFollow(FOLLOW_2); rule__VLSTypeDef__TypeSigAssignment_0(); @@ -10884,14 +10980,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group__1" - // InternalVampireLanguage.g:3365:1: rule__VLSTypeDef__Group__1 : rule__VLSTypeDef__Group__1__Impl ; + // InternalVampireLanguage.g:3396:1: rule__VLSTypeDef__Group__1 : rule__VLSTypeDef__Group__1__Impl ; public final void rule__VLSTypeDef__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3369:1: ( rule__VLSTypeDef__Group__1__Impl ) - // InternalVampireLanguage.g:3370:2: rule__VLSTypeDef__Group__1__Impl + // InternalVampireLanguage.g:3400:1: ( rule__VLSTypeDef__Group__1__Impl ) + // InternalVampireLanguage.g:3401:2: rule__VLSTypeDef__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSTypeDef__Group__1__Impl(); @@ -10917,20 +11013,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group__1__Impl" - // InternalVampireLanguage.g:3376:1: rule__VLSTypeDef__Group__1__Impl : ( ( rule__VLSTypeDef__Group_1__0 )? ) ; + // InternalVampireLanguage.g:3407:1: rule__VLSTypeDef__Group__1__Impl : ( ( rule__VLSTypeDef__Group_1__0 )? ) ; public final void rule__VLSTypeDef__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3380:1: ( ( ( rule__VLSTypeDef__Group_1__0 )? ) ) - // InternalVampireLanguage.g:3381:1: ( ( rule__VLSTypeDef__Group_1__0 )? ) + // InternalVampireLanguage.g:3411:1: ( ( ( rule__VLSTypeDef__Group_1__0 )? ) ) + // InternalVampireLanguage.g:3412:1: ( ( rule__VLSTypeDef__Group_1__0 )? ) { - // InternalVampireLanguage.g:3381:1: ( ( rule__VLSTypeDef__Group_1__0 )? ) - // InternalVampireLanguage.g:3382:2: ( rule__VLSTypeDef__Group_1__0 )? + // InternalVampireLanguage.g:3412:1: ( ( rule__VLSTypeDef__Group_1__0 )? ) + // InternalVampireLanguage.g:3413:2: ( rule__VLSTypeDef__Group_1__0 )? { before(grammarAccess.getVLSTypeDefAccess().getGroup_1()); - // InternalVampireLanguage.g:3383:2: ( rule__VLSTypeDef__Group_1__0 )? + // InternalVampireLanguage.g:3414:2: ( rule__VLSTypeDef__Group_1__0 )? int alt36=2; int LA36_0 = input.LA(1); @@ -10939,7 +11035,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt36) { case 1 : - // InternalVampireLanguage.g:3383:3: rule__VLSTypeDef__Group_1__0 + // InternalVampireLanguage.g:3414:3: rule__VLSTypeDef__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSTypeDef__Group_1__0(); @@ -10975,16 +11071,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group_1__0" - // InternalVampireLanguage.g:3392:1: rule__VLSTypeDef__Group_1__0 : rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 ; + // InternalVampireLanguage.g:3423:1: rule__VLSTypeDef__Group_1__0 : rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 ; public final void rule__VLSTypeDef__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3396:1: ( rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 ) - // InternalVampireLanguage.g:3397:2: rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 + // InternalVampireLanguage.g:3427:1: ( rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 ) + // InternalVampireLanguage.g:3428:2: rule__VLSTypeDef__Group_1__0__Impl rule__VLSTypeDef__Group_1__1 { - pushFollow(FOLLOW_37); + pushFollow(FOLLOW_38); rule__VLSTypeDef__Group_1__0__Impl(); state._fsp--; @@ -11013,17 +11109,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group_1__0__Impl" - // InternalVampireLanguage.g:3404:1: rule__VLSTypeDef__Group_1__0__Impl : ( '>' ) ; + // InternalVampireLanguage.g:3435:1: rule__VLSTypeDef__Group_1__0__Impl : ( '>' ) ; public final void rule__VLSTypeDef__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3408:1: ( ( '>' ) ) - // InternalVampireLanguage.g:3409:1: ( '>' ) + // InternalVampireLanguage.g:3439:1: ( ( '>' ) ) + // InternalVampireLanguage.g:3440:1: ( '>' ) { - // InternalVampireLanguage.g:3409:1: ( '>' ) - // InternalVampireLanguage.g:3410:2: '>' + // InternalVampireLanguage.g:3440:1: ( '>' ) + // InternalVampireLanguage.g:3441:2: '>' { before(grammarAccess.getVLSTypeDefAccess().getGreaterThanSignKeyword_1_0()); match(input,62,FOLLOW_2); @@ -11050,14 +11146,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group_1__1" - // InternalVampireLanguage.g:3419:1: rule__VLSTypeDef__Group_1__1 : rule__VLSTypeDef__Group_1__1__Impl ; + // InternalVampireLanguage.g:3450:1: rule__VLSTypeDef__Group_1__1 : rule__VLSTypeDef__Group_1__1__Impl ; public final void rule__VLSTypeDef__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3423:1: ( rule__VLSTypeDef__Group_1__1__Impl ) - // InternalVampireLanguage.g:3424:2: rule__VLSTypeDef__Group_1__1__Impl + // InternalVampireLanguage.g:3454:1: ( rule__VLSTypeDef__Group_1__1__Impl ) + // InternalVampireLanguage.g:3455:2: rule__VLSTypeDef__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSTypeDef__Group_1__1__Impl(); @@ -11083,21 +11179,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__Group_1__1__Impl" - // InternalVampireLanguage.g:3430:1: rule__VLSTypeDef__Group_1__1__Impl : ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:3461:1: rule__VLSTypeDef__Group_1__1__Impl : ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) ; public final void rule__VLSTypeDef__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3434:1: ( ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:3435:1: ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) + // InternalVampireLanguage.g:3465:1: ( ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:3466:1: ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) { - // InternalVampireLanguage.g:3435:1: ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) - // InternalVampireLanguage.g:3436:2: ( rule__VLSTypeDef__MapsToAssignment_1_1 ) + // InternalVampireLanguage.g:3466:1: ( ( rule__VLSTypeDef__MapsToAssignment_1_1 ) ) + // InternalVampireLanguage.g:3467:2: ( rule__VLSTypeDef__MapsToAssignment_1_1 ) { before(grammarAccess.getVLSTypeDefAccess().getMapsToAssignment_1_1()); - // InternalVampireLanguage.g:3437:2: ( rule__VLSTypeDef__MapsToAssignment_1_1 ) - // InternalVampireLanguage.g:3437:3: rule__VLSTypeDef__MapsToAssignment_1_1 + // InternalVampireLanguage.g:3468:2: ( rule__VLSTypeDef__MapsToAssignment_1_1 ) + // InternalVampireLanguage.g:3468:3: rule__VLSTypeDef__MapsToAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSTypeDef__MapsToAssignment_1_1(); @@ -11130,16 +11226,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group__0" - // InternalVampireLanguage.g:3446:1: rule__VLSUnitaryTerm__Group__0 : rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 ; + // InternalVampireLanguage.g:3477:1: rule__VLSUnitaryTerm__Group__0 : rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 ; public final void rule__VLSUnitaryTerm__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3450:1: ( rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 ) - // InternalVampireLanguage.g:3451:2: rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 + // InternalVampireLanguage.g:3481:1: ( rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 ) + // InternalVampireLanguage.g:3482:2: rule__VLSUnitaryTerm__Group__0__Impl rule__VLSUnitaryTerm__Group__1 { - pushFollow(FOLLOW_38); + pushFollow(FOLLOW_39); rule__VLSUnitaryTerm__Group__0__Impl(); state._fsp--; @@ -11168,21 +11264,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group__0__Impl" - // InternalVampireLanguage.g:3458:1: rule__VLSUnitaryTerm__Group__0__Impl : ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) ; + // InternalVampireLanguage.g:3489:1: rule__VLSUnitaryTerm__Group__0__Impl : ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) ; public final void rule__VLSUnitaryTerm__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3462:1: ( ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) ) - // InternalVampireLanguage.g:3463:1: ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) + // InternalVampireLanguage.g:3493:1: ( ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) ) + // InternalVampireLanguage.g:3494:1: ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) { - // InternalVampireLanguage.g:3463:1: ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) - // InternalVampireLanguage.g:3464:2: ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) + // InternalVampireLanguage.g:3494:1: ( ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) ) + // InternalVampireLanguage.g:3495:2: ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) { before(grammarAccess.getVLSUnitaryTermAccess().getInitTypeAssignment_0()); - // InternalVampireLanguage.g:3465:2: ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) - // InternalVampireLanguage.g:3465:3: rule__VLSUnitaryTerm__InitTypeAssignment_0 + // InternalVampireLanguage.g:3496:2: ( rule__VLSUnitaryTerm__InitTypeAssignment_0 ) + // InternalVampireLanguage.g:3496:3: rule__VLSUnitaryTerm__InitTypeAssignment_0 { pushFollow(FOLLOW_2); rule__VLSUnitaryTerm__InitTypeAssignment_0(); @@ -11215,14 +11311,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group__1" - // InternalVampireLanguage.g:3473:1: rule__VLSUnitaryTerm__Group__1 : rule__VLSUnitaryTerm__Group__1__Impl ; + // InternalVampireLanguage.g:3504:1: rule__VLSUnitaryTerm__Group__1 : rule__VLSUnitaryTerm__Group__1__Impl ; public final void rule__VLSUnitaryTerm__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3477:1: ( rule__VLSUnitaryTerm__Group__1__Impl ) - // InternalVampireLanguage.g:3478:2: rule__VLSUnitaryTerm__Group__1__Impl + // InternalVampireLanguage.g:3508:1: ( rule__VLSUnitaryTerm__Group__1__Impl ) + // InternalVampireLanguage.g:3509:2: rule__VLSUnitaryTerm__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnitaryTerm__Group__1__Impl(); @@ -11248,20 +11344,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group__1__Impl" - // InternalVampireLanguage.g:3484:1: rule__VLSUnitaryTerm__Group__1__Impl : ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) ; + // InternalVampireLanguage.g:3515:1: rule__VLSUnitaryTerm__Group__1__Impl : ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) ; public final void rule__VLSUnitaryTerm__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3488:1: ( ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) ) - // InternalVampireLanguage.g:3489:1: ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) + // InternalVampireLanguage.g:3519:1: ( ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) ) + // InternalVampireLanguage.g:3520:1: ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) { - // InternalVampireLanguage.g:3489:1: ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) - // InternalVampireLanguage.g:3490:2: ( rule__VLSUnitaryTerm__Group_1__0 )* + // InternalVampireLanguage.g:3520:1: ( ( rule__VLSUnitaryTerm__Group_1__0 )* ) + // InternalVampireLanguage.g:3521:2: ( rule__VLSUnitaryTerm__Group_1__0 )* { before(grammarAccess.getVLSUnitaryTermAccess().getGroup_1()); - // InternalVampireLanguage.g:3491:2: ( rule__VLSUnitaryTerm__Group_1__0 )* + // InternalVampireLanguage.g:3522:2: ( rule__VLSUnitaryTerm__Group_1__0 )* loop37: do { int alt37=2; @@ -11274,9 +11370,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt37) { case 1 : - // InternalVampireLanguage.g:3491:3: rule__VLSUnitaryTerm__Group_1__0 + // InternalVampireLanguage.g:3522:3: rule__VLSUnitaryTerm__Group_1__0 { - pushFollow(FOLLOW_39); + pushFollow(FOLLOW_40); rule__VLSUnitaryTerm__Group_1__0(); state._fsp--; @@ -11313,16 +11409,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group_1__0" - // InternalVampireLanguage.g:3500:1: rule__VLSUnitaryTerm__Group_1__0 : rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 ; + // InternalVampireLanguage.g:3531:1: rule__VLSUnitaryTerm__Group_1__0 : rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 ; public final void rule__VLSUnitaryTerm__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3504:1: ( rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 ) - // InternalVampireLanguage.g:3505:2: rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 + // InternalVampireLanguage.g:3535:1: ( rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 ) + // InternalVampireLanguage.g:3536:2: rule__VLSUnitaryTerm__Group_1__0__Impl rule__VLSUnitaryTerm__Group_1__1 { - pushFollow(FOLLOW_37); + pushFollow(FOLLOW_38); rule__VLSUnitaryTerm__Group_1__0__Impl(); state._fsp--; @@ -11351,17 +11447,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group_1__0__Impl" - // InternalVampireLanguage.g:3512:1: rule__VLSUnitaryTerm__Group_1__0__Impl : ( '*' ) ; + // InternalVampireLanguage.g:3543:1: rule__VLSUnitaryTerm__Group_1__0__Impl : ( '*' ) ; public final void rule__VLSUnitaryTerm__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3516:1: ( ( '*' ) ) - // InternalVampireLanguage.g:3517:1: ( '*' ) + // InternalVampireLanguage.g:3547:1: ( ( '*' ) ) + // InternalVampireLanguage.g:3548:1: ( '*' ) { - // InternalVampireLanguage.g:3517:1: ( '*' ) - // InternalVampireLanguage.g:3518:2: '*' + // InternalVampireLanguage.g:3548:1: ( '*' ) + // InternalVampireLanguage.g:3549:2: '*' { before(grammarAccess.getVLSUnitaryTermAccess().getAsteriskKeyword_1_0()); match(input,63,FOLLOW_2); @@ -11388,14 +11484,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group_1__1" - // InternalVampireLanguage.g:3527:1: rule__VLSUnitaryTerm__Group_1__1 : rule__VLSUnitaryTerm__Group_1__1__Impl ; + // InternalVampireLanguage.g:3558:1: rule__VLSUnitaryTerm__Group_1__1 : rule__VLSUnitaryTerm__Group_1__1__Impl ; public final void rule__VLSUnitaryTerm__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3531:1: ( rule__VLSUnitaryTerm__Group_1__1__Impl ) - // InternalVampireLanguage.g:3532:2: rule__VLSUnitaryTerm__Group_1__1__Impl + // InternalVampireLanguage.g:3562:1: ( rule__VLSUnitaryTerm__Group_1__1__Impl ) + // InternalVampireLanguage.g:3563:2: rule__VLSUnitaryTerm__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnitaryTerm__Group_1__1__Impl(); @@ -11421,21 +11517,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__Group_1__1__Impl" - // InternalVampireLanguage.g:3538:1: rule__VLSUnitaryTerm__Group_1__1__Impl : ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:3569:1: rule__VLSUnitaryTerm__Group_1__1__Impl : ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) ; public final void rule__VLSUnitaryTerm__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3542:1: ( ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:3543:1: ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) + // InternalVampireLanguage.g:3573:1: ( ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:3574:1: ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) { - // InternalVampireLanguage.g:3543:1: ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) - // InternalVampireLanguage.g:3544:2: ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) + // InternalVampireLanguage.g:3574:1: ( ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) ) + // InternalVampireLanguage.g:3575:2: ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) { before(grammarAccess.getVLSUnitaryTermAccess().getNextTypeAssignment_1_1()); - // InternalVampireLanguage.g:3545:2: ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) - // InternalVampireLanguage.g:3545:3: rule__VLSUnitaryTerm__NextTypeAssignment_1_1 + // InternalVampireLanguage.g:3576:2: ( rule__VLSUnitaryTerm__NextTypeAssignment_1_1 ) + // InternalVampireLanguage.g:3576:3: rule__VLSUnitaryTerm__NextTypeAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSUnitaryTerm__NextTypeAssignment_1_1(); @@ -11468,16 +11564,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group__0" - // InternalVampireLanguage.g:3554:1: rule__VLSBinary__Group__0 : rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 ; + // InternalVampireLanguage.g:3585:1: rule__VLSBinary__Group__0 : rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 ; public final void rule__VLSBinary__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3558:1: ( rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 ) - // InternalVampireLanguage.g:3559:2: rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 + // InternalVampireLanguage.g:3589:1: ( rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 ) + // InternalVampireLanguage.g:3590:2: rule__VLSBinary__Group__0__Impl rule__VLSBinary__Group__1 { - pushFollow(FOLLOW_40); + pushFollow(FOLLOW_41); rule__VLSBinary__Group__0__Impl(); state._fsp--; @@ -11506,17 +11602,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group__0__Impl" - // InternalVampireLanguage.g:3566:1: rule__VLSBinary__Group__0__Impl : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:3597:1: rule__VLSBinary__Group__0__Impl : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSBinary__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3570:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:3571:1: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:3601:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:3602:1: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:3571:1: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:3572:2: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:3602:1: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:3603:2: ruleVLSUnitaryFormula { before(grammarAccess.getVLSBinaryAccess().getVLSUnitaryFormulaParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -11547,14 +11643,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group__1" - // InternalVampireLanguage.g:3581:1: rule__VLSBinary__Group__1 : rule__VLSBinary__Group__1__Impl ; + // InternalVampireLanguage.g:3612:1: rule__VLSBinary__Group__1 : rule__VLSBinary__Group__1__Impl ; public final void rule__VLSBinary__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3585:1: ( rule__VLSBinary__Group__1__Impl ) - // InternalVampireLanguage.g:3586:2: rule__VLSBinary__Group__1__Impl + // InternalVampireLanguage.g:3616:1: ( rule__VLSBinary__Group__1__Impl ) + // InternalVampireLanguage.g:3617:2: rule__VLSBinary__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group__1__Impl(); @@ -11580,20 +11676,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group__1__Impl" - // InternalVampireLanguage.g:3592:1: rule__VLSBinary__Group__1__Impl : ( ( rule__VLSBinary__Alternatives_1 )? ) ; + // InternalVampireLanguage.g:3623:1: rule__VLSBinary__Group__1__Impl : ( ( rule__VLSBinary__Alternatives_1 )? ) ; public final void rule__VLSBinary__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3596:1: ( ( ( rule__VLSBinary__Alternatives_1 )? ) ) - // InternalVampireLanguage.g:3597:1: ( ( rule__VLSBinary__Alternatives_1 )? ) + // InternalVampireLanguage.g:3627:1: ( ( ( rule__VLSBinary__Alternatives_1 )? ) ) + // InternalVampireLanguage.g:3628:1: ( ( rule__VLSBinary__Alternatives_1 )? ) { - // InternalVampireLanguage.g:3597:1: ( ( rule__VLSBinary__Alternatives_1 )? ) - // InternalVampireLanguage.g:3598:2: ( rule__VLSBinary__Alternatives_1 )? + // InternalVampireLanguage.g:3628:1: ( ( rule__VLSBinary__Alternatives_1 )? ) + // InternalVampireLanguage.g:3629:2: ( rule__VLSBinary__Alternatives_1 )? { before(grammarAccess.getVLSBinaryAccess().getAlternatives_1()); - // InternalVampireLanguage.g:3599:2: ( rule__VLSBinary__Alternatives_1 )? + // InternalVampireLanguage.g:3630:2: ( rule__VLSBinary__Alternatives_1 )? int alt38=2; int LA38_0 = input.LA(1); @@ -11602,7 +11698,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt38) { case 1 : - // InternalVampireLanguage.g:3599:3: rule__VLSBinary__Alternatives_1 + // InternalVampireLanguage.g:3630:3: rule__VLSBinary__Alternatives_1 { pushFollow(FOLLOW_2); rule__VLSBinary__Alternatives_1(); @@ -11638,14 +11734,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0__0" - // InternalVampireLanguage.g:3608:1: rule__VLSBinary__Group_1_0__0 : rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 ; + // InternalVampireLanguage.g:3639:1: rule__VLSBinary__Group_1_0__0 : rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 ; public final void rule__VLSBinary__Group_1_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3612:1: ( rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 ) - // InternalVampireLanguage.g:3613:2: rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 + // InternalVampireLanguage.g:3643:1: ( rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 ) + // InternalVampireLanguage.g:3644:2: rule__VLSBinary__Group_1_0__0__Impl rule__VLSBinary__Group_1_0__1 { pushFollow(FOLLOW_26); rule__VLSBinary__Group_1_0__0__Impl(); @@ -11676,21 +11772,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0__0__Impl" - // InternalVampireLanguage.g:3620:1: rule__VLSBinary__Group_1_0__0__Impl : ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) ; + // InternalVampireLanguage.g:3651:1: rule__VLSBinary__Group_1_0__0__Impl : ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) ; public final void rule__VLSBinary__Group_1_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3624:1: ( ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) ) - // InternalVampireLanguage.g:3625:1: ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) + // InternalVampireLanguage.g:3655:1: ( ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) ) + // InternalVampireLanguage.g:3656:1: ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) { - // InternalVampireLanguage.g:3625:1: ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) - // InternalVampireLanguage.g:3626:2: ( rule__VLSBinary__Alternatives_1_0_0 ) + // InternalVampireLanguage.g:3656:1: ( ( rule__VLSBinary__Alternatives_1_0_0 ) ) + // InternalVampireLanguage.g:3657:2: ( rule__VLSBinary__Alternatives_1_0_0 ) { before(grammarAccess.getVLSBinaryAccess().getAlternatives_1_0_0()); - // InternalVampireLanguage.g:3627:2: ( rule__VLSBinary__Alternatives_1_0_0 ) - // InternalVampireLanguage.g:3627:3: rule__VLSBinary__Alternatives_1_0_0 + // InternalVampireLanguage.g:3658:2: ( rule__VLSBinary__Alternatives_1_0_0 ) + // InternalVampireLanguage.g:3658:3: rule__VLSBinary__Alternatives_1_0_0 { pushFollow(FOLLOW_2); rule__VLSBinary__Alternatives_1_0_0(); @@ -11723,14 +11819,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0__1" - // InternalVampireLanguage.g:3635:1: rule__VLSBinary__Group_1_0__1 : rule__VLSBinary__Group_1_0__1__Impl ; + // InternalVampireLanguage.g:3666:1: rule__VLSBinary__Group_1_0__1 : rule__VLSBinary__Group_1_0__1__Impl ; public final void rule__VLSBinary__Group_1_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3639:1: ( rule__VLSBinary__Group_1_0__1__Impl ) - // InternalVampireLanguage.g:3640:2: rule__VLSBinary__Group_1_0__1__Impl + // InternalVampireLanguage.g:3670:1: ( rule__VLSBinary__Group_1_0__1__Impl ) + // InternalVampireLanguage.g:3671:2: rule__VLSBinary__Group_1_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0__1__Impl(); @@ -11756,21 +11852,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0__1__Impl" - // InternalVampireLanguage.g:3646:1: rule__VLSBinary__Group_1_0__1__Impl : ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) ; + // InternalVampireLanguage.g:3677:1: rule__VLSBinary__Group_1_0__1__Impl : ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) ; public final void rule__VLSBinary__Group_1_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3650:1: ( ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) ) - // InternalVampireLanguage.g:3651:1: ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) + // InternalVampireLanguage.g:3681:1: ( ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) ) + // InternalVampireLanguage.g:3682:1: ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) { - // InternalVampireLanguage.g:3651:1: ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) - // InternalVampireLanguage.g:3652:2: ( rule__VLSBinary__RightAssignment_1_0_1 ) + // InternalVampireLanguage.g:3682:1: ( ( rule__VLSBinary__RightAssignment_1_0_1 ) ) + // InternalVampireLanguage.g:3683:2: ( rule__VLSBinary__RightAssignment_1_0_1 ) { before(grammarAccess.getVLSBinaryAccess().getRightAssignment_1_0_1()); - // InternalVampireLanguage.g:3653:2: ( rule__VLSBinary__RightAssignment_1_0_1 ) - // InternalVampireLanguage.g:3653:3: rule__VLSBinary__RightAssignment_1_0_1 + // InternalVampireLanguage.g:3684:2: ( rule__VLSBinary__RightAssignment_1_0_1 ) + // InternalVampireLanguage.g:3684:3: rule__VLSBinary__RightAssignment_1_0_1 { pushFollow(FOLLOW_2); rule__VLSBinary__RightAssignment_1_0_1(); @@ -11803,16 +11899,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_0__0" - // InternalVampireLanguage.g:3662:1: rule__VLSBinary__Group_1_0_0_0__0 : rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 ; + // InternalVampireLanguage.g:3693:1: rule__VLSBinary__Group_1_0_0_0__0 : rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 ; public final void rule__VLSBinary__Group_1_0_0_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3666:1: ( rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 ) - // InternalVampireLanguage.g:3667:2: rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 + // InternalVampireLanguage.g:3697:1: ( rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 ) + // InternalVampireLanguage.g:3698:2: rule__VLSBinary__Group_1_0_0_0__0__Impl rule__VLSBinary__Group_1_0_0_0__1 { - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); rule__VLSBinary__Group_1_0_0_0__0__Impl(); state._fsp--; @@ -11841,21 +11937,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_0__0__Impl" - // InternalVampireLanguage.g:3674:1: rule__VLSBinary__Group_1_0_0_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3705:1: rule__VLSBinary__Group_1_0_0_0__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3678:1: ( ( () ) ) - // InternalVampireLanguage.g:3679:1: ( () ) + // InternalVampireLanguage.g:3709:1: ( ( () ) ) + // InternalVampireLanguage.g:3710:1: ( () ) { - // InternalVampireLanguage.g:3679:1: ( () ) - // InternalVampireLanguage.g:3680:2: () + // InternalVampireLanguage.g:3710:1: ( () ) + // InternalVampireLanguage.g:3711:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSEquivalentLeftAction_1_0_0_0_0()); - // InternalVampireLanguage.g:3681:2: () - // InternalVampireLanguage.g:3681:3: + // InternalVampireLanguage.g:3712:2: () + // InternalVampireLanguage.g:3712:3: { } @@ -11878,14 +11974,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_0__1" - // InternalVampireLanguage.g:3689:1: rule__VLSBinary__Group_1_0_0_0__1 : rule__VLSBinary__Group_1_0_0_0__1__Impl ; + // InternalVampireLanguage.g:3720:1: rule__VLSBinary__Group_1_0_0_0__1 : rule__VLSBinary__Group_1_0_0_0__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3693:1: ( rule__VLSBinary__Group_1_0_0_0__1__Impl ) - // InternalVampireLanguage.g:3694:2: rule__VLSBinary__Group_1_0_0_0__1__Impl + // InternalVampireLanguage.g:3724:1: ( rule__VLSBinary__Group_1_0_0_0__1__Impl ) + // InternalVampireLanguage.g:3725:2: rule__VLSBinary__Group_1_0_0_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_0__1__Impl(); @@ -11911,17 +12007,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_0__1__Impl" - // InternalVampireLanguage.g:3700:1: rule__VLSBinary__Group_1_0_0_0__1__Impl : ( '<=>' ) ; + // InternalVampireLanguage.g:3731:1: rule__VLSBinary__Group_1_0_0_0__1__Impl : ( '<=>' ) ; public final void rule__VLSBinary__Group_1_0_0_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3704:1: ( ( '<=>' ) ) - // InternalVampireLanguage.g:3705:1: ( '<=>' ) + // InternalVampireLanguage.g:3735:1: ( ( '<=>' ) ) + // InternalVampireLanguage.g:3736:1: ( '<=>' ) { - // InternalVampireLanguage.g:3705:1: ( '<=>' ) - // InternalVampireLanguage.g:3706:2: '<=>' + // InternalVampireLanguage.g:3736:1: ( '<=>' ) + // InternalVampireLanguage.g:3737:2: '<=>' { before(grammarAccess.getVLSBinaryAccess().getLessThanSignEqualsSignGreaterThanSignKeyword_1_0_0_0_1()); match(input,64,FOLLOW_2); @@ -11948,16 +12044,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_1__0" - // InternalVampireLanguage.g:3716:1: rule__VLSBinary__Group_1_0_0_1__0 : rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 ; + // InternalVampireLanguage.g:3747:1: rule__VLSBinary__Group_1_0_0_1__0 : rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 ; public final void rule__VLSBinary__Group_1_0_0_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3720:1: ( rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 ) - // InternalVampireLanguage.g:3721:2: rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 + // InternalVampireLanguage.g:3751:1: ( rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 ) + // InternalVampireLanguage.g:3752:2: rule__VLSBinary__Group_1_0_0_1__0__Impl rule__VLSBinary__Group_1_0_0_1__1 { - pushFollow(FOLLOW_42); + pushFollow(FOLLOW_43); rule__VLSBinary__Group_1_0_0_1__0__Impl(); state._fsp--; @@ -11986,21 +12082,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_1__0__Impl" - // InternalVampireLanguage.g:3728:1: rule__VLSBinary__Group_1_0_0_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3759:1: rule__VLSBinary__Group_1_0_0_1__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3732:1: ( ( () ) ) - // InternalVampireLanguage.g:3733:1: ( () ) + // InternalVampireLanguage.g:3763:1: ( ( () ) ) + // InternalVampireLanguage.g:3764:1: ( () ) { - // InternalVampireLanguage.g:3733:1: ( () ) - // InternalVampireLanguage.g:3734:2: () + // InternalVampireLanguage.g:3764:1: ( () ) + // InternalVampireLanguage.g:3765:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSImpliesLeftAction_1_0_0_1_0()); - // InternalVampireLanguage.g:3735:2: () - // InternalVampireLanguage.g:3735:3: + // InternalVampireLanguage.g:3766:2: () + // InternalVampireLanguage.g:3766:3: { } @@ -12023,14 +12119,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_1__1" - // InternalVampireLanguage.g:3743:1: rule__VLSBinary__Group_1_0_0_1__1 : rule__VLSBinary__Group_1_0_0_1__1__Impl ; + // InternalVampireLanguage.g:3774:1: rule__VLSBinary__Group_1_0_0_1__1 : rule__VLSBinary__Group_1_0_0_1__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3747:1: ( rule__VLSBinary__Group_1_0_0_1__1__Impl ) - // InternalVampireLanguage.g:3748:2: rule__VLSBinary__Group_1_0_0_1__1__Impl + // InternalVampireLanguage.g:3778:1: ( rule__VLSBinary__Group_1_0_0_1__1__Impl ) + // InternalVampireLanguage.g:3779:2: rule__VLSBinary__Group_1_0_0_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_1__1__Impl(); @@ -12056,17 +12152,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_1__1__Impl" - // InternalVampireLanguage.g:3754:1: rule__VLSBinary__Group_1_0_0_1__1__Impl : ( '=>' ) ; + // InternalVampireLanguage.g:3785:1: rule__VLSBinary__Group_1_0_0_1__1__Impl : ( '=>' ) ; public final void rule__VLSBinary__Group_1_0_0_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3758:1: ( ( '=>' ) ) - // InternalVampireLanguage.g:3759:1: ( '=>' ) + // InternalVampireLanguage.g:3789:1: ( ( '=>' ) ) + // InternalVampireLanguage.g:3790:1: ( '=>' ) { - // InternalVampireLanguage.g:3759:1: ( '=>' ) - // InternalVampireLanguage.g:3760:2: '=>' + // InternalVampireLanguage.g:3790:1: ( '=>' ) + // InternalVampireLanguage.g:3791:2: '=>' { before(grammarAccess.getVLSBinaryAccess().getEqualsSignGreaterThanSignKeyword_1_0_0_1_1()); match(input,65,FOLLOW_2); @@ -12093,16 +12189,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_2__0" - // InternalVampireLanguage.g:3770:1: rule__VLSBinary__Group_1_0_0_2__0 : rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 ; + // InternalVampireLanguage.g:3801:1: rule__VLSBinary__Group_1_0_0_2__0 : rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 ; public final void rule__VLSBinary__Group_1_0_0_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3774:1: ( rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 ) - // InternalVampireLanguage.g:3775:2: rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 + // InternalVampireLanguage.g:3805:1: ( rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 ) + // InternalVampireLanguage.g:3806:2: rule__VLSBinary__Group_1_0_0_2__0__Impl rule__VLSBinary__Group_1_0_0_2__1 { - pushFollow(FOLLOW_43); + pushFollow(FOLLOW_44); rule__VLSBinary__Group_1_0_0_2__0__Impl(); state._fsp--; @@ -12131,21 +12227,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_2__0__Impl" - // InternalVampireLanguage.g:3782:1: rule__VLSBinary__Group_1_0_0_2__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3813:1: rule__VLSBinary__Group_1_0_0_2__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3786:1: ( ( () ) ) - // InternalVampireLanguage.g:3787:1: ( () ) + // InternalVampireLanguage.g:3817:1: ( ( () ) ) + // InternalVampireLanguage.g:3818:1: ( () ) { - // InternalVampireLanguage.g:3787:1: ( () ) - // InternalVampireLanguage.g:3788:2: () + // InternalVampireLanguage.g:3818:1: ( () ) + // InternalVampireLanguage.g:3819:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSRevImpliesLeftAction_1_0_0_2_0()); - // InternalVampireLanguage.g:3789:2: () - // InternalVampireLanguage.g:3789:3: + // InternalVampireLanguage.g:3820:2: () + // InternalVampireLanguage.g:3820:3: { } @@ -12168,14 +12264,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_2__1" - // InternalVampireLanguage.g:3797:1: rule__VLSBinary__Group_1_0_0_2__1 : rule__VLSBinary__Group_1_0_0_2__1__Impl ; + // InternalVampireLanguage.g:3828:1: rule__VLSBinary__Group_1_0_0_2__1 : rule__VLSBinary__Group_1_0_0_2__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3801:1: ( rule__VLSBinary__Group_1_0_0_2__1__Impl ) - // InternalVampireLanguage.g:3802:2: rule__VLSBinary__Group_1_0_0_2__1__Impl + // InternalVampireLanguage.g:3832:1: ( rule__VLSBinary__Group_1_0_0_2__1__Impl ) + // InternalVampireLanguage.g:3833:2: rule__VLSBinary__Group_1_0_0_2__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_2__1__Impl(); @@ -12201,17 +12297,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_2__1__Impl" - // InternalVampireLanguage.g:3808:1: rule__VLSBinary__Group_1_0_0_2__1__Impl : ( '<=' ) ; + // InternalVampireLanguage.g:3839:1: rule__VLSBinary__Group_1_0_0_2__1__Impl : ( '<=' ) ; public final void rule__VLSBinary__Group_1_0_0_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3812:1: ( ( '<=' ) ) - // InternalVampireLanguage.g:3813:1: ( '<=' ) + // InternalVampireLanguage.g:3843:1: ( ( '<=' ) ) + // InternalVampireLanguage.g:3844:1: ( '<=' ) { - // InternalVampireLanguage.g:3813:1: ( '<=' ) - // InternalVampireLanguage.g:3814:2: '<=' + // InternalVampireLanguage.g:3844:1: ( '<=' ) + // InternalVampireLanguage.g:3845:2: '<=' { before(grammarAccess.getVLSBinaryAccess().getLessThanSignEqualsSignKeyword_1_0_0_2_1()); match(input,66,FOLLOW_2); @@ -12238,16 +12334,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_3__0" - // InternalVampireLanguage.g:3824:1: rule__VLSBinary__Group_1_0_0_3__0 : rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 ; + // InternalVampireLanguage.g:3855:1: rule__VLSBinary__Group_1_0_0_3__0 : rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 ; public final void rule__VLSBinary__Group_1_0_0_3__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3828:1: ( rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 ) - // InternalVampireLanguage.g:3829:2: rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 + // InternalVampireLanguage.g:3859:1: ( rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 ) + // InternalVampireLanguage.g:3860:2: rule__VLSBinary__Group_1_0_0_3__0__Impl rule__VLSBinary__Group_1_0_0_3__1 { - pushFollow(FOLLOW_44); + pushFollow(FOLLOW_45); rule__VLSBinary__Group_1_0_0_3__0__Impl(); state._fsp--; @@ -12276,21 +12372,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_3__0__Impl" - // InternalVampireLanguage.g:3836:1: rule__VLSBinary__Group_1_0_0_3__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3867:1: rule__VLSBinary__Group_1_0_0_3__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_3__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3840:1: ( ( () ) ) - // InternalVampireLanguage.g:3841:1: ( () ) + // InternalVampireLanguage.g:3871:1: ( ( () ) ) + // InternalVampireLanguage.g:3872:1: ( () ) { - // InternalVampireLanguage.g:3841:1: ( () ) - // InternalVampireLanguage.g:3842:2: () + // InternalVampireLanguage.g:3872:1: ( () ) + // InternalVampireLanguage.g:3873:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSXnorLeftAction_1_0_0_3_0()); - // InternalVampireLanguage.g:3843:2: () - // InternalVampireLanguage.g:3843:3: + // InternalVampireLanguage.g:3874:2: () + // InternalVampireLanguage.g:3874:3: { } @@ -12313,14 +12409,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_3__1" - // InternalVampireLanguage.g:3851:1: rule__VLSBinary__Group_1_0_0_3__1 : rule__VLSBinary__Group_1_0_0_3__1__Impl ; + // InternalVampireLanguage.g:3882:1: rule__VLSBinary__Group_1_0_0_3__1 : rule__VLSBinary__Group_1_0_0_3__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_3__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3855:1: ( rule__VLSBinary__Group_1_0_0_3__1__Impl ) - // InternalVampireLanguage.g:3856:2: rule__VLSBinary__Group_1_0_0_3__1__Impl + // InternalVampireLanguage.g:3886:1: ( rule__VLSBinary__Group_1_0_0_3__1__Impl ) + // InternalVampireLanguage.g:3887:2: rule__VLSBinary__Group_1_0_0_3__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_3__1__Impl(); @@ -12346,17 +12442,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_3__1__Impl" - // InternalVampireLanguage.g:3862:1: rule__VLSBinary__Group_1_0_0_3__1__Impl : ( '<~>' ) ; + // InternalVampireLanguage.g:3893:1: rule__VLSBinary__Group_1_0_0_3__1__Impl : ( '<~>' ) ; public final void rule__VLSBinary__Group_1_0_0_3__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3866:1: ( ( '<~>' ) ) - // InternalVampireLanguage.g:3867:1: ( '<~>' ) + // InternalVampireLanguage.g:3897:1: ( ( '<~>' ) ) + // InternalVampireLanguage.g:3898:1: ( '<~>' ) { - // InternalVampireLanguage.g:3867:1: ( '<~>' ) - // InternalVampireLanguage.g:3868:2: '<~>' + // InternalVampireLanguage.g:3898:1: ( '<~>' ) + // InternalVampireLanguage.g:3899:2: '<~>' { before(grammarAccess.getVLSBinaryAccess().getLessThanSignTildeGreaterThanSignKeyword_1_0_0_3_1()); match(input,67,FOLLOW_2); @@ -12383,16 +12479,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_4__0" - // InternalVampireLanguage.g:3878:1: rule__VLSBinary__Group_1_0_0_4__0 : rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 ; + // InternalVampireLanguage.g:3909:1: rule__VLSBinary__Group_1_0_0_4__0 : rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 ; public final void rule__VLSBinary__Group_1_0_0_4__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3882:1: ( rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 ) - // InternalVampireLanguage.g:3883:2: rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 + // InternalVampireLanguage.g:3913:1: ( rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 ) + // InternalVampireLanguage.g:3914:2: rule__VLSBinary__Group_1_0_0_4__0__Impl rule__VLSBinary__Group_1_0_0_4__1 { - pushFollow(FOLLOW_45); + pushFollow(FOLLOW_46); rule__VLSBinary__Group_1_0_0_4__0__Impl(); state._fsp--; @@ -12421,21 +12517,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_4__0__Impl" - // InternalVampireLanguage.g:3890:1: rule__VLSBinary__Group_1_0_0_4__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3921:1: rule__VLSBinary__Group_1_0_0_4__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_4__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3894:1: ( ( () ) ) - // InternalVampireLanguage.g:3895:1: ( () ) + // InternalVampireLanguage.g:3925:1: ( ( () ) ) + // InternalVampireLanguage.g:3926:1: ( () ) { - // InternalVampireLanguage.g:3895:1: ( () ) - // InternalVampireLanguage.g:3896:2: () + // InternalVampireLanguage.g:3926:1: ( () ) + // InternalVampireLanguage.g:3927:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSNorLeftAction_1_0_0_4_0()); - // InternalVampireLanguage.g:3897:2: () - // InternalVampireLanguage.g:3897:3: + // InternalVampireLanguage.g:3928:2: () + // InternalVampireLanguage.g:3928:3: { } @@ -12458,14 +12554,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_4__1" - // InternalVampireLanguage.g:3905:1: rule__VLSBinary__Group_1_0_0_4__1 : rule__VLSBinary__Group_1_0_0_4__1__Impl ; + // InternalVampireLanguage.g:3936:1: rule__VLSBinary__Group_1_0_0_4__1 : rule__VLSBinary__Group_1_0_0_4__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_4__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3909:1: ( rule__VLSBinary__Group_1_0_0_4__1__Impl ) - // InternalVampireLanguage.g:3910:2: rule__VLSBinary__Group_1_0_0_4__1__Impl + // InternalVampireLanguage.g:3940:1: ( rule__VLSBinary__Group_1_0_0_4__1__Impl ) + // InternalVampireLanguage.g:3941:2: rule__VLSBinary__Group_1_0_0_4__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_4__1__Impl(); @@ -12491,17 +12587,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_4__1__Impl" - // InternalVampireLanguage.g:3916:1: rule__VLSBinary__Group_1_0_0_4__1__Impl : ( '~|' ) ; + // InternalVampireLanguage.g:3947:1: rule__VLSBinary__Group_1_0_0_4__1__Impl : ( '~|' ) ; public final void rule__VLSBinary__Group_1_0_0_4__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3920:1: ( ( '~|' ) ) - // InternalVampireLanguage.g:3921:1: ( '~|' ) + // InternalVampireLanguage.g:3951:1: ( ( '~|' ) ) + // InternalVampireLanguage.g:3952:1: ( '~|' ) { - // InternalVampireLanguage.g:3921:1: ( '~|' ) - // InternalVampireLanguage.g:3922:2: '~|' + // InternalVampireLanguage.g:3952:1: ( '~|' ) + // InternalVampireLanguage.g:3953:2: '~|' { before(grammarAccess.getVLSBinaryAccess().getTildeVerticalLineKeyword_1_0_0_4_1()); match(input,68,FOLLOW_2); @@ -12528,16 +12624,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_5__0" - // InternalVampireLanguage.g:3932:1: rule__VLSBinary__Group_1_0_0_5__0 : rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 ; + // InternalVampireLanguage.g:3963:1: rule__VLSBinary__Group_1_0_0_5__0 : rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 ; public final void rule__VLSBinary__Group_1_0_0_5__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3936:1: ( rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 ) - // InternalVampireLanguage.g:3937:2: rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 + // InternalVampireLanguage.g:3967:1: ( rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 ) + // InternalVampireLanguage.g:3968:2: rule__VLSBinary__Group_1_0_0_5__0__Impl rule__VLSBinary__Group_1_0_0_5__1 { - pushFollow(FOLLOW_46); + pushFollow(FOLLOW_47); rule__VLSBinary__Group_1_0_0_5__0__Impl(); state._fsp--; @@ -12566,21 +12662,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_5__0__Impl" - // InternalVampireLanguage.g:3944:1: rule__VLSBinary__Group_1_0_0_5__0__Impl : ( () ) ; + // InternalVampireLanguage.g:3975:1: rule__VLSBinary__Group_1_0_0_5__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_0_0_5__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3948:1: ( ( () ) ) - // InternalVampireLanguage.g:3949:1: ( () ) + // InternalVampireLanguage.g:3979:1: ( ( () ) ) + // InternalVampireLanguage.g:3980:1: ( () ) { - // InternalVampireLanguage.g:3949:1: ( () ) - // InternalVampireLanguage.g:3950:2: () + // InternalVampireLanguage.g:3980:1: ( () ) + // InternalVampireLanguage.g:3981:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSNandLeftAction_1_0_0_5_0()); - // InternalVampireLanguage.g:3951:2: () - // InternalVampireLanguage.g:3951:3: + // InternalVampireLanguage.g:3982:2: () + // InternalVampireLanguage.g:3982:3: { } @@ -12603,14 +12699,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_5__1" - // InternalVampireLanguage.g:3959:1: rule__VLSBinary__Group_1_0_0_5__1 : rule__VLSBinary__Group_1_0_0_5__1__Impl ; + // InternalVampireLanguage.g:3990:1: rule__VLSBinary__Group_1_0_0_5__1 : rule__VLSBinary__Group_1_0_0_5__1__Impl ; public final void rule__VLSBinary__Group_1_0_0_5__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3963:1: ( rule__VLSBinary__Group_1_0_0_5__1__Impl ) - // InternalVampireLanguage.g:3964:2: rule__VLSBinary__Group_1_0_0_5__1__Impl + // InternalVampireLanguage.g:3994:1: ( rule__VLSBinary__Group_1_0_0_5__1__Impl ) + // InternalVampireLanguage.g:3995:2: rule__VLSBinary__Group_1_0_0_5__1__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_0_0_5__1__Impl(); @@ -12636,17 +12732,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_0_0_5__1__Impl" - // InternalVampireLanguage.g:3970:1: rule__VLSBinary__Group_1_0_0_5__1__Impl : ( '~&' ) ; + // InternalVampireLanguage.g:4001:1: rule__VLSBinary__Group_1_0_0_5__1__Impl : ( '~&' ) ; public final void rule__VLSBinary__Group_1_0_0_5__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3974:1: ( ( '~&' ) ) - // InternalVampireLanguage.g:3975:1: ( '~&' ) + // InternalVampireLanguage.g:4005:1: ( ( '~&' ) ) + // InternalVampireLanguage.g:4006:1: ( '~&' ) { - // InternalVampireLanguage.g:3975:1: ( '~&' ) - // InternalVampireLanguage.g:3976:2: '~&' + // InternalVampireLanguage.g:4006:1: ( '~&' ) + // InternalVampireLanguage.g:4007:2: '~&' { before(grammarAccess.getVLSBinaryAccess().getTildeAmpersandKeyword_1_0_0_5_1()); match(input,69,FOLLOW_2); @@ -12673,16 +12769,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__0" - // InternalVampireLanguage.g:3986:1: rule__VLSBinary__Group_1_1__0 : rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 ; + // InternalVampireLanguage.g:4017:1: rule__VLSBinary__Group_1_1__0 : rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 ; public final void rule__VLSBinary__Group_1_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:3990:1: ( rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 ) - // InternalVampireLanguage.g:3991:2: rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 + // InternalVampireLanguage.g:4021:1: ( rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 ) + // InternalVampireLanguage.g:4022:2: rule__VLSBinary__Group_1_1__0__Impl rule__VLSBinary__Group_1_1__1 { - pushFollow(FOLLOW_47); + pushFollow(FOLLOW_48); rule__VLSBinary__Group_1_1__0__Impl(); state._fsp--; @@ -12711,21 +12807,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__0__Impl" - // InternalVampireLanguage.g:3998:1: rule__VLSBinary__Group_1_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:4029:1: rule__VLSBinary__Group_1_1__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4002:1: ( ( () ) ) - // InternalVampireLanguage.g:4003:1: ( () ) + // InternalVampireLanguage.g:4033:1: ( ( () ) ) + // InternalVampireLanguage.g:4034:1: ( () ) { - // InternalVampireLanguage.g:4003:1: ( () ) - // InternalVampireLanguage.g:4004:2: () + // InternalVampireLanguage.g:4034:1: ( () ) + // InternalVampireLanguage.g:4035:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSAndLeftAction_1_1_0()); - // InternalVampireLanguage.g:4005:2: () - // InternalVampireLanguage.g:4005:3: + // InternalVampireLanguage.g:4036:2: () + // InternalVampireLanguage.g:4036:3: { } @@ -12748,14 +12844,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__1" - // InternalVampireLanguage.g:4013:1: rule__VLSBinary__Group_1_1__1 : rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 ; + // InternalVampireLanguage.g:4044:1: rule__VLSBinary__Group_1_1__1 : rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 ; public final void rule__VLSBinary__Group_1_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4017:1: ( rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 ) - // InternalVampireLanguage.g:4018:2: rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 + // InternalVampireLanguage.g:4048:1: ( rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 ) + // InternalVampireLanguage.g:4049:2: rule__VLSBinary__Group_1_1__1__Impl rule__VLSBinary__Group_1_1__2 { pushFollow(FOLLOW_26); rule__VLSBinary__Group_1_1__1__Impl(); @@ -12786,17 +12882,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__1__Impl" - // InternalVampireLanguage.g:4025:1: rule__VLSBinary__Group_1_1__1__Impl : ( '&' ) ; + // InternalVampireLanguage.g:4056:1: rule__VLSBinary__Group_1_1__1__Impl : ( '&' ) ; public final void rule__VLSBinary__Group_1_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4029:1: ( ( '&' ) ) - // InternalVampireLanguage.g:4030:1: ( '&' ) + // InternalVampireLanguage.g:4060:1: ( ( '&' ) ) + // InternalVampireLanguage.g:4061:1: ( '&' ) { - // InternalVampireLanguage.g:4030:1: ( '&' ) - // InternalVampireLanguage.g:4031:2: '&' + // InternalVampireLanguage.g:4061:1: ( '&' ) + // InternalVampireLanguage.g:4062:2: '&' { before(grammarAccess.getVLSBinaryAccess().getAmpersandKeyword_1_1_1()); match(input,70,FOLLOW_2); @@ -12823,14 +12919,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__2" - // InternalVampireLanguage.g:4040:1: rule__VLSBinary__Group_1_1__2 : rule__VLSBinary__Group_1_1__2__Impl ; + // InternalVampireLanguage.g:4071:1: rule__VLSBinary__Group_1_1__2 : rule__VLSBinary__Group_1_1__2__Impl ; public final void rule__VLSBinary__Group_1_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4044:1: ( rule__VLSBinary__Group_1_1__2__Impl ) - // InternalVampireLanguage.g:4045:2: rule__VLSBinary__Group_1_1__2__Impl + // InternalVampireLanguage.g:4075:1: ( rule__VLSBinary__Group_1_1__2__Impl ) + // InternalVampireLanguage.g:4076:2: rule__VLSBinary__Group_1_1__2__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_1__2__Impl(); @@ -12856,21 +12952,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_1__2__Impl" - // InternalVampireLanguage.g:4051:1: rule__VLSBinary__Group_1_1__2__Impl : ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) ; + // InternalVampireLanguage.g:4082:1: rule__VLSBinary__Group_1_1__2__Impl : ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) ; public final void rule__VLSBinary__Group_1_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4055:1: ( ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) ) - // InternalVampireLanguage.g:4056:1: ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) + // InternalVampireLanguage.g:4086:1: ( ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) ) + // InternalVampireLanguage.g:4087:1: ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) { - // InternalVampireLanguage.g:4056:1: ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) - // InternalVampireLanguage.g:4057:2: ( rule__VLSBinary__RightAssignment_1_1_2 ) + // InternalVampireLanguage.g:4087:1: ( ( rule__VLSBinary__RightAssignment_1_1_2 ) ) + // InternalVampireLanguage.g:4088:2: ( rule__VLSBinary__RightAssignment_1_1_2 ) { before(grammarAccess.getVLSBinaryAccess().getRightAssignment_1_1_2()); - // InternalVampireLanguage.g:4058:2: ( rule__VLSBinary__RightAssignment_1_1_2 ) - // InternalVampireLanguage.g:4058:3: rule__VLSBinary__RightAssignment_1_1_2 + // InternalVampireLanguage.g:4089:2: ( rule__VLSBinary__RightAssignment_1_1_2 ) + // InternalVampireLanguage.g:4089:3: rule__VLSBinary__RightAssignment_1_1_2 { pushFollow(FOLLOW_2); rule__VLSBinary__RightAssignment_1_1_2(); @@ -12903,16 +12999,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__0" - // InternalVampireLanguage.g:4067:1: rule__VLSBinary__Group_1_2__0 : rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 ; + // InternalVampireLanguage.g:4098:1: rule__VLSBinary__Group_1_2__0 : rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 ; public final void rule__VLSBinary__Group_1_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4071:1: ( rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 ) - // InternalVampireLanguage.g:4072:2: rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 + // InternalVampireLanguage.g:4102:1: ( rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 ) + // InternalVampireLanguage.g:4103:2: rule__VLSBinary__Group_1_2__0__Impl rule__VLSBinary__Group_1_2__1 { - pushFollow(FOLLOW_48); + pushFollow(FOLLOW_49); rule__VLSBinary__Group_1_2__0__Impl(); state._fsp--; @@ -12941,21 +13037,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__0__Impl" - // InternalVampireLanguage.g:4079:1: rule__VLSBinary__Group_1_2__0__Impl : ( () ) ; + // InternalVampireLanguage.g:4110:1: rule__VLSBinary__Group_1_2__0__Impl : ( () ) ; public final void rule__VLSBinary__Group_1_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4083:1: ( ( () ) ) - // InternalVampireLanguage.g:4084:1: ( () ) + // InternalVampireLanguage.g:4114:1: ( ( () ) ) + // InternalVampireLanguage.g:4115:1: ( () ) { - // InternalVampireLanguage.g:4084:1: ( () ) - // InternalVampireLanguage.g:4085:2: () + // InternalVampireLanguage.g:4115:1: ( () ) + // InternalVampireLanguage.g:4116:2: () { before(grammarAccess.getVLSBinaryAccess().getVLSOrLeftAction_1_2_0()); - // InternalVampireLanguage.g:4086:2: () - // InternalVampireLanguage.g:4086:3: + // InternalVampireLanguage.g:4117:2: () + // InternalVampireLanguage.g:4117:3: { } @@ -12978,14 +13074,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__1" - // InternalVampireLanguage.g:4094:1: rule__VLSBinary__Group_1_2__1 : rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 ; + // InternalVampireLanguage.g:4125:1: rule__VLSBinary__Group_1_2__1 : rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 ; public final void rule__VLSBinary__Group_1_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4098:1: ( rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 ) - // InternalVampireLanguage.g:4099:2: rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 + // InternalVampireLanguage.g:4129:1: ( rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 ) + // InternalVampireLanguage.g:4130:2: rule__VLSBinary__Group_1_2__1__Impl rule__VLSBinary__Group_1_2__2 { pushFollow(FOLLOW_26); rule__VLSBinary__Group_1_2__1__Impl(); @@ -13016,17 +13112,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__1__Impl" - // InternalVampireLanguage.g:4106:1: rule__VLSBinary__Group_1_2__1__Impl : ( '|' ) ; + // InternalVampireLanguage.g:4137:1: rule__VLSBinary__Group_1_2__1__Impl : ( '|' ) ; public final void rule__VLSBinary__Group_1_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4110:1: ( ( '|' ) ) - // InternalVampireLanguage.g:4111:1: ( '|' ) + // InternalVampireLanguage.g:4141:1: ( ( '|' ) ) + // InternalVampireLanguage.g:4142:1: ( '|' ) { - // InternalVampireLanguage.g:4111:1: ( '|' ) - // InternalVampireLanguage.g:4112:2: '|' + // InternalVampireLanguage.g:4142:1: ( '|' ) + // InternalVampireLanguage.g:4143:2: '|' { before(grammarAccess.getVLSBinaryAccess().getVerticalLineKeyword_1_2_1()); match(input,71,FOLLOW_2); @@ -13053,14 +13149,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__2" - // InternalVampireLanguage.g:4121:1: rule__VLSBinary__Group_1_2__2 : rule__VLSBinary__Group_1_2__2__Impl ; + // InternalVampireLanguage.g:4152:1: rule__VLSBinary__Group_1_2__2 : rule__VLSBinary__Group_1_2__2__Impl ; public final void rule__VLSBinary__Group_1_2__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4125:1: ( rule__VLSBinary__Group_1_2__2__Impl ) - // InternalVampireLanguage.g:4126:2: rule__VLSBinary__Group_1_2__2__Impl + // InternalVampireLanguage.g:4156:1: ( rule__VLSBinary__Group_1_2__2__Impl ) + // InternalVampireLanguage.g:4157:2: rule__VLSBinary__Group_1_2__2__Impl { pushFollow(FOLLOW_2); rule__VLSBinary__Group_1_2__2__Impl(); @@ -13086,21 +13182,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__Group_1_2__2__Impl" - // InternalVampireLanguage.g:4132:1: rule__VLSBinary__Group_1_2__2__Impl : ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) ; + // InternalVampireLanguage.g:4163:1: rule__VLSBinary__Group_1_2__2__Impl : ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) ; public final void rule__VLSBinary__Group_1_2__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4136:1: ( ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) ) - // InternalVampireLanguage.g:4137:1: ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) + // InternalVampireLanguage.g:4167:1: ( ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) ) + // InternalVampireLanguage.g:4168:1: ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) { - // InternalVampireLanguage.g:4137:1: ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) - // InternalVampireLanguage.g:4138:2: ( rule__VLSBinary__RightAssignment_1_2_2 ) + // InternalVampireLanguage.g:4168:1: ( ( rule__VLSBinary__RightAssignment_1_2_2 ) ) + // InternalVampireLanguage.g:4169:2: ( rule__VLSBinary__RightAssignment_1_2_2 ) { before(grammarAccess.getVLSBinaryAccess().getRightAssignment_1_2_2()); - // InternalVampireLanguage.g:4139:2: ( rule__VLSBinary__RightAssignment_1_2_2 ) - // InternalVampireLanguage.g:4139:3: rule__VLSBinary__RightAssignment_1_2_2 + // InternalVampireLanguage.g:4170:2: ( rule__VLSBinary__RightAssignment_1_2_2 ) + // InternalVampireLanguage.g:4170:3: rule__VLSBinary__RightAssignment_1_2_2 { pushFollow(FOLLOW_2); rule__VLSBinary__RightAssignment_1_2_2(); @@ -13133,14 +13229,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__0" - // InternalVampireLanguage.g:4148:1: rule__VLSUnitaryFormula__Group_4__0 : rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 ; + // InternalVampireLanguage.g:4179:1: rule__VLSUnitaryFormula__Group_4__0 : rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 ; public final void rule__VLSUnitaryFormula__Group_4__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4152:1: ( rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 ) - // InternalVampireLanguage.g:4153:2: rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 + // InternalVampireLanguage.g:4183:1: ( rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 ) + // InternalVampireLanguage.g:4184:2: rule__VLSUnitaryFormula__Group_4__0__Impl rule__VLSUnitaryFormula__Group_4__1 { pushFollow(FOLLOW_26); rule__VLSUnitaryFormula__Group_4__0__Impl(); @@ -13171,17 +13267,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__0__Impl" - // InternalVampireLanguage.g:4160:1: rule__VLSUnitaryFormula__Group_4__0__Impl : ( '(' ) ; + // InternalVampireLanguage.g:4191:1: rule__VLSUnitaryFormula__Group_4__0__Impl : ( '(' ) ; public final void rule__VLSUnitaryFormula__Group_4__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4164:1: ( ( '(' ) ) - // InternalVampireLanguage.g:4165:1: ( '(' ) + // InternalVampireLanguage.g:4195:1: ( ( '(' ) ) + // InternalVampireLanguage.g:4196:1: ( '(' ) { - // InternalVampireLanguage.g:4165:1: ( '(' ) - // InternalVampireLanguage.g:4166:2: '(' + // InternalVampireLanguage.g:4196:1: ( '(' ) + // InternalVampireLanguage.g:4197:2: '(' { before(grammarAccess.getVLSUnitaryFormulaAccess().getLeftParenthesisKeyword_4_0()); match(input,55,FOLLOW_2); @@ -13208,16 +13304,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__1" - // InternalVampireLanguage.g:4175:1: rule__VLSUnitaryFormula__Group_4__1 : rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 ; + // InternalVampireLanguage.g:4206:1: rule__VLSUnitaryFormula__Group_4__1 : rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 ; public final void rule__VLSUnitaryFormula__Group_4__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4179:1: ( rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 ) - // InternalVampireLanguage.g:4180:2: rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 + // InternalVampireLanguage.g:4210:1: ( rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 ) + // InternalVampireLanguage.g:4211:2: rule__VLSUnitaryFormula__Group_4__1__Impl rule__VLSUnitaryFormula__Group_4__2 { - pushFollow(FOLLOW_32); + pushFollow(FOLLOW_33); rule__VLSUnitaryFormula__Group_4__1__Impl(); state._fsp--; @@ -13246,17 +13342,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__1__Impl" - // InternalVampireLanguage.g:4187:1: rule__VLSUnitaryFormula__Group_4__1__Impl : ( ruleVLSTerm ) ; + // InternalVampireLanguage.g:4218:1: rule__VLSUnitaryFormula__Group_4__1__Impl : ( ruleVLSTerm ) ; public final void rule__VLSUnitaryFormula__Group_4__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4191:1: ( ( ruleVLSTerm ) ) - // InternalVampireLanguage.g:4192:1: ( ruleVLSTerm ) + // InternalVampireLanguage.g:4222:1: ( ( ruleVLSTerm ) ) + // InternalVampireLanguage.g:4223:1: ( ruleVLSTerm ) { - // InternalVampireLanguage.g:4192:1: ( ruleVLSTerm ) - // InternalVampireLanguage.g:4193:2: ruleVLSTerm + // InternalVampireLanguage.g:4223:1: ( ruleVLSTerm ) + // InternalVampireLanguage.g:4224:2: ruleVLSTerm { before(grammarAccess.getVLSUnitaryFormulaAccess().getVLSTermParserRuleCall_4_1()); pushFollow(FOLLOW_2); @@ -13287,14 +13383,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__2" - // InternalVampireLanguage.g:4202:1: rule__VLSUnitaryFormula__Group_4__2 : rule__VLSUnitaryFormula__Group_4__2__Impl ; + // InternalVampireLanguage.g:4233:1: rule__VLSUnitaryFormula__Group_4__2 : rule__VLSUnitaryFormula__Group_4__2__Impl ; public final void rule__VLSUnitaryFormula__Group_4__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4206:1: ( rule__VLSUnitaryFormula__Group_4__2__Impl ) - // InternalVampireLanguage.g:4207:2: rule__VLSUnitaryFormula__Group_4__2__Impl + // InternalVampireLanguage.g:4237:1: ( rule__VLSUnitaryFormula__Group_4__2__Impl ) + // InternalVampireLanguage.g:4238:2: rule__VLSUnitaryFormula__Group_4__2__Impl { pushFollow(FOLLOW_2); rule__VLSUnitaryFormula__Group_4__2__Impl(); @@ -13320,17 +13416,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryFormula__Group_4__2__Impl" - // InternalVampireLanguage.g:4213:1: rule__VLSUnitaryFormula__Group_4__2__Impl : ( ')' ) ; + // InternalVampireLanguage.g:4244:1: rule__VLSUnitaryFormula__Group_4__2__Impl : ( ')' ) ; public final void rule__VLSUnitaryFormula__Group_4__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4217:1: ( ( ')' ) ) - // InternalVampireLanguage.g:4218:1: ( ')' ) + // InternalVampireLanguage.g:4248:1: ( ( ')' ) ) + // InternalVampireLanguage.g:4249:1: ( ')' ) { - // InternalVampireLanguage.g:4218:1: ( ')' ) - // InternalVampireLanguage.g:4219:2: ')' + // InternalVampireLanguage.g:4249:1: ( ')' ) + // InternalVampireLanguage.g:4250:2: ')' { before(grammarAccess.getVLSUnitaryFormulaAccess().getRightParenthesisKeyword_4_2()); match(input,57,FOLLOW_2); @@ -13357,16 +13453,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__0" - // InternalVampireLanguage.g:4229:1: rule__VLSUniversalQuantifier__Group__0 : rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 ; + // InternalVampireLanguage.g:4260:1: rule__VLSUniversalQuantifier__Group__0 : rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 ; public final void rule__VLSUniversalQuantifier__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4233:1: ( rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 ) - // InternalVampireLanguage.g:4234:2: rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 + // InternalVampireLanguage.g:4264:1: ( rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 ) + // InternalVampireLanguage.g:4265:2: rule__VLSUniversalQuantifier__Group__0__Impl rule__VLSUniversalQuantifier__Group__1 { - pushFollow(FOLLOW_49); + pushFollow(FOLLOW_50); rule__VLSUniversalQuantifier__Group__0__Impl(); state._fsp--; @@ -13395,21 +13491,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__0__Impl" - // InternalVampireLanguage.g:4241:1: rule__VLSUniversalQuantifier__Group__0__Impl : ( () ) ; + // InternalVampireLanguage.g:4272:1: rule__VLSUniversalQuantifier__Group__0__Impl : ( () ) ; public final void rule__VLSUniversalQuantifier__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4245:1: ( ( () ) ) - // InternalVampireLanguage.g:4246:1: ( () ) + // InternalVampireLanguage.g:4276:1: ( ( () ) ) + // InternalVampireLanguage.g:4277:1: ( () ) { - // InternalVampireLanguage.g:4246:1: ( () ) - // InternalVampireLanguage.g:4247:2: () + // InternalVampireLanguage.g:4277:1: ( () ) + // InternalVampireLanguage.g:4278:2: () { before(grammarAccess.getVLSUniversalQuantifierAccess().getVLSUniversalQuantifierAction_0()); - // InternalVampireLanguage.g:4248:2: () - // InternalVampireLanguage.g:4248:3: + // InternalVampireLanguage.g:4279:2: () + // InternalVampireLanguage.g:4279:3: { } @@ -13432,14 +13528,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__1" - // InternalVampireLanguage.g:4256:1: rule__VLSUniversalQuantifier__Group__1 : rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 ; + // InternalVampireLanguage.g:4287:1: rule__VLSUniversalQuantifier__Group__1 : rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 ; public final void rule__VLSUniversalQuantifier__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4260:1: ( rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 ) - // InternalVampireLanguage.g:4261:2: rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 + // InternalVampireLanguage.g:4291:1: ( rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 ) + // InternalVampireLanguage.g:4292:2: rule__VLSUniversalQuantifier__Group__1__Impl rule__VLSUniversalQuantifier__Group__2 { pushFollow(FOLLOW_26); rule__VLSUniversalQuantifier__Group__1__Impl(); @@ -13470,21 +13566,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__1__Impl" - // InternalVampireLanguage.g:4268:1: rule__VLSUniversalQuantifier__Group__1__Impl : ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) ; + // InternalVampireLanguage.g:4299:1: rule__VLSUniversalQuantifier__Group__1__Impl : ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) ; public final void rule__VLSUniversalQuantifier__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4272:1: ( ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) ) - // InternalVampireLanguage.g:4273:1: ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) + // InternalVampireLanguage.g:4303:1: ( ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) ) + // InternalVampireLanguage.g:4304:1: ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) { - // InternalVampireLanguage.g:4273:1: ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) - // InternalVampireLanguage.g:4274:2: ( rule__VLSUniversalQuantifier__Group_1__0 ) + // InternalVampireLanguage.g:4304:1: ( ( rule__VLSUniversalQuantifier__Group_1__0 ) ) + // InternalVampireLanguage.g:4305:2: ( rule__VLSUniversalQuantifier__Group_1__0 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getGroup_1()); - // InternalVampireLanguage.g:4275:2: ( rule__VLSUniversalQuantifier__Group_1__0 ) - // InternalVampireLanguage.g:4275:3: rule__VLSUniversalQuantifier__Group_1__0 + // InternalVampireLanguage.g:4306:2: ( rule__VLSUniversalQuantifier__Group_1__0 ) + // InternalVampireLanguage.g:4306:3: rule__VLSUniversalQuantifier__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__Group_1__0(); @@ -13517,14 +13613,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__2" - // InternalVampireLanguage.g:4283:1: rule__VLSUniversalQuantifier__Group__2 : rule__VLSUniversalQuantifier__Group__2__Impl ; + // InternalVampireLanguage.g:4314:1: rule__VLSUniversalQuantifier__Group__2 : rule__VLSUniversalQuantifier__Group__2__Impl ; public final void rule__VLSUniversalQuantifier__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4287:1: ( rule__VLSUniversalQuantifier__Group__2__Impl ) - // InternalVampireLanguage.g:4288:2: rule__VLSUniversalQuantifier__Group__2__Impl + // InternalVampireLanguage.g:4318:1: ( rule__VLSUniversalQuantifier__Group__2__Impl ) + // InternalVampireLanguage.g:4319:2: rule__VLSUniversalQuantifier__Group__2__Impl { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__Group__2__Impl(); @@ -13550,21 +13646,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group__2__Impl" - // InternalVampireLanguage.g:4294:1: rule__VLSUniversalQuantifier__Group__2__Impl : ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) ; + // InternalVampireLanguage.g:4325:1: rule__VLSUniversalQuantifier__Group__2__Impl : ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) ; public final void rule__VLSUniversalQuantifier__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4298:1: ( ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) ) - // InternalVampireLanguage.g:4299:1: ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4329:1: ( ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) ) + // InternalVampireLanguage.g:4330:1: ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) { - // InternalVampireLanguage.g:4299:1: ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) - // InternalVampireLanguage.g:4300:2: ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) + // InternalVampireLanguage.g:4330:1: ( ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4331:2: ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getOperandAssignment_2()); - // InternalVampireLanguage.g:4301:2: ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) - // InternalVampireLanguage.g:4301:3: rule__VLSUniversalQuantifier__OperandAssignment_2 + // InternalVampireLanguage.g:4332:2: ( rule__VLSUniversalQuantifier__OperandAssignment_2 ) + // InternalVampireLanguage.g:4332:3: rule__VLSUniversalQuantifier__OperandAssignment_2 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__OperandAssignment_2(); @@ -13597,14 +13693,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__0" - // InternalVampireLanguage.g:4310:1: rule__VLSUniversalQuantifier__Group_1__0 : rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 ; + // InternalVampireLanguage.g:4341:1: rule__VLSUniversalQuantifier__Group_1__0 : rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 ; public final void rule__VLSUniversalQuantifier__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4314:1: ( rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 ) - // InternalVampireLanguage.g:4315:2: rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 + // InternalVampireLanguage.g:4345:1: ( rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 ) + // InternalVampireLanguage.g:4346:2: rule__VLSUniversalQuantifier__Group_1__0__Impl rule__VLSUniversalQuantifier__Group_1__1 { pushFollow(FOLLOW_16); rule__VLSUniversalQuantifier__Group_1__0__Impl(); @@ -13635,17 +13731,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__0__Impl" - // InternalVampireLanguage.g:4322:1: rule__VLSUniversalQuantifier__Group_1__0__Impl : ( '!' ) ; + // InternalVampireLanguage.g:4353:1: rule__VLSUniversalQuantifier__Group_1__0__Impl : ( '!' ) ; public final void rule__VLSUniversalQuantifier__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4326:1: ( ( '!' ) ) - // InternalVampireLanguage.g:4327:1: ( '!' ) + // InternalVampireLanguage.g:4357:1: ( ( '!' ) ) + // InternalVampireLanguage.g:4358:1: ( '!' ) { - // InternalVampireLanguage.g:4327:1: ( '!' ) - // InternalVampireLanguage.g:4328:2: '!' + // InternalVampireLanguage.g:4358:1: ( '!' ) + // InternalVampireLanguage.g:4359:2: '!' { before(grammarAccess.getVLSUniversalQuantifierAccess().getExclamationMarkKeyword_1_0()); match(input,72,FOLLOW_2); @@ -13672,16 +13768,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__1" - // InternalVampireLanguage.g:4337:1: rule__VLSUniversalQuantifier__Group_1__1 : rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 ; + // InternalVampireLanguage.g:4368:1: rule__VLSUniversalQuantifier__Group_1__1 : rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 ; public final void rule__VLSUniversalQuantifier__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4341:1: ( rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 ) - // InternalVampireLanguage.g:4342:2: rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 + // InternalVampireLanguage.g:4372:1: ( rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 ) + // InternalVampireLanguage.g:4373:2: rule__VLSUniversalQuantifier__Group_1__1__Impl rule__VLSUniversalQuantifier__Group_1__2 { - pushFollow(FOLLOW_50); + pushFollow(FOLLOW_51); rule__VLSUniversalQuantifier__Group_1__1__Impl(); state._fsp--; @@ -13710,17 +13806,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__1__Impl" - // InternalVampireLanguage.g:4349:1: rule__VLSUniversalQuantifier__Group_1__1__Impl : ( '[' ) ; + // InternalVampireLanguage.g:4380:1: rule__VLSUniversalQuantifier__Group_1__1__Impl : ( '[' ) ; public final void rule__VLSUniversalQuantifier__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4353:1: ( ( '[' ) ) - // InternalVampireLanguage.g:4354:1: ( '[' ) + // InternalVampireLanguage.g:4384:1: ( ( '[' ) ) + // InternalVampireLanguage.g:4385:1: ( '[' ) { - // InternalVampireLanguage.g:4354:1: ( '[' ) - // InternalVampireLanguage.g:4355:2: '[' + // InternalVampireLanguage.g:4385:1: ( '[' ) + // InternalVampireLanguage.g:4386:2: '[' { before(grammarAccess.getVLSUniversalQuantifierAccess().getLeftSquareBracketKeyword_1_1()); match(input,49,FOLLOW_2); @@ -13747,16 +13843,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__2" - // InternalVampireLanguage.g:4364:1: rule__VLSUniversalQuantifier__Group_1__2 : rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 ; + // InternalVampireLanguage.g:4395:1: rule__VLSUniversalQuantifier__Group_1__2 : rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 ; public final void rule__VLSUniversalQuantifier__Group_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4368:1: ( rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 ) - // InternalVampireLanguage.g:4369:2: rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 + // InternalVampireLanguage.g:4399:1: ( rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 ) + // InternalVampireLanguage.g:4400:2: rule__VLSUniversalQuantifier__Group_1__2__Impl rule__VLSUniversalQuantifier__Group_1__3 { - pushFollow(FOLLOW_51); + pushFollow(FOLLOW_52); rule__VLSUniversalQuantifier__Group_1__2__Impl(); state._fsp--; @@ -13785,21 +13881,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__2__Impl" - // InternalVampireLanguage.g:4376:1: rule__VLSUniversalQuantifier__Group_1__2__Impl : ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) ; + // InternalVampireLanguage.g:4407:1: rule__VLSUniversalQuantifier__Group_1__2__Impl : ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) ; public final void rule__VLSUniversalQuantifier__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4380:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) ) - // InternalVampireLanguage.g:4381:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) + // InternalVampireLanguage.g:4411:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) ) + // InternalVampireLanguage.g:4412:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) { - // InternalVampireLanguage.g:4381:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) - // InternalVampireLanguage.g:4382:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) + // InternalVampireLanguage.g:4412:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) ) + // InternalVampireLanguage.g:4413:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesAssignment_1_2()); - // InternalVampireLanguage.g:4383:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) - // InternalVampireLanguage.g:4383:3: rule__VLSUniversalQuantifier__VariablesAssignment_1_2 + // InternalVampireLanguage.g:4414:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_2 ) + // InternalVampireLanguage.g:4414:3: rule__VLSUniversalQuantifier__VariablesAssignment_1_2 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__VariablesAssignment_1_2(); @@ -13832,16 +13928,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__3" - // InternalVampireLanguage.g:4391:1: rule__VLSUniversalQuantifier__Group_1__3 : rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 ; + // InternalVampireLanguage.g:4422:1: rule__VLSUniversalQuantifier__Group_1__3 : rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 ; public final void rule__VLSUniversalQuantifier__Group_1__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4395:1: ( rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 ) - // InternalVampireLanguage.g:4396:2: rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 + // InternalVampireLanguage.g:4426:1: ( rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 ) + // InternalVampireLanguage.g:4427:2: rule__VLSUniversalQuantifier__Group_1__3__Impl rule__VLSUniversalQuantifier__Group_1__4 { - pushFollow(FOLLOW_51); + pushFollow(FOLLOW_52); rule__VLSUniversalQuantifier__Group_1__3__Impl(); state._fsp--; @@ -13870,20 +13966,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__3__Impl" - // InternalVampireLanguage.g:4403:1: rule__VLSUniversalQuantifier__Group_1__3__Impl : ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) ; + // InternalVampireLanguage.g:4434:1: rule__VLSUniversalQuantifier__Group_1__3__Impl : ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) ; public final void rule__VLSUniversalQuantifier__Group_1__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4407:1: ( ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) ) - // InternalVampireLanguage.g:4408:1: ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) + // InternalVampireLanguage.g:4438:1: ( ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) ) + // InternalVampireLanguage.g:4439:1: ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) { - // InternalVampireLanguage.g:4408:1: ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) - // InternalVampireLanguage.g:4409:2: ( rule__VLSUniversalQuantifier__Group_1_3__0 )* + // InternalVampireLanguage.g:4439:1: ( ( rule__VLSUniversalQuantifier__Group_1_3__0 )* ) + // InternalVampireLanguage.g:4440:2: ( rule__VLSUniversalQuantifier__Group_1_3__0 )* { before(grammarAccess.getVLSUniversalQuantifierAccess().getGroup_1_3()); - // InternalVampireLanguage.g:4410:2: ( rule__VLSUniversalQuantifier__Group_1_3__0 )* + // InternalVampireLanguage.g:4441:2: ( rule__VLSUniversalQuantifier__Group_1_3__0 )* loop39: do { int alt39=2; @@ -13896,9 +13992,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt39) { case 1 : - // InternalVampireLanguage.g:4410:3: rule__VLSUniversalQuantifier__Group_1_3__0 + // InternalVampireLanguage.g:4441:3: rule__VLSUniversalQuantifier__Group_1_3__0 { - pushFollow(FOLLOW_33); + pushFollow(FOLLOW_34); rule__VLSUniversalQuantifier__Group_1_3__0(); state._fsp--; @@ -13935,16 +14031,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__4" - // InternalVampireLanguage.g:4418:1: rule__VLSUniversalQuantifier__Group_1__4 : rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 ; + // InternalVampireLanguage.g:4449:1: rule__VLSUniversalQuantifier__Group_1__4 : rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 ; public final void rule__VLSUniversalQuantifier__Group_1__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4422:1: ( rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 ) - // InternalVampireLanguage.g:4423:2: rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 + // InternalVampireLanguage.g:4453:1: ( rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 ) + // InternalVampireLanguage.g:4454:2: rule__VLSUniversalQuantifier__Group_1__4__Impl rule__VLSUniversalQuantifier__Group_1__5 { - pushFollow(FOLLOW_34); + pushFollow(FOLLOW_35); rule__VLSUniversalQuantifier__Group_1__4__Impl(); state._fsp--; @@ -13973,17 +14069,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__4__Impl" - // InternalVampireLanguage.g:4430:1: rule__VLSUniversalQuantifier__Group_1__4__Impl : ( ']' ) ; + // InternalVampireLanguage.g:4461:1: rule__VLSUniversalQuantifier__Group_1__4__Impl : ( ']' ) ; public final void rule__VLSUniversalQuantifier__Group_1__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4434:1: ( ( ']' ) ) - // InternalVampireLanguage.g:4435:1: ( ']' ) + // InternalVampireLanguage.g:4465:1: ( ( ']' ) ) + // InternalVampireLanguage.g:4466:1: ( ']' ) { - // InternalVampireLanguage.g:4435:1: ( ']' ) - // InternalVampireLanguage.g:4436:2: ']' + // InternalVampireLanguage.g:4466:1: ( ']' ) + // InternalVampireLanguage.g:4467:2: ']' { before(grammarAccess.getVLSUniversalQuantifierAccess().getRightSquareBracketKeyword_1_4()); match(input,50,FOLLOW_2); @@ -14010,14 +14106,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__5" - // InternalVampireLanguage.g:4445:1: rule__VLSUniversalQuantifier__Group_1__5 : rule__VLSUniversalQuantifier__Group_1__5__Impl ; + // InternalVampireLanguage.g:4476:1: rule__VLSUniversalQuantifier__Group_1__5 : rule__VLSUniversalQuantifier__Group_1__5__Impl ; public final void rule__VLSUniversalQuantifier__Group_1__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4449:1: ( rule__VLSUniversalQuantifier__Group_1__5__Impl ) - // InternalVampireLanguage.g:4450:2: rule__VLSUniversalQuantifier__Group_1__5__Impl + // InternalVampireLanguage.g:4480:1: ( rule__VLSUniversalQuantifier__Group_1__5__Impl ) + // InternalVampireLanguage.g:4481:2: rule__VLSUniversalQuantifier__Group_1__5__Impl { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__Group_1__5__Impl(); @@ -14043,17 +14139,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1__5__Impl" - // InternalVampireLanguage.g:4456:1: rule__VLSUniversalQuantifier__Group_1__5__Impl : ( ':' ) ; + // InternalVampireLanguage.g:4487:1: rule__VLSUniversalQuantifier__Group_1__5__Impl : ( ':' ) ; public final void rule__VLSUniversalQuantifier__Group_1__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4460:1: ( ( ':' ) ) - // InternalVampireLanguage.g:4461:1: ( ':' ) + // InternalVampireLanguage.g:4491:1: ( ( ':' ) ) + // InternalVampireLanguage.g:4492:1: ( ':' ) { - // InternalVampireLanguage.g:4461:1: ( ':' ) - // InternalVampireLanguage.g:4462:2: ':' + // InternalVampireLanguage.g:4492:1: ( ':' ) + // InternalVampireLanguage.g:4493:2: ':' { before(grammarAccess.getVLSUniversalQuantifierAccess().getColonKeyword_1_5()); match(input,61,FOLLOW_2); @@ -14080,16 +14176,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1_3__0" - // InternalVampireLanguage.g:4472:1: rule__VLSUniversalQuantifier__Group_1_3__0 : rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 ; + // InternalVampireLanguage.g:4503:1: rule__VLSUniversalQuantifier__Group_1_3__0 : rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 ; public final void rule__VLSUniversalQuantifier__Group_1_3__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4476:1: ( rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 ) - // InternalVampireLanguage.g:4477:2: rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 + // InternalVampireLanguage.g:4507:1: ( rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 ) + // InternalVampireLanguage.g:4508:2: rule__VLSUniversalQuantifier__Group_1_3__0__Impl rule__VLSUniversalQuantifier__Group_1_3__1 { - pushFollow(FOLLOW_50); + pushFollow(FOLLOW_51); rule__VLSUniversalQuantifier__Group_1_3__0__Impl(); state._fsp--; @@ -14118,17 +14214,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1_3__0__Impl" - // InternalVampireLanguage.g:4484:1: rule__VLSUniversalQuantifier__Group_1_3__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:4515:1: rule__VLSUniversalQuantifier__Group_1_3__0__Impl : ( ',' ) ; public final void rule__VLSUniversalQuantifier__Group_1_3__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4488:1: ( ( ',' ) ) - // InternalVampireLanguage.g:4489:1: ( ',' ) + // InternalVampireLanguage.g:4519:1: ( ( ',' ) ) + // InternalVampireLanguage.g:4520:1: ( ',' ) { - // InternalVampireLanguage.g:4489:1: ( ',' ) - // InternalVampireLanguage.g:4490:2: ',' + // InternalVampireLanguage.g:4520:1: ( ',' ) + // InternalVampireLanguage.g:4521:2: ',' { before(grammarAccess.getVLSUniversalQuantifierAccess().getCommaKeyword_1_3_0()); match(input,56,FOLLOW_2); @@ -14155,14 +14251,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1_3__1" - // InternalVampireLanguage.g:4499:1: rule__VLSUniversalQuantifier__Group_1_3__1 : rule__VLSUniversalQuantifier__Group_1_3__1__Impl ; + // InternalVampireLanguage.g:4530:1: rule__VLSUniversalQuantifier__Group_1_3__1 : rule__VLSUniversalQuantifier__Group_1_3__1__Impl ; public final void rule__VLSUniversalQuantifier__Group_1_3__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4503:1: ( rule__VLSUniversalQuantifier__Group_1_3__1__Impl ) - // InternalVampireLanguage.g:4504:2: rule__VLSUniversalQuantifier__Group_1_3__1__Impl + // InternalVampireLanguage.g:4534:1: ( rule__VLSUniversalQuantifier__Group_1_3__1__Impl ) + // InternalVampireLanguage.g:4535:2: rule__VLSUniversalQuantifier__Group_1_3__1__Impl { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__Group_1_3__1__Impl(); @@ -14188,21 +14284,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__Group_1_3__1__Impl" - // InternalVampireLanguage.g:4510:1: rule__VLSUniversalQuantifier__Group_1_3__1__Impl : ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) ; + // InternalVampireLanguage.g:4541:1: rule__VLSUniversalQuantifier__Group_1_3__1__Impl : ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) ; public final void rule__VLSUniversalQuantifier__Group_1_3__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4514:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) ) - // InternalVampireLanguage.g:4515:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) + // InternalVampireLanguage.g:4545:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) ) + // InternalVampireLanguage.g:4546:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) { - // InternalVampireLanguage.g:4515:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) - // InternalVampireLanguage.g:4516:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) + // InternalVampireLanguage.g:4546:1: ( ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) ) + // InternalVampireLanguage.g:4547:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesAssignment_1_3_1()); - // InternalVampireLanguage.g:4517:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) - // InternalVampireLanguage.g:4517:3: rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 + // InternalVampireLanguage.g:4548:2: ( rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 ) + // InternalVampireLanguage.g:4548:3: rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1(); @@ -14235,16 +14331,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__0" - // InternalVampireLanguage.g:4526:1: rule__VLSExistentialQuantifier__Group__0 : rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 ; + // InternalVampireLanguage.g:4557:1: rule__VLSExistentialQuantifier__Group__0 : rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 ; public final void rule__VLSExistentialQuantifier__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4530:1: ( rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 ) - // InternalVampireLanguage.g:4531:2: rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 + // InternalVampireLanguage.g:4561:1: ( rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 ) + // InternalVampireLanguage.g:4562:2: rule__VLSExistentialQuantifier__Group__0__Impl rule__VLSExistentialQuantifier__Group__1 { - pushFollow(FOLLOW_52); + pushFollow(FOLLOW_53); rule__VLSExistentialQuantifier__Group__0__Impl(); state._fsp--; @@ -14273,21 +14369,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__0__Impl" - // InternalVampireLanguage.g:4538:1: rule__VLSExistentialQuantifier__Group__0__Impl : ( () ) ; + // InternalVampireLanguage.g:4569:1: rule__VLSExistentialQuantifier__Group__0__Impl : ( () ) ; public final void rule__VLSExistentialQuantifier__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4542:1: ( ( () ) ) - // InternalVampireLanguage.g:4543:1: ( () ) + // InternalVampireLanguage.g:4573:1: ( ( () ) ) + // InternalVampireLanguage.g:4574:1: ( () ) { - // InternalVampireLanguage.g:4543:1: ( () ) - // InternalVampireLanguage.g:4544:2: () + // InternalVampireLanguage.g:4574:1: ( () ) + // InternalVampireLanguage.g:4575:2: () { before(grammarAccess.getVLSExistentialQuantifierAccess().getVLSExistentialQuantifierAction_0()); - // InternalVampireLanguage.g:4545:2: () - // InternalVampireLanguage.g:4545:3: + // InternalVampireLanguage.g:4576:2: () + // InternalVampireLanguage.g:4576:3: { } @@ -14310,14 +14406,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__1" - // InternalVampireLanguage.g:4553:1: rule__VLSExistentialQuantifier__Group__1 : rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 ; + // InternalVampireLanguage.g:4584:1: rule__VLSExistentialQuantifier__Group__1 : rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 ; public final void rule__VLSExistentialQuantifier__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4557:1: ( rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 ) - // InternalVampireLanguage.g:4558:2: rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 + // InternalVampireLanguage.g:4588:1: ( rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 ) + // InternalVampireLanguage.g:4589:2: rule__VLSExistentialQuantifier__Group__1__Impl rule__VLSExistentialQuantifier__Group__2 { pushFollow(FOLLOW_26); rule__VLSExistentialQuantifier__Group__1__Impl(); @@ -14348,21 +14444,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__1__Impl" - // InternalVampireLanguage.g:4565:1: rule__VLSExistentialQuantifier__Group__1__Impl : ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) ; + // InternalVampireLanguage.g:4596:1: rule__VLSExistentialQuantifier__Group__1__Impl : ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) ; public final void rule__VLSExistentialQuantifier__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4569:1: ( ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) ) - // InternalVampireLanguage.g:4570:1: ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) + // InternalVampireLanguage.g:4600:1: ( ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) ) + // InternalVampireLanguage.g:4601:1: ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) { - // InternalVampireLanguage.g:4570:1: ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) - // InternalVampireLanguage.g:4571:2: ( rule__VLSExistentialQuantifier__Group_1__0 ) + // InternalVampireLanguage.g:4601:1: ( ( rule__VLSExistentialQuantifier__Group_1__0 ) ) + // InternalVampireLanguage.g:4602:2: ( rule__VLSExistentialQuantifier__Group_1__0 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getGroup_1()); - // InternalVampireLanguage.g:4572:2: ( rule__VLSExistentialQuantifier__Group_1__0 ) - // InternalVampireLanguage.g:4572:3: rule__VLSExistentialQuantifier__Group_1__0 + // InternalVampireLanguage.g:4603:2: ( rule__VLSExistentialQuantifier__Group_1__0 ) + // InternalVampireLanguage.g:4603:3: rule__VLSExistentialQuantifier__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__Group_1__0(); @@ -14395,14 +14491,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__2" - // InternalVampireLanguage.g:4580:1: rule__VLSExistentialQuantifier__Group__2 : rule__VLSExistentialQuantifier__Group__2__Impl ; + // InternalVampireLanguage.g:4611:1: rule__VLSExistentialQuantifier__Group__2 : rule__VLSExistentialQuantifier__Group__2__Impl ; public final void rule__VLSExistentialQuantifier__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4584:1: ( rule__VLSExistentialQuantifier__Group__2__Impl ) - // InternalVampireLanguage.g:4585:2: rule__VLSExistentialQuantifier__Group__2__Impl + // InternalVampireLanguage.g:4615:1: ( rule__VLSExistentialQuantifier__Group__2__Impl ) + // InternalVampireLanguage.g:4616:2: rule__VLSExistentialQuantifier__Group__2__Impl { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__Group__2__Impl(); @@ -14428,21 +14524,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group__2__Impl" - // InternalVampireLanguage.g:4591:1: rule__VLSExistentialQuantifier__Group__2__Impl : ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) ; + // InternalVampireLanguage.g:4622:1: rule__VLSExistentialQuantifier__Group__2__Impl : ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) ; public final void rule__VLSExistentialQuantifier__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4595:1: ( ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) ) - // InternalVampireLanguage.g:4596:1: ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4626:1: ( ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) ) + // InternalVampireLanguage.g:4627:1: ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) { - // InternalVampireLanguage.g:4596:1: ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) - // InternalVampireLanguage.g:4597:2: ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) + // InternalVampireLanguage.g:4627:1: ( ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4628:2: ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getOperandAssignment_2()); - // InternalVampireLanguage.g:4598:2: ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) - // InternalVampireLanguage.g:4598:3: rule__VLSExistentialQuantifier__OperandAssignment_2 + // InternalVampireLanguage.g:4629:2: ( rule__VLSExistentialQuantifier__OperandAssignment_2 ) + // InternalVampireLanguage.g:4629:3: rule__VLSExistentialQuantifier__OperandAssignment_2 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__OperandAssignment_2(); @@ -14475,14 +14571,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__0" - // InternalVampireLanguage.g:4607:1: rule__VLSExistentialQuantifier__Group_1__0 : rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 ; + // InternalVampireLanguage.g:4638:1: rule__VLSExistentialQuantifier__Group_1__0 : rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 ; public final void rule__VLSExistentialQuantifier__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4611:1: ( rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 ) - // InternalVampireLanguage.g:4612:2: rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 + // InternalVampireLanguage.g:4642:1: ( rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 ) + // InternalVampireLanguage.g:4643:2: rule__VLSExistentialQuantifier__Group_1__0__Impl rule__VLSExistentialQuantifier__Group_1__1 { pushFollow(FOLLOW_16); rule__VLSExistentialQuantifier__Group_1__0__Impl(); @@ -14513,17 +14609,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__0__Impl" - // InternalVampireLanguage.g:4619:1: rule__VLSExistentialQuantifier__Group_1__0__Impl : ( '?' ) ; + // InternalVampireLanguage.g:4650:1: rule__VLSExistentialQuantifier__Group_1__0__Impl : ( '?' ) ; public final void rule__VLSExistentialQuantifier__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4623:1: ( ( '?' ) ) - // InternalVampireLanguage.g:4624:1: ( '?' ) + // InternalVampireLanguage.g:4654:1: ( ( '?' ) ) + // InternalVampireLanguage.g:4655:1: ( '?' ) { - // InternalVampireLanguage.g:4624:1: ( '?' ) - // InternalVampireLanguage.g:4625:2: '?' + // InternalVampireLanguage.g:4655:1: ( '?' ) + // InternalVampireLanguage.g:4656:2: '?' { before(grammarAccess.getVLSExistentialQuantifierAccess().getQuestionMarkKeyword_1_0()); match(input,73,FOLLOW_2); @@ -14550,16 +14646,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__1" - // InternalVampireLanguage.g:4634:1: rule__VLSExistentialQuantifier__Group_1__1 : rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 ; + // InternalVampireLanguage.g:4665:1: rule__VLSExistentialQuantifier__Group_1__1 : rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 ; public final void rule__VLSExistentialQuantifier__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4638:1: ( rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 ) - // InternalVampireLanguage.g:4639:2: rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 + // InternalVampireLanguage.g:4669:1: ( rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 ) + // InternalVampireLanguage.g:4670:2: rule__VLSExistentialQuantifier__Group_1__1__Impl rule__VLSExistentialQuantifier__Group_1__2 { - pushFollow(FOLLOW_50); + pushFollow(FOLLOW_51); rule__VLSExistentialQuantifier__Group_1__1__Impl(); state._fsp--; @@ -14588,17 +14684,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__1__Impl" - // InternalVampireLanguage.g:4646:1: rule__VLSExistentialQuantifier__Group_1__1__Impl : ( '[' ) ; + // InternalVampireLanguage.g:4677:1: rule__VLSExistentialQuantifier__Group_1__1__Impl : ( '[' ) ; public final void rule__VLSExistentialQuantifier__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4650:1: ( ( '[' ) ) - // InternalVampireLanguage.g:4651:1: ( '[' ) + // InternalVampireLanguage.g:4681:1: ( ( '[' ) ) + // InternalVampireLanguage.g:4682:1: ( '[' ) { - // InternalVampireLanguage.g:4651:1: ( '[' ) - // InternalVampireLanguage.g:4652:2: '[' + // InternalVampireLanguage.g:4682:1: ( '[' ) + // InternalVampireLanguage.g:4683:2: '[' { before(grammarAccess.getVLSExistentialQuantifierAccess().getLeftSquareBracketKeyword_1_1()); match(input,49,FOLLOW_2); @@ -14625,16 +14721,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__2" - // InternalVampireLanguage.g:4661:1: rule__VLSExistentialQuantifier__Group_1__2 : rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 ; + // InternalVampireLanguage.g:4692:1: rule__VLSExistentialQuantifier__Group_1__2 : rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 ; public final void rule__VLSExistentialQuantifier__Group_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4665:1: ( rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 ) - // InternalVampireLanguage.g:4666:2: rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 + // InternalVampireLanguage.g:4696:1: ( rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 ) + // InternalVampireLanguage.g:4697:2: rule__VLSExistentialQuantifier__Group_1__2__Impl rule__VLSExistentialQuantifier__Group_1__3 { - pushFollow(FOLLOW_51); + pushFollow(FOLLOW_52); rule__VLSExistentialQuantifier__Group_1__2__Impl(); state._fsp--; @@ -14663,21 +14759,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__2__Impl" - // InternalVampireLanguage.g:4673:1: rule__VLSExistentialQuantifier__Group_1__2__Impl : ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) ; + // InternalVampireLanguage.g:4704:1: rule__VLSExistentialQuantifier__Group_1__2__Impl : ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) ; public final void rule__VLSExistentialQuantifier__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4677:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) ) - // InternalVampireLanguage.g:4678:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) + // InternalVampireLanguage.g:4708:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) ) + // InternalVampireLanguage.g:4709:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) { - // InternalVampireLanguage.g:4678:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) - // InternalVampireLanguage.g:4679:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) + // InternalVampireLanguage.g:4709:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) ) + // InternalVampireLanguage.g:4710:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesAssignment_1_2()); - // InternalVampireLanguage.g:4680:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) - // InternalVampireLanguage.g:4680:3: rule__VLSExistentialQuantifier__VariablesAssignment_1_2 + // InternalVampireLanguage.g:4711:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_2 ) + // InternalVampireLanguage.g:4711:3: rule__VLSExistentialQuantifier__VariablesAssignment_1_2 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__VariablesAssignment_1_2(); @@ -14710,16 +14806,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__3" - // InternalVampireLanguage.g:4688:1: rule__VLSExistentialQuantifier__Group_1__3 : rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 ; + // InternalVampireLanguage.g:4719:1: rule__VLSExistentialQuantifier__Group_1__3 : rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 ; public final void rule__VLSExistentialQuantifier__Group_1__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4692:1: ( rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 ) - // InternalVampireLanguage.g:4693:2: rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 + // InternalVampireLanguage.g:4723:1: ( rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 ) + // InternalVampireLanguage.g:4724:2: rule__VLSExistentialQuantifier__Group_1__3__Impl rule__VLSExistentialQuantifier__Group_1__4 { - pushFollow(FOLLOW_51); + pushFollow(FOLLOW_52); rule__VLSExistentialQuantifier__Group_1__3__Impl(); state._fsp--; @@ -14748,20 +14844,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__3__Impl" - // InternalVampireLanguage.g:4700:1: rule__VLSExistentialQuantifier__Group_1__3__Impl : ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) ; + // InternalVampireLanguage.g:4731:1: rule__VLSExistentialQuantifier__Group_1__3__Impl : ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) ; public final void rule__VLSExistentialQuantifier__Group_1__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4704:1: ( ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) ) - // InternalVampireLanguage.g:4705:1: ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) + // InternalVampireLanguage.g:4735:1: ( ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) ) + // InternalVampireLanguage.g:4736:1: ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) { - // InternalVampireLanguage.g:4705:1: ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) - // InternalVampireLanguage.g:4706:2: ( rule__VLSExistentialQuantifier__Group_1_3__0 )* + // InternalVampireLanguage.g:4736:1: ( ( rule__VLSExistentialQuantifier__Group_1_3__0 )* ) + // InternalVampireLanguage.g:4737:2: ( rule__VLSExistentialQuantifier__Group_1_3__0 )* { before(grammarAccess.getVLSExistentialQuantifierAccess().getGroup_1_3()); - // InternalVampireLanguage.g:4707:2: ( rule__VLSExistentialQuantifier__Group_1_3__0 )* + // InternalVampireLanguage.g:4738:2: ( rule__VLSExistentialQuantifier__Group_1_3__0 )* loop40: do { int alt40=2; @@ -14774,9 +14870,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt40) { case 1 : - // InternalVampireLanguage.g:4707:3: rule__VLSExistentialQuantifier__Group_1_3__0 + // InternalVampireLanguage.g:4738:3: rule__VLSExistentialQuantifier__Group_1_3__0 { - pushFollow(FOLLOW_33); + pushFollow(FOLLOW_34); rule__VLSExistentialQuantifier__Group_1_3__0(); state._fsp--; @@ -14813,16 +14909,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__4" - // InternalVampireLanguage.g:4715:1: rule__VLSExistentialQuantifier__Group_1__4 : rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 ; + // InternalVampireLanguage.g:4746:1: rule__VLSExistentialQuantifier__Group_1__4 : rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 ; public final void rule__VLSExistentialQuantifier__Group_1__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4719:1: ( rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 ) - // InternalVampireLanguage.g:4720:2: rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 + // InternalVampireLanguage.g:4750:1: ( rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 ) + // InternalVampireLanguage.g:4751:2: rule__VLSExistentialQuantifier__Group_1__4__Impl rule__VLSExistentialQuantifier__Group_1__5 { - pushFollow(FOLLOW_34); + pushFollow(FOLLOW_35); rule__VLSExistentialQuantifier__Group_1__4__Impl(); state._fsp--; @@ -14851,17 +14947,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__4__Impl" - // InternalVampireLanguage.g:4727:1: rule__VLSExistentialQuantifier__Group_1__4__Impl : ( ']' ) ; + // InternalVampireLanguage.g:4758:1: rule__VLSExistentialQuantifier__Group_1__4__Impl : ( ']' ) ; public final void rule__VLSExistentialQuantifier__Group_1__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4731:1: ( ( ']' ) ) - // InternalVampireLanguage.g:4732:1: ( ']' ) + // InternalVampireLanguage.g:4762:1: ( ( ']' ) ) + // InternalVampireLanguage.g:4763:1: ( ']' ) { - // InternalVampireLanguage.g:4732:1: ( ']' ) - // InternalVampireLanguage.g:4733:2: ']' + // InternalVampireLanguage.g:4763:1: ( ']' ) + // InternalVampireLanguage.g:4764:2: ']' { before(grammarAccess.getVLSExistentialQuantifierAccess().getRightSquareBracketKeyword_1_4()); match(input,50,FOLLOW_2); @@ -14888,14 +14984,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__5" - // InternalVampireLanguage.g:4742:1: rule__VLSExistentialQuantifier__Group_1__5 : rule__VLSExistentialQuantifier__Group_1__5__Impl ; + // InternalVampireLanguage.g:4773:1: rule__VLSExistentialQuantifier__Group_1__5 : rule__VLSExistentialQuantifier__Group_1__5__Impl ; public final void rule__VLSExistentialQuantifier__Group_1__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4746:1: ( rule__VLSExistentialQuantifier__Group_1__5__Impl ) - // InternalVampireLanguage.g:4747:2: rule__VLSExistentialQuantifier__Group_1__5__Impl + // InternalVampireLanguage.g:4777:1: ( rule__VLSExistentialQuantifier__Group_1__5__Impl ) + // InternalVampireLanguage.g:4778:2: rule__VLSExistentialQuantifier__Group_1__5__Impl { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__Group_1__5__Impl(); @@ -14921,17 +15017,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1__5__Impl" - // InternalVampireLanguage.g:4753:1: rule__VLSExistentialQuantifier__Group_1__5__Impl : ( ':' ) ; + // InternalVampireLanguage.g:4784:1: rule__VLSExistentialQuantifier__Group_1__5__Impl : ( ':' ) ; public final void rule__VLSExistentialQuantifier__Group_1__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4757:1: ( ( ':' ) ) - // InternalVampireLanguage.g:4758:1: ( ':' ) + // InternalVampireLanguage.g:4788:1: ( ( ':' ) ) + // InternalVampireLanguage.g:4789:1: ( ':' ) { - // InternalVampireLanguage.g:4758:1: ( ':' ) - // InternalVampireLanguage.g:4759:2: ':' + // InternalVampireLanguage.g:4789:1: ( ':' ) + // InternalVampireLanguage.g:4790:2: ':' { before(grammarAccess.getVLSExistentialQuantifierAccess().getColonKeyword_1_5()); match(input,61,FOLLOW_2); @@ -14958,16 +15054,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1_3__0" - // InternalVampireLanguage.g:4769:1: rule__VLSExistentialQuantifier__Group_1_3__0 : rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 ; + // InternalVampireLanguage.g:4800:1: rule__VLSExistentialQuantifier__Group_1_3__0 : rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 ; public final void rule__VLSExistentialQuantifier__Group_1_3__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4773:1: ( rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 ) - // InternalVampireLanguage.g:4774:2: rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 + // InternalVampireLanguage.g:4804:1: ( rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 ) + // InternalVampireLanguage.g:4805:2: rule__VLSExistentialQuantifier__Group_1_3__0__Impl rule__VLSExistentialQuantifier__Group_1_3__1 { - pushFollow(FOLLOW_50); + pushFollow(FOLLOW_51); rule__VLSExistentialQuantifier__Group_1_3__0__Impl(); state._fsp--; @@ -14996,17 +15092,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1_3__0__Impl" - // InternalVampireLanguage.g:4781:1: rule__VLSExistentialQuantifier__Group_1_3__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:4812:1: rule__VLSExistentialQuantifier__Group_1_3__0__Impl : ( ',' ) ; public final void rule__VLSExistentialQuantifier__Group_1_3__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4785:1: ( ( ',' ) ) - // InternalVampireLanguage.g:4786:1: ( ',' ) + // InternalVampireLanguage.g:4816:1: ( ( ',' ) ) + // InternalVampireLanguage.g:4817:1: ( ',' ) { - // InternalVampireLanguage.g:4786:1: ( ',' ) - // InternalVampireLanguage.g:4787:2: ',' + // InternalVampireLanguage.g:4817:1: ( ',' ) + // InternalVampireLanguage.g:4818:2: ',' { before(grammarAccess.getVLSExistentialQuantifierAccess().getCommaKeyword_1_3_0()); match(input,56,FOLLOW_2); @@ -15033,14 +15129,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1_3__1" - // InternalVampireLanguage.g:4796:1: rule__VLSExistentialQuantifier__Group_1_3__1 : rule__VLSExistentialQuantifier__Group_1_3__1__Impl ; + // InternalVampireLanguage.g:4827:1: rule__VLSExistentialQuantifier__Group_1_3__1 : rule__VLSExistentialQuantifier__Group_1_3__1__Impl ; public final void rule__VLSExistentialQuantifier__Group_1_3__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4800:1: ( rule__VLSExistentialQuantifier__Group_1_3__1__Impl ) - // InternalVampireLanguage.g:4801:2: rule__VLSExistentialQuantifier__Group_1_3__1__Impl + // InternalVampireLanguage.g:4831:1: ( rule__VLSExistentialQuantifier__Group_1_3__1__Impl ) + // InternalVampireLanguage.g:4832:2: rule__VLSExistentialQuantifier__Group_1_3__1__Impl { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__Group_1_3__1__Impl(); @@ -15066,21 +15162,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__Group_1_3__1__Impl" - // InternalVampireLanguage.g:4807:1: rule__VLSExistentialQuantifier__Group_1_3__1__Impl : ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) ; + // InternalVampireLanguage.g:4838:1: rule__VLSExistentialQuantifier__Group_1_3__1__Impl : ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) ; public final void rule__VLSExistentialQuantifier__Group_1_3__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4811:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) ) - // InternalVampireLanguage.g:4812:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) + // InternalVampireLanguage.g:4842:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) ) + // InternalVampireLanguage.g:4843:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) { - // InternalVampireLanguage.g:4812:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) - // InternalVampireLanguage.g:4813:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) + // InternalVampireLanguage.g:4843:1: ( ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) ) + // InternalVampireLanguage.g:4844:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesAssignment_1_3_1()); - // InternalVampireLanguage.g:4814:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) - // InternalVampireLanguage.g:4814:3: rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 + // InternalVampireLanguage.g:4845:2: ( rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 ) + // InternalVampireLanguage.g:4845:3: rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1(); @@ -15113,16 +15209,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__0" - // InternalVampireLanguage.g:4823:1: rule__VLSUnaryNegation__Group__0 : rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 ; + // InternalVampireLanguage.g:4854:1: rule__VLSUnaryNegation__Group__0 : rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 ; public final void rule__VLSUnaryNegation__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4827:1: ( rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 ) - // InternalVampireLanguage.g:4828:2: rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 + // InternalVampireLanguage.g:4858:1: ( rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 ) + // InternalVampireLanguage.g:4859:2: rule__VLSUnaryNegation__Group__0__Impl rule__VLSUnaryNegation__Group__1 { - pushFollow(FOLLOW_53); + pushFollow(FOLLOW_54); rule__VLSUnaryNegation__Group__0__Impl(); state._fsp--; @@ -15151,21 +15247,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__0__Impl" - // InternalVampireLanguage.g:4835:1: rule__VLSUnaryNegation__Group__0__Impl : ( () ) ; + // InternalVampireLanguage.g:4866:1: rule__VLSUnaryNegation__Group__0__Impl : ( () ) ; public final void rule__VLSUnaryNegation__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4839:1: ( ( () ) ) - // InternalVampireLanguage.g:4840:1: ( () ) + // InternalVampireLanguage.g:4870:1: ( ( () ) ) + // InternalVampireLanguage.g:4871:1: ( () ) { - // InternalVampireLanguage.g:4840:1: ( () ) - // InternalVampireLanguage.g:4841:2: () + // InternalVampireLanguage.g:4871:1: ( () ) + // InternalVampireLanguage.g:4872:2: () { before(grammarAccess.getVLSUnaryNegationAccess().getVLSUnaryNegationAction_0()); - // InternalVampireLanguage.g:4842:2: () - // InternalVampireLanguage.g:4842:3: + // InternalVampireLanguage.g:4873:2: () + // InternalVampireLanguage.g:4873:3: { } @@ -15188,14 +15284,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__1" - // InternalVampireLanguage.g:4850:1: rule__VLSUnaryNegation__Group__1 : rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 ; + // InternalVampireLanguage.g:4881:1: rule__VLSUnaryNegation__Group__1 : rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 ; public final void rule__VLSUnaryNegation__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4854:1: ( rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 ) - // InternalVampireLanguage.g:4855:2: rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 + // InternalVampireLanguage.g:4885:1: ( rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 ) + // InternalVampireLanguage.g:4886:2: rule__VLSUnaryNegation__Group__1__Impl rule__VLSUnaryNegation__Group__2 { pushFollow(FOLLOW_26); rule__VLSUnaryNegation__Group__1__Impl(); @@ -15226,17 +15322,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__1__Impl" - // InternalVampireLanguage.g:4862:1: rule__VLSUnaryNegation__Group__1__Impl : ( '~' ) ; + // InternalVampireLanguage.g:4893:1: rule__VLSUnaryNegation__Group__1__Impl : ( '~' ) ; public final void rule__VLSUnaryNegation__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4866:1: ( ( '~' ) ) - // InternalVampireLanguage.g:4867:1: ( '~' ) + // InternalVampireLanguage.g:4897:1: ( ( '~' ) ) + // InternalVampireLanguage.g:4898:1: ( '~' ) { - // InternalVampireLanguage.g:4867:1: ( '~' ) - // InternalVampireLanguage.g:4868:2: '~' + // InternalVampireLanguage.g:4898:1: ( '~' ) + // InternalVampireLanguage.g:4899:2: '~' { before(grammarAccess.getVLSUnaryNegationAccess().getTildeKeyword_1()); match(input,74,FOLLOW_2); @@ -15263,14 +15359,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__2" - // InternalVampireLanguage.g:4877:1: rule__VLSUnaryNegation__Group__2 : rule__VLSUnaryNegation__Group__2__Impl ; + // InternalVampireLanguage.g:4908:1: rule__VLSUnaryNegation__Group__2 : rule__VLSUnaryNegation__Group__2__Impl ; public final void rule__VLSUnaryNegation__Group__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4881:1: ( rule__VLSUnaryNegation__Group__2__Impl ) - // InternalVampireLanguage.g:4882:2: rule__VLSUnaryNegation__Group__2__Impl + // InternalVampireLanguage.g:4912:1: ( rule__VLSUnaryNegation__Group__2__Impl ) + // InternalVampireLanguage.g:4913:2: rule__VLSUnaryNegation__Group__2__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryNegation__Group__2__Impl(); @@ -15296,21 +15392,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__Group__2__Impl" - // InternalVampireLanguage.g:4888:1: rule__VLSUnaryNegation__Group__2__Impl : ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) ; + // InternalVampireLanguage.g:4919:1: rule__VLSUnaryNegation__Group__2__Impl : ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) ; public final void rule__VLSUnaryNegation__Group__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4892:1: ( ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) ) - // InternalVampireLanguage.g:4893:1: ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4923:1: ( ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) ) + // InternalVampireLanguage.g:4924:1: ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) { - // InternalVampireLanguage.g:4893:1: ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) - // InternalVampireLanguage.g:4894:2: ( rule__VLSUnaryNegation__OperandAssignment_2 ) + // InternalVampireLanguage.g:4924:1: ( ( rule__VLSUnaryNegation__OperandAssignment_2 ) ) + // InternalVampireLanguage.g:4925:2: ( rule__VLSUnaryNegation__OperandAssignment_2 ) { before(grammarAccess.getVLSUnaryNegationAccess().getOperandAssignment_2()); - // InternalVampireLanguage.g:4895:2: ( rule__VLSUnaryNegation__OperandAssignment_2 ) - // InternalVampireLanguage.g:4895:3: rule__VLSUnaryNegation__OperandAssignment_2 + // InternalVampireLanguage.g:4926:2: ( rule__VLSUnaryNegation__OperandAssignment_2 ) + // InternalVampireLanguage.g:4926:3: rule__VLSUnaryNegation__OperandAssignment_2 { pushFollow(FOLLOW_2); rule__VLSUnaryNegation__OperandAssignment_2(); @@ -15343,16 +15439,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group__0" - // InternalVampireLanguage.g:4904:1: rule__VLSUnaryInfix__Group__0 : rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 ; + // InternalVampireLanguage.g:4935:1: rule__VLSUnaryInfix__Group__0 : rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 ; public final void rule__VLSUnaryInfix__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4908:1: ( rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 ) - // InternalVampireLanguage.g:4909:2: rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 + // InternalVampireLanguage.g:4939:1: ( rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 ) + // InternalVampireLanguage.g:4940:2: rule__VLSUnaryInfix__Group__0__Impl rule__VLSUnaryInfix__Group__1 { - pushFollow(FOLLOW_54); + pushFollow(FOLLOW_55); rule__VLSUnaryInfix__Group__0__Impl(); state._fsp--; @@ -15381,17 +15477,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group__0__Impl" - // InternalVampireLanguage.g:4916:1: rule__VLSUnaryInfix__Group__0__Impl : ( ruleVLSAtomic ) ; + // InternalVampireLanguage.g:4947:1: rule__VLSUnaryInfix__Group__0__Impl : ( ruleVLSAtomic ) ; public final void rule__VLSUnaryInfix__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4920:1: ( ( ruleVLSAtomic ) ) - // InternalVampireLanguage.g:4921:1: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:4951:1: ( ( ruleVLSAtomic ) ) + // InternalVampireLanguage.g:4952:1: ( ruleVLSAtomic ) { - // InternalVampireLanguage.g:4921:1: ( ruleVLSAtomic ) - // InternalVampireLanguage.g:4922:2: ruleVLSAtomic + // InternalVampireLanguage.g:4952:1: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:4953:2: ruleVLSAtomic { before(grammarAccess.getVLSUnaryInfixAccess().getVLSAtomicParserRuleCall_0()); pushFollow(FOLLOW_2); @@ -15422,14 +15518,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group__1" - // InternalVampireLanguage.g:4931:1: rule__VLSUnaryInfix__Group__1 : rule__VLSUnaryInfix__Group__1__Impl ; + // InternalVampireLanguage.g:4962:1: rule__VLSUnaryInfix__Group__1 : rule__VLSUnaryInfix__Group__1__Impl ; public final void rule__VLSUnaryInfix__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4935:1: ( rule__VLSUnaryInfix__Group__1__Impl ) - // InternalVampireLanguage.g:4936:2: rule__VLSUnaryInfix__Group__1__Impl + // InternalVampireLanguage.g:4966:1: ( rule__VLSUnaryInfix__Group__1__Impl ) + // InternalVampireLanguage.g:4967:2: rule__VLSUnaryInfix__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group__1__Impl(); @@ -15455,20 +15551,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group__1__Impl" - // InternalVampireLanguage.g:4942:1: rule__VLSUnaryInfix__Group__1__Impl : ( ( rule__VLSUnaryInfix__Group_1__0 )? ) ; + // InternalVampireLanguage.g:4973:1: rule__VLSUnaryInfix__Group__1__Impl : ( ( rule__VLSUnaryInfix__Group_1__0 )? ) ; public final void rule__VLSUnaryInfix__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4946:1: ( ( ( rule__VLSUnaryInfix__Group_1__0 )? ) ) - // InternalVampireLanguage.g:4947:1: ( ( rule__VLSUnaryInfix__Group_1__0 )? ) + // InternalVampireLanguage.g:4977:1: ( ( ( rule__VLSUnaryInfix__Group_1__0 )? ) ) + // InternalVampireLanguage.g:4978:1: ( ( rule__VLSUnaryInfix__Group_1__0 )? ) { - // InternalVampireLanguage.g:4947:1: ( ( rule__VLSUnaryInfix__Group_1__0 )? ) - // InternalVampireLanguage.g:4948:2: ( rule__VLSUnaryInfix__Group_1__0 )? + // InternalVampireLanguage.g:4978:1: ( ( rule__VLSUnaryInfix__Group_1__0 )? ) + // InternalVampireLanguage.g:4979:2: ( rule__VLSUnaryInfix__Group_1__0 )? { before(grammarAccess.getVLSUnaryInfixAccess().getGroup_1()); - // InternalVampireLanguage.g:4949:2: ( rule__VLSUnaryInfix__Group_1__0 )? + // InternalVampireLanguage.g:4980:2: ( rule__VLSUnaryInfix__Group_1__0 )? int alt41=2; int LA41_0 = input.LA(1); @@ -15477,7 +15573,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt41) { case 1 : - // InternalVampireLanguage.g:4949:3: rule__VLSUnaryInfix__Group_1__0 + // InternalVampireLanguage.g:4980:3: rule__VLSUnaryInfix__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1__0(); @@ -15513,16 +15609,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1__0" - // InternalVampireLanguage.g:4958:1: rule__VLSUnaryInfix__Group_1__0 : rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 ; + // InternalVampireLanguage.g:4989:1: rule__VLSUnaryInfix__Group_1__0 : rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 ; public final void rule__VLSUnaryInfix__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4962:1: ( rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 ) - // InternalVampireLanguage.g:4963:2: rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 + // InternalVampireLanguage.g:4993:1: ( rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 ) + // InternalVampireLanguage.g:4994:2: rule__VLSUnaryInfix__Group_1__0__Impl rule__VLSUnaryInfix__Group_1__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSUnaryInfix__Group_1__0__Impl(); state._fsp--; @@ -15551,21 +15647,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1__0__Impl" - // InternalVampireLanguage.g:4970:1: rule__VLSUnaryInfix__Group_1__0__Impl : ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) ; + // InternalVampireLanguage.g:5001:1: rule__VLSUnaryInfix__Group_1__0__Impl : ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) ; public final void rule__VLSUnaryInfix__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4974:1: ( ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) ) - // InternalVampireLanguage.g:4975:1: ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) + // InternalVampireLanguage.g:5005:1: ( ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) ) + // InternalVampireLanguage.g:5006:1: ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) { - // InternalVampireLanguage.g:4975:1: ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) - // InternalVampireLanguage.g:4976:2: ( rule__VLSUnaryInfix__Alternatives_1_0 ) + // InternalVampireLanguage.g:5006:1: ( ( rule__VLSUnaryInfix__Alternatives_1_0 ) ) + // InternalVampireLanguage.g:5007:2: ( rule__VLSUnaryInfix__Alternatives_1_0 ) { before(grammarAccess.getVLSUnaryInfixAccess().getAlternatives_1_0()); - // InternalVampireLanguage.g:4977:2: ( rule__VLSUnaryInfix__Alternatives_1_0 ) - // InternalVampireLanguage.g:4977:3: rule__VLSUnaryInfix__Alternatives_1_0 + // InternalVampireLanguage.g:5008:2: ( rule__VLSUnaryInfix__Alternatives_1_0 ) + // InternalVampireLanguage.g:5008:3: rule__VLSUnaryInfix__Alternatives_1_0 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Alternatives_1_0(); @@ -15598,14 +15694,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1__1" - // InternalVampireLanguage.g:4985:1: rule__VLSUnaryInfix__Group_1__1 : rule__VLSUnaryInfix__Group_1__1__Impl ; + // InternalVampireLanguage.g:5016:1: rule__VLSUnaryInfix__Group_1__1 : rule__VLSUnaryInfix__Group_1__1__Impl ; public final void rule__VLSUnaryInfix__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:4989:1: ( rule__VLSUnaryInfix__Group_1__1__Impl ) - // InternalVampireLanguage.g:4990:2: rule__VLSUnaryInfix__Group_1__1__Impl + // InternalVampireLanguage.g:5020:1: ( rule__VLSUnaryInfix__Group_1__1__Impl ) + // InternalVampireLanguage.g:5021:2: rule__VLSUnaryInfix__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1__1__Impl(); @@ -15631,21 +15727,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1__1__Impl" - // InternalVampireLanguage.g:4996:1: rule__VLSUnaryInfix__Group_1__1__Impl : ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:5027:1: rule__VLSUnaryInfix__Group_1__1__Impl : ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) ; public final void rule__VLSUnaryInfix__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5000:1: ( ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:5001:1: ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) + // InternalVampireLanguage.g:5031:1: ( ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:5032:1: ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) { - // InternalVampireLanguage.g:5001:1: ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) - // InternalVampireLanguage.g:5002:2: ( rule__VLSUnaryInfix__RightAssignment_1_1 ) + // InternalVampireLanguage.g:5032:1: ( ( rule__VLSUnaryInfix__RightAssignment_1_1 ) ) + // InternalVampireLanguage.g:5033:2: ( rule__VLSUnaryInfix__RightAssignment_1_1 ) { before(grammarAccess.getVLSUnaryInfixAccess().getRightAssignment_1_1()); - // InternalVampireLanguage.g:5003:2: ( rule__VLSUnaryInfix__RightAssignment_1_1 ) - // InternalVampireLanguage.g:5003:3: rule__VLSUnaryInfix__RightAssignment_1_1 + // InternalVampireLanguage.g:5034:2: ( rule__VLSUnaryInfix__RightAssignment_1_1 ) + // InternalVampireLanguage.g:5034:3: rule__VLSUnaryInfix__RightAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__RightAssignment_1_1(); @@ -15678,16 +15774,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_0__0" - // InternalVampireLanguage.g:5012:1: rule__VLSUnaryInfix__Group_1_0_0__0 : rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 ; + // InternalVampireLanguage.g:5043:1: rule__VLSUnaryInfix__Group_1_0_0__0 : rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 ; public final void rule__VLSUnaryInfix__Group_1_0_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5016:1: ( rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 ) - // InternalVampireLanguage.g:5017:2: rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 + // InternalVampireLanguage.g:5047:1: ( rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 ) + // InternalVampireLanguage.g:5048:2: rule__VLSUnaryInfix__Group_1_0_0__0__Impl rule__VLSUnaryInfix__Group_1_0_0__1 { - pushFollow(FOLLOW_55); + pushFollow(FOLLOW_56); rule__VLSUnaryInfix__Group_1_0_0__0__Impl(); state._fsp--; @@ -15716,21 +15812,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_0__0__Impl" - // InternalVampireLanguage.g:5024:1: rule__VLSUnaryInfix__Group_1_0_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5055:1: rule__VLSUnaryInfix__Group_1_0_0__0__Impl : ( () ) ; public final void rule__VLSUnaryInfix__Group_1_0_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5028:1: ( ( () ) ) - // InternalVampireLanguage.g:5029:1: ( () ) + // InternalVampireLanguage.g:5059:1: ( ( () ) ) + // InternalVampireLanguage.g:5060:1: ( () ) { - // InternalVampireLanguage.g:5029:1: ( () ) - // InternalVampireLanguage.g:5030:2: () + // InternalVampireLanguage.g:5060:1: ( () ) + // InternalVampireLanguage.g:5061:2: () { before(grammarAccess.getVLSUnaryInfixAccess().getVLSInequalityLeftAction_1_0_0_0()); - // InternalVampireLanguage.g:5031:2: () - // InternalVampireLanguage.g:5031:3: + // InternalVampireLanguage.g:5062:2: () + // InternalVampireLanguage.g:5062:3: { } @@ -15753,14 +15849,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_0__1" - // InternalVampireLanguage.g:5039:1: rule__VLSUnaryInfix__Group_1_0_0__1 : rule__VLSUnaryInfix__Group_1_0_0__1__Impl ; + // InternalVampireLanguage.g:5070:1: rule__VLSUnaryInfix__Group_1_0_0__1 : rule__VLSUnaryInfix__Group_1_0_0__1__Impl ; public final void rule__VLSUnaryInfix__Group_1_0_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5043:1: ( rule__VLSUnaryInfix__Group_1_0_0__1__Impl ) - // InternalVampireLanguage.g:5044:2: rule__VLSUnaryInfix__Group_1_0_0__1__Impl + // InternalVampireLanguage.g:5074:1: ( rule__VLSUnaryInfix__Group_1_0_0__1__Impl ) + // InternalVampireLanguage.g:5075:2: rule__VLSUnaryInfix__Group_1_0_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_0__1__Impl(); @@ -15786,17 +15882,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_0__1__Impl" - // InternalVampireLanguage.g:5050:1: rule__VLSUnaryInfix__Group_1_0_0__1__Impl : ( '!=' ) ; + // InternalVampireLanguage.g:5081:1: rule__VLSUnaryInfix__Group_1_0_0__1__Impl : ( '!=' ) ; public final void rule__VLSUnaryInfix__Group_1_0_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5054:1: ( ( '!=' ) ) - // InternalVampireLanguage.g:5055:1: ( '!=' ) + // InternalVampireLanguage.g:5085:1: ( ( '!=' ) ) + // InternalVampireLanguage.g:5086:1: ( '!=' ) { - // InternalVampireLanguage.g:5055:1: ( '!=' ) - // InternalVampireLanguage.g:5056:2: '!=' + // InternalVampireLanguage.g:5086:1: ( '!=' ) + // InternalVampireLanguage.g:5087:2: '!=' { before(grammarAccess.getVLSUnaryInfixAccess().getExclamationMarkEqualsSignKeyword_1_0_0_1()); match(input,75,FOLLOW_2); @@ -15823,16 +15919,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_1__0" - // InternalVampireLanguage.g:5066:1: rule__VLSUnaryInfix__Group_1_0_1__0 : rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 ; + // InternalVampireLanguage.g:5097:1: rule__VLSUnaryInfix__Group_1_0_1__0 : rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 ; public final void rule__VLSUnaryInfix__Group_1_0_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5070:1: ( rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 ) - // InternalVampireLanguage.g:5071:2: rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 + // InternalVampireLanguage.g:5101:1: ( rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 ) + // InternalVampireLanguage.g:5102:2: rule__VLSUnaryInfix__Group_1_0_1__0__Impl rule__VLSUnaryInfix__Group_1_0_1__1 { - pushFollow(FOLLOW_56); + pushFollow(FOLLOW_57); rule__VLSUnaryInfix__Group_1_0_1__0__Impl(); state._fsp--; @@ -15861,21 +15957,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_1__0__Impl" - // InternalVampireLanguage.g:5078:1: rule__VLSUnaryInfix__Group_1_0_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5109:1: rule__VLSUnaryInfix__Group_1_0_1__0__Impl : ( () ) ; public final void rule__VLSUnaryInfix__Group_1_0_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5082:1: ( ( () ) ) - // InternalVampireLanguage.g:5083:1: ( () ) + // InternalVampireLanguage.g:5113:1: ( ( () ) ) + // InternalVampireLanguage.g:5114:1: ( () ) { - // InternalVampireLanguage.g:5083:1: ( () ) - // InternalVampireLanguage.g:5084:2: () + // InternalVampireLanguage.g:5114:1: ( () ) + // InternalVampireLanguage.g:5115:2: () { before(grammarAccess.getVLSUnaryInfixAccess().getVLSEqualityLeftAction_1_0_1_0()); - // InternalVampireLanguage.g:5085:2: () - // InternalVampireLanguage.g:5085:3: + // InternalVampireLanguage.g:5116:2: () + // InternalVampireLanguage.g:5116:3: { } @@ -15898,14 +15994,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_1__1" - // InternalVampireLanguage.g:5093:1: rule__VLSUnaryInfix__Group_1_0_1__1 : rule__VLSUnaryInfix__Group_1_0_1__1__Impl ; + // InternalVampireLanguage.g:5124:1: rule__VLSUnaryInfix__Group_1_0_1__1 : rule__VLSUnaryInfix__Group_1_0_1__1__Impl ; public final void rule__VLSUnaryInfix__Group_1_0_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5097:1: ( rule__VLSUnaryInfix__Group_1_0_1__1__Impl ) - // InternalVampireLanguage.g:5098:2: rule__VLSUnaryInfix__Group_1_0_1__1__Impl + // InternalVampireLanguage.g:5128:1: ( rule__VLSUnaryInfix__Group_1_0_1__1__Impl ) + // InternalVampireLanguage.g:5129:2: rule__VLSUnaryInfix__Group_1_0_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_1__1__Impl(); @@ -15931,17 +16027,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_1__1__Impl" - // InternalVampireLanguage.g:5104:1: rule__VLSUnaryInfix__Group_1_0_1__1__Impl : ( '=' ) ; + // InternalVampireLanguage.g:5135:1: rule__VLSUnaryInfix__Group_1_0_1__1__Impl : ( '=' ) ; public final void rule__VLSUnaryInfix__Group_1_0_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5108:1: ( ( '=' ) ) - // InternalVampireLanguage.g:5109:1: ( '=' ) + // InternalVampireLanguage.g:5139:1: ( ( '=' ) ) + // InternalVampireLanguage.g:5140:1: ( '=' ) { - // InternalVampireLanguage.g:5109:1: ( '=' ) - // InternalVampireLanguage.g:5110:2: '=' + // InternalVampireLanguage.g:5140:1: ( '=' ) + // InternalVampireLanguage.g:5141:2: '=' { before(grammarAccess.getVLSUnaryInfixAccess().getEqualsSignKeyword_1_0_1_1()); match(input,76,FOLLOW_2); @@ -15968,16 +16064,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_2__0" - // InternalVampireLanguage.g:5120:1: rule__VLSUnaryInfix__Group_1_0_2__0 : rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 ; + // InternalVampireLanguage.g:5151:1: rule__VLSUnaryInfix__Group_1_0_2__0 : rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 ; public final void rule__VLSUnaryInfix__Group_1_0_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5124:1: ( rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 ) - // InternalVampireLanguage.g:5125:2: rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 + // InternalVampireLanguage.g:5155:1: ( rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 ) + // InternalVampireLanguage.g:5156:2: rule__VLSUnaryInfix__Group_1_0_2__0__Impl rule__VLSUnaryInfix__Group_1_0_2__1 { - pushFollow(FOLLOW_54); + pushFollow(FOLLOW_55); rule__VLSUnaryInfix__Group_1_0_2__0__Impl(); state._fsp--; @@ -16006,21 +16102,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_2__0__Impl" - // InternalVampireLanguage.g:5132:1: rule__VLSUnaryInfix__Group_1_0_2__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5163:1: rule__VLSUnaryInfix__Group_1_0_2__0__Impl : ( () ) ; public final void rule__VLSUnaryInfix__Group_1_0_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5136:1: ( ( () ) ) - // InternalVampireLanguage.g:5137:1: ( () ) + // InternalVampireLanguage.g:5167:1: ( ( () ) ) + // InternalVampireLanguage.g:5168:1: ( () ) { - // InternalVampireLanguage.g:5137:1: ( () ) - // InternalVampireLanguage.g:5138:2: () + // InternalVampireLanguage.g:5168:1: ( () ) + // InternalVampireLanguage.g:5169:2: () { before(grammarAccess.getVLSUnaryInfixAccess().getVLSAssignmentLeftAction_1_0_2_0()); - // InternalVampireLanguage.g:5139:2: () - // InternalVampireLanguage.g:5139:3: + // InternalVampireLanguage.g:5170:2: () + // InternalVampireLanguage.g:5170:3: { } @@ -16043,14 +16139,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_2__1" - // InternalVampireLanguage.g:5147:1: rule__VLSUnaryInfix__Group_1_0_2__1 : rule__VLSUnaryInfix__Group_1_0_2__1__Impl ; + // InternalVampireLanguage.g:5178:1: rule__VLSUnaryInfix__Group_1_0_2__1 : rule__VLSUnaryInfix__Group_1_0_2__1__Impl ; public final void rule__VLSUnaryInfix__Group_1_0_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5151:1: ( rule__VLSUnaryInfix__Group_1_0_2__1__Impl ) - // InternalVampireLanguage.g:5152:2: rule__VLSUnaryInfix__Group_1_0_2__1__Impl + // InternalVampireLanguage.g:5182:1: ( rule__VLSUnaryInfix__Group_1_0_2__1__Impl ) + // InternalVampireLanguage.g:5183:2: rule__VLSUnaryInfix__Group_1_0_2__1__Impl { pushFollow(FOLLOW_2); rule__VLSUnaryInfix__Group_1_0_2__1__Impl(); @@ -16076,17 +16172,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__Group_1_0_2__1__Impl" - // InternalVampireLanguage.g:5158:1: rule__VLSUnaryInfix__Group_1_0_2__1__Impl : ( ':=' ) ; + // InternalVampireLanguage.g:5189:1: rule__VLSUnaryInfix__Group_1_0_2__1__Impl : ( ':=' ) ; public final void rule__VLSUnaryInfix__Group_1_0_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5162:1: ( ( ':=' ) ) - // InternalVampireLanguage.g:5163:1: ( ':=' ) + // InternalVampireLanguage.g:5193:1: ( ( ':=' ) ) + // InternalVampireLanguage.g:5194:1: ( ':=' ) { - // InternalVampireLanguage.g:5163:1: ( ':=' ) - // InternalVampireLanguage.g:5164:2: ':=' + // InternalVampireLanguage.g:5194:1: ( ':=' ) + // InternalVampireLanguage.g:5195:2: ':=' { before(grammarAccess.getVLSUnaryInfixAccess().getColonEqualsSignKeyword_1_0_2_1()); match(input,77,FOLLOW_2); @@ -16113,16 +16209,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_0__0" - // InternalVampireLanguage.g:5174:1: rule__VLSAtomicConstant__Group_0__0 : rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 ; + // InternalVampireLanguage.g:5205:1: rule__VLSAtomicConstant__Group_0__0 : rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 ; public final void rule__VLSAtomicConstant__Group_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5178:1: ( rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 ) - // InternalVampireLanguage.g:5179:2: rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 + // InternalVampireLanguage.g:5209:1: ( rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 ) + // InternalVampireLanguage.g:5210:2: rule__VLSAtomicConstant__Group_0__0__Impl rule__VLSAtomicConstant__Group_0__1 { - pushFollow(FOLLOW_57); + pushFollow(FOLLOW_58); rule__VLSAtomicConstant__Group_0__0__Impl(); state._fsp--; @@ -16151,21 +16247,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_0__0__Impl" - // InternalVampireLanguage.g:5186:1: rule__VLSAtomicConstant__Group_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5217:1: rule__VLSAtomicConstant__Group_0__0__Impl : ( () ) ; public final void rule__VLSAtomicConstant__Group_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5190:1: ( ( () ) ) - // InternalVampireLanguage.g:5191:1: ( () ) + // InternalVampireLanguage.g:5221:1: ( ( () ) ) + // InternalVampireLanguage.g:5222:1: ( () ) { - // InternalVampireLanguage.g:5191:1: ( () ) - // InternalVampireLanguage.g:5192:2: () + // InternalVampireLanguage.g:5222:1: ( () ) + // InternalVampireLanguage.g:5223:2: () { before(grammarAccess.getVLSAtomicConstantAccess().getVLSConstantAction_0_0()); - // InternalVampireLanguage.g:5193:2: () - // InternalVampireLanguage.g:5193:3: + // InternalVampireLanguage.g:5224:2: () + // InternalVampireLanguage.g:5224:3: { } @@ -16188,14 +16284,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_0__1" - // InternalVampireLanguage.g:5201:1: rule__VLSAtomicConstant__Group_0__1 : rule__VLSAtomicConstant__Group_0__1__Impl ; + // InternalVampireLanguage.g:5232:1: rule__VLSAtomicConstant__Group_0__1 : rule__VLSAtomicConstant__Group_0__1__Impl ; public final void rule__VLSAtomicConstant__Group_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5205:1: ( rule__VLSAtomicConstant__Group_0__1__Impl ) - // InternalVampireLanguage.g:5206:2: rule__VLSAtomicConstant__Group_0__1__Impl + // InternalVampireLanguage.g:5236:1: ( rule__VLSAtomicConstant__Group_0__1__Impl ) + // InternalVampireLanguage.g:5237:2: rule__VLSAtomicConstant__Group_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_0__1__Impl(); @@ -16221,21 +16317,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_0__1__Impl" - // InternalVampireLanguage.g:5212:1: rule__VLSAtomicConstant__Group_0__1__Impl : ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) ; + // InternalVampireLanguage.g:5243:1: rule__VLSAtomicConstant__Group_0__1__Impl : ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) ; public final void rule__VLSAtomicConstant__Group_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5216:1: ( ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) ) - // InternalVampireLanguage.g:5217:1: ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) + // InternalVampireLanguage.g:5247:1: ( ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) ) + // InternalVampireLanguage.g:5248:1: ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) { - // InternalVampireLanguage.g:5217:1: ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) - // InternalVampireLanguage.g:5218:2: ( rule__VLSAtomicConstant__NameAssignment_0_1 ) + // InternalVampireLanguage.g:5248:1: ( ( rule__VLSAtomicConstant__NameAssignment_0_1 ) ) + // InternalVampireLanguage.g:5249:2: ( rule__VLSAtomicConstant__NameAssignment_0_1 ) { before(grammarAccess.getVLSAtomicConstantAccess().getNameAssignment_0_1()); - // InternalVampireLanguage.g:5219:2: ( rule__VLSAtomicConstant__NameAssignment_0_1 ) - // InternalVampireLanguage.g:5219:3: rule__VLSAtomicConstant__NameAssignment_0_1 + // InternalVampireLanguage.g:5250:2: ( rule__VLSAtomicConstant__NameAssignment_0_1 ) + // InternalVampireLanguage.g:5250:3: rule__VLSAtomicConstant__NameAssignment_0_1 { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__NameAssignment_0_1(); @@ -16268,16 +16364,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_1__0" - // InternalVampireLanguage.g:5228:1: rule__VLSAtomicConstant__Group_1__0 : rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 ; + // InternalVampireLanguage.g:5259:1: rule__VLSAtomicConstant__Group_1__0 : rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 ; public final void rule__VLSAtomicConstant__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5232:1: ( rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 ) - // InternalVampireLanguage.g:5233:2: rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 + // InternalVampireLanguage.g:5263:1: ( rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 ) + // InternalVampireLanguage.g:5264:2: rule__VLSAtomicConstant__Group_1__0__Impl rule__VLSAtomicConstant__Group_1__1 { - pushFollow(FOLLOW_58); + pushFollow(FOLLOW_59); rule__VLSAtomicConstant__Group_1__0__Impl(); state._fsp--; @@ -16306,21 +16402,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_1__0__Impl" - // InternalVampireLanguage.g:5240:1: rule__VLSAtomicConstant__Group_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5271:1: rule__VLSAtomicConstant__Group_1__0__Impl : ( () ) ; public final void rule__VLSAtomicConstant__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5244:1: ( ( () ) ) - // InternalVampireLanguage.g:5245:1: ( () ) + // InternalVampireLanguage.g:5275:1: ( ( () ) ) + // InternalVampireLanguage.g:5276:1: ( () ) { - // InternalVampireLanguage.g:5245:1: ( () ) - // InternalVampireLanguage.g:5246:2: () + // InternalVampireLanguage.g:5276:1: ( () ) + // InternalVampireLanguage.g:5277:2: () { before(grammarAccess.getVLSAtomicConstantAccess().getVLSTrueAction_1_0()); - // InternalVampireLanguage.g:5247:2: () - // InternalVampireLanguage.g:5247:3: + // InternalVampireLanguage.g:5278:2: () + // InternalVampireLanguage.g:5278:3: { } @@ -16343,14 +16439,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_1__1" - // InternalVampireLanguage.g:5255:1: rule__VLSAtomicConstant__Group_1__1 : rule__VLSAtomicConstant__Group_1__1__Impl ; + // InternalVampireLanguage.g:5286:1: rule__VLSAtomicConstant__Group_1__1 : rule__VLSAtomicConstant__Group_1__1__Impl ; public final void rule__VLSAtomicConstant__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5259:1: ( rule__VLSAtomicConstant__Group_1__1__Impl ) - // InternalVampireLanguage.g:5260:2: rule__VLSAtomicConstant__Group_1__1__Impl + // InternalVampireLanguage.g:5290:1: ( rule__VLSAtomicConstant__Group_1__1__Impl ) + // InternalVampireLanguage.g:5291:2: rule__VLSAtomicConstant__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_1__1__Impl(); @@ -16376,17 +16472,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_1__1__Impl" - // InternalVampireLanguage.g:5266:1: rule__VLSAtomicConstant__Group_1__1__Impl : ( '$true' ) ; + // InternalVampireLanguage.g:5297:1: rule__VLSAtomicConstant__Group_1__1__Impl : ( '$true' ) ; public final void rule__VLSAtomicConstant__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5270:1: ( ( '$true' ) ) - // InternalVampireLanguage.g:5271:1: ( '$true' ) + // InternalVampireLanguage.g:5301:1: ( ( '$true' ) ) + // InternalVampireLanguage.g:5302:1: ( '$true' ) { - // InternalVampireLanguage.g:5271:1: ( '$true' ) - // InternalVampireLanguage.g:5272:2: '$true' + // InternalVampireLanguage.g:5302:1: ( '$true' ) + // InternalVampireLanguage.g:5303:2: '$true' { before(grammarAccess.getVLSAtomicConstantAccess().getTrueKeyword_1_1()); match(input,78,FOLLOW_2); @@ -16413,16 +16509,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_2__0" - // InternalVampireLanguage.g:5282:1: rule__VLSAtomicConstant__Group_2__0 : rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 ; + // InternalVampireLanguage.g:5313:1: rule__VLSAtomicConstant__Group_2__0 : rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 ; public final void rule__VLSAtomicConstant__Group_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5286:1: ( rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 ) - // InternalVampireLanguage.g:5287:2: rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 + // InternalVampireLanguage.g:5317:1: ( rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 ) + // InternalVampireLanguage.g:5318:2: rule__VLSAtomicConstant__Group_2__0__Impl rule__VLSAtomicConstant__Group_2__1 { - pushFollow(FOLLOW_37); + pushFollow(FOLLOW_38); rule__VLSAtomicConstant__Group_2__0__Impl(); state._fsp--; @@ -16451,21 +16547,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_2__0__Impl" - // InternalVampireLanguage.g:5294:1: rule__VLSAtomicConstant__Group_2__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5325:1: rule__VLSAtomicConstant__Group_2__0__Impl : ( () ) ; public final void rule__VLSAtomicConstant__Group_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5298:1: ( ( () ) ) - // InternalVampireLanguage.g:5299:1: ( () ) + // InternalVampireLanguage.g:5329:1: ( ( () ) ) + // InternalVampireLanguage.g:5330:1: ( () ) { - // InternalVampireLanguage.g:5299:1: ( () ) - // InternalVampireLanguage.g:5300:2: () + // InternalVampireLanguage.g:5330:1: ( () ) + // InternalVampireLanguage.g:5331:2: () { before(grammarAccess.getVLSAtomicConstantAccess().getVLSFalseAction_2_0()); - // InternalVampireLanguage.g:5301:2: () - // InternalVampireLanguage.g:5301:3: + // InternalVampireLanguage.g:5332:2: () + // InternalVampireLanguage.g:5332:3: { } @@ -16488,14 +16584,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_2__1" - // InternalVampireLanguage.g:5309:1: rule__VLSAtomicConstant__Group_2__1 : rule__VLSAtomicConstant__Group_2__1__Impl ; + // InternalVampireLanguage.g:5340:1: rule__VLSAtomicConstant__Group_2__1 : rule__VLSAtomicConstant__Group_2__1__Impl ; public final void rule__VLSAtomicConstant__Group_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5313:1: ( rule__VLSAtomicConstant__Group_2__1__Impl ) - // InternalVampireLanguage.g:5314:2: rule__VLSAtomicConstant__Group_2__1__Impl + // InternalVampireLanguage.g:5344:1: ( rule__VLSAtomicConstant__Group_2__1__Impl ) + // InternalVampireLanguage.g:5345:2: rule__VLSAtomicConstant__Group_2__1__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__Group_2__1__Impl(); @@ -16521,17 +16617,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__Group_2__1__Impl" - // InternalVampireLanguage.g:5320:1: rule__VLSAtomicConstant__Group_2__1__Impl : ( '$false' ) ; + // InternalVampireLanguage.g:5351:1: rule__VLSAtomicConstant__Group_2__1__Impl : ( '$false' ) ; public final void rule__VLSAtomicConstant__Group_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5324:1: ( ( '$false' ) ) - // InternalVampireLanguage.g:5325:1: ( '$false' ) + // InternalVampireLanguage.g:5355:1: ( ( '$false' ) ) + // InternalVampireLanguage.g:5356:1: ( '$false' ) { - // InternalVampireLanguage.g:5325:1: ( '$false' ) - // InternalVampireLanguage.g:5326:2: '$false' + // InternalVampireLanguage.g:5356:1: ( '$false' ) + // InternalVampireLanguage.g:5357:2: '$false' { before(grammarAccess.getVLSAtomicConstantAccess().getFalseKeyword_2_1()); match(input,79,FOLLOW_2); @@ -16558,16 +16654,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__0" - // InternalVampireLanguage.g:5336:1: rule__VLSAtomicFunction__Group_0__0 : rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 ; + // InternalVampireLanguage.g:5367:1: rule__VLSAtomicFunction__Group_0__0 : rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 ; public final void rule__VLSAtomicFunction__Group_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5340:1: ( rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 ) - // InternalVampireLanguage.g:5341:2: rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 + // InternalVampireLanguage.g:5371:1: ( rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 ) + // InternalVampireLanguage.g:5372:2: rule__VLSAtomicFunction__Group_0__0__Impl rule__VLSAtomicFunction__Group_0__1 { - pushFollow(FOLLOW_57); + pushFollow(FOLLOW_58); rule__VLSAtomicFunction__Group_0__0__Impl(); state._fsp--; @@ -16596,21 +16692,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__0__Impl" - // InternalVampireLanguage.g:5348:1: rule__VLSAtomicFunction__Group_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5379:1: rule__VLSAtomicFunction__Group_0__0__Impl : ( () ) ; public final void rule__VLSAtomicFunction__Group_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5352:1: ( ( () ) ) - // InternalVampireLanguage.g:5353:1: ( () ) + // InternalVampireLanguage.g:5383:1: ( ( () ) ) + // InternalVampireLanguage.g:5384:1: ( () ) { - // InternalVampireLanguage.g:5353:1: ( () ) - // InternalVampireLanguage.g:5354:2: () + // InternalVampireLanguage.g:5384:1: ( () ) + // InternalVampireLanguage.g:5385:2: () { before(grammarAccess.getVLSAtomicFunctionAccess().getVLSFunctionAction_0_0()); - // InternalVampireLanguage.g:5355:2: () - // InternalVampireLanguage.g:5355:3: + // InternalVampireLanguage.g:5386:2: () + // InternalVampireLanguage.g:5386:3: { } @@ -16633,14 +16729,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__1" - // InternalVampireLanguage.g:5363:1: rule__VLSAtomicFunction__Group_0__1 : rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 ; + // InternalVampireLanguage.g:5394:1: rule__VLSAtomicFunction__Group_0__1 : rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 ; public final void rule__VLSAtomicFunction__Group_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5367:1: ( rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 ) - // InternalVampireLanguage.g:5368:2: rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 + // InternalVampireLanguage.g:5398:1: ( rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 ) + // InternalVampireLanguage.g:5399:2: rule__VLSAtomicFunction__Group_0__1__Impl rule__VLSAtomicFunction__Group_0__2 { pushFollow(FOLLOW_22); rule__VLSAtomicFunction__Group_0__1__Impl(); @@ -16671,21 +16767,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__1__Impl" - // InternalVampireLanguage.g:5375:1: rule__VLSAtomicFunction__Group_0__1__Impl : ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) ; + // InternalVampireLanguage.g:5406:1: rule__VLSAtomicFunction__Group_0__1__Impl : ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) ; public final void rule__VLSAtomicFunction__Group_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5379:1: ( ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) ) - // InternalVampireLanguage.g:5380:1: ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) + // InternalVampireLanguage.g:5410:1: ( ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) ) + // InternalVampireLanguage.g:5411:1: ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) { - // InternalVampireLanguage.g:5380:1: ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) - // InternalVampireLanguage.g:5381:2: ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) + // InternalVampireLanguage.g:5411:1: ( ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) ) + // InternalVampireLanguage.g:5412:2: ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantAssignment_0_1()); - // InternalVampireLanguage.g:5382:2: ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) - // InternalVampireLanguage.g:5382:3: rule__VLSAtomicFunction__ConstantAssignment_0_1 + // InternalVampireLanguage.g:5413:2: ( rule__VLSAtomicFunction__ConstantAssignment_0_1 ) + // InternalVampireLanguage.g:5413:3: rule__VLSAtomicFunction__ConstantAssignment_0_1 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__ConstantAssignment_0_1(); @@ -16718,14 +16814,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__2" - // InternalVampireLanguage.g:5390:1: rule__VLSAtomicFunction__Group_0__2 : rule__VLSAtomicFunction__Group_0__2__Impl ; + // InternalVampireLanguage.g:5421:1: rule__VLSAtomicFunction__Group_0__2 : rule__VLSAtomicFunction__Group_0__2__Impl ; public final void rule__VLSAtomicFunction__Group_0__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5394:1: ( rule__VLSAtomicFunction__Group_0__2__Impl ) - // InternalVampireLanguage.g:5395:2: rule__VLSAtomicFunction__Group_0__2__Impl + // InternalVampireLanguage.g:5425:1: ( rule__VLSAtomicFunction__Group_0__2__Impl ) + // InternalVampireLanguage.g:5426:2: rule__VLSAtomicFunction__Group_0__2__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_0__2__Impl(); @@ -16751,21 +16847,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0__2__Impl" - // InternalVampireLanguage.g:5401:1: rule__VLSAtomicFunction__Group_0__2__Impl : ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) ; + // InternalVampireLanguage.g:5432:1: rule__VLSAtomicFunction__Group_0__2__Impl : ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) ; public final void rule__VLSAtomicFunction__Group_0__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5405:1: ( ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) ) - // InternalVampireLanguage.g:5406:1: ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) + // InternalVampireLanguage.g:5436:1: ( ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) ) + // InternalVampireLanguage.g:5437:1: ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) { - // InternalVampireLanguage.g:5406:1: ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) - // InternalVampireLanguage.g:5407:2: ( rule__VLSAtomicFunction__Group_0_2__0 ) + // InternalVampireLanguage.g:5437:1: ( ( rule__VLSAtomicFunction__Group_0_2__0 ) ) + // InternalVampireLanguage.g:5438:2: ( rule__VLSAtomicFunction__Group_0_2__0 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getGroup_0_2()); - // InternalVampireLanguage.g:5408:2: ( rule__VLSAtomicFunction__Group_0_2__0 ) - // InternalVampireLanguage.g:5408:3: rule__VLSAtomicFunction__Group_0_2__0 + // InternalVampireLanguage.g:5439:2: ( rule__VLSAtomicFunction__Group_0_2__0 ) + // InternalVampireLanguage.g:5439:3: rule__VLSAtomicFunction__Group_0_2__0 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_0_2__0(); @@ -16798,16 +16894,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__0" - // InternalVampireLanguage.g:5417:1: rule__VLSAtomicFunction__Group_0_2__0 : rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 ; + // InternalVampireLanguage.g:5448:1: rule__VLSAtomicFunction__Group_0_2__0 : rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 ; public final void rule__VLSAtomicFunction__Group_0_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5421:1: ( rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 ) - // InternalVampireLanguage.g:5422:2: rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 + // InternalVampireLanguage.g:5452:1: ( rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 ) + // InternalVampireLanguage.g:5453:2: rule__VLSAtomicFunction__Group_0_2__0__Impl rule__VLSAtomicFunction__Group_0_2__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSAtomicFunction__Group_0_2__0__Impl(); state._fsp--; @@ -16836,17 +16932,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__0__Impl" - // InternalVampireLanguage.g:5429:1: rule__VLSAtomicFunction__Group_0_2__0__Impl : ( '(' ) ; + // InternalVampireLanguage.g:5460:1: rule__VLSAtomicFunction__Group_0_2__0__Impl : ( '(' ) ; public final void rule__VLSAtomicFunction__Group_0_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5433:1: ( ( '(' ) ) - // InternalVampireLanguage.g:5434:1: ( '(' ) + // InternalVampireLanguage.g:5464:1: ( ( '(' ) ) + // InternalVampireLanguage.g:5465:1: ( '(' ) { - // InternalVampireLanguage.g:5434:1: ( '(' ) - // InternalVampireLanguage.g:5435:2: '(' + // InternalVampireLanguage.g:5465:1: ( '(' ) + // InternalVampireLanguage.g:5466:2: '(' { before(grammarAccess.getVLSAtomicFunctionAccess().getLeftParenthesisKeyword_0_2_0()); match(input,55,FOLLOW_2); @@ -16873,14 +16969,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__1" - // InternalVampireLanguage.g:5444:1: rule__VLSAtomicFunction__Group_0_2__1 : rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 ; + // InternalVampireLanguage.g:5475:1: rule__VLSAtomicFunction__Group_0_2__1 : rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 ; public final void rule__VLSAtomicFunction__Group_0_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5448:1: ( rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 ) - // InternalVampireLanguage.g:5449:2: rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 + // InternalVampireLanguage.g:5479:1: ( rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 ) + // InternalVampireLanguage.g:5480:2: rule__VLSAtomicFunction__Group_0_2__1__Impl rule__VLSAtomicFunction__Group_0_2__2 { pushFollow(FOLLOW_27); rule__VLSAtomicFunction__Group_0_2__1__Impl(); @@ -16911,21 +17007,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__1__Impl" - // InternalVampireLanguage.g:5456:1: rule__VLSAtomicFunction__Group_0_2__1__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) ; + // InternalVampireLanguage.g:5487:1: rule__VLSAtomicFunction__Group_0_2__1__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) ; public final void rule__VLSAtomicFunction__Group_0_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5460:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) ) - // InternalVampireLanguage.g:5461:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) + // InternalVampireLanguage.g:5491:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) ) + // InternalVampireLanguage.g:5492:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) { - // InternalVampireLanguage.g:5461:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) - // InternalVampireLanguage.g:5462:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) + // InternalVampireLanguage.g:5492:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) ) + // InternalVampireLanguage.g:5493:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsAssignment_0_2_1()); - // InternalVampireLanguage.g:5463:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) - // InternalVampireLanguage.g:5463:3: rule__VLSAtomicFunction__TermsAssignment_0_2_1 + // InternalVampireLanguage.g:5494:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_1 ) + // InternalVampireLanguage.g:5494:3: rule__VLSAtomicFunction__TermsAssignment_0_2_1 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__TermsAssignment_0_2_1(); @@ -16958,14 +17054,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__2" - // InternalVampireLanguage.g:5471:1: rule__VLSAtomicFunction__Group_0_2__2 : rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 ; + // InternalVampireLanguage.g:5502:1: rule__VLSAtomicFunction__Group_0_2__2 : rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 ; public final void rule__VLSAtomicFunction__Group_0_2__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5475:1: ( rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 ) - // InternalVampireLanguage.g:5476:2: rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 + // InternalVampireLanguage.g:5506:1: ( rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 ) + // InternalVampireLanguage.g:5507:2: rule__VLSAtomicFunction__Group_0_2__2__Impl rule__VLSAtomicFunction__Group_0_2__3 { pushFollow(FOLLOW_27); rule__VLSAtomicFunction__Group_0_2__2__Impl(); @@ -16996,20 +17092,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__2__Impl" - // InternalVampireLanguage.g:5483:1: rule__VLSAtomicFunction__Group_0_2__2__Impl : ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) ; + // InternalVampireLanguage.g:5514:1: rule__VLSAtomicFunction__Group_0_2__2__Impl : ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) ; public final void rule__VLSAtomicFunction__Group_0_2__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5487:1: ( ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) ) - // InternalVampireLanguage.g:5488:1: ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) + // InternalVampireLanguage.g:5518:1: ( ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) ) + // InternalVampireLanguage.g:5519:1: ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) { - // InternalVampireLanguage.g:5488:1: ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) - // InternalVampireLanguage.g:5489:2: ( rule__VLSAtomicFunction__Group_0_2_2__0 )* + // InternalVampireLanguage.g:5519:1: ( ( rule__VLSAtomicFunction__Group_0_2_2__0 )* ) + // InternalVampireLanguage.g:5520:2: ( rule__VLSAtomicFunction__Group_0_2_2__0 )* { before(grammarAccess.getVLSAtomicFunctionAccess().getGroup_0_2_2()); - // InternalVampireLanguage.g:5490:2: ( rule__VLSAtomicFunction__Group_0_2_2__0 )* + // InternalVampireLanguage.g:5521:2: ( rule__VLSAtomicFunction__Group_0_2_2__0 )* loop42: do { int alt42=2; @@ -17022,9 +17118,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt42) { case 1 : - // InternalVampireLanguage.g:5490:3: rule__VLSAtomicFunction__Group_0_2_2__0 + // InternalVampireLanguage.g:5521:3: rule__VLSAtomicFunction__Group_0_2_2__0 { - pushFollow(FOLLOW_33); + pushFollow(FOLLOW_34); rule__VLSAtomicFunction__Group_0_2_2__0(); state._fsp--; @@ -17061,14 +17157,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__3" - // InternalVampireLanguage.g:5498:1: rule__VLSAtomicFunction__Group_0_2__3 : rule__VLSAtomicFunction__Group_0_2__3__Impl ; + // InternalVampireLanguage.g:5529:1: rule__VLSAtomicFunction__Group_0_2__3 : rule__VLSAtomicFunction__Group_0_2__3__Impl ; public final void rule__VLSAtomicFunction__Group_0_2__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5502:1: ( rule__VLSAtomicFunction__Group_0_2__3__Impl ) - // InternalVampireLanguage.g:5503:2: rule__VLSAtomicFunction__Group_0_2__3__Impl + // InternalVampireLanguage.g:5533:1: ( rule__VLSAtomicFunction__Group_0_2__3__Impl ) + // InternalVampireLanguage.g:5534:2: rule__VLSAtomicFunction__Group_0_2__3__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_0_2__3__Impl(); @@ -17094,17 +17190,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2__3__Impl" - // InternalVampireLanguage.g:5509:1: rule__VLSAtomicFunction__Group_0_2__3__Impl : ( ')' ) ; + // InternalVampireLanguage.g:5540:1: rule__VLSAtomicFunction__Group_0_2__3__Impl : ( ')' ) ; public final void rule__VLSAtomicFunction__Group_0_2__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5513:1: ( ( ')' ) ) - // InternalVampireLanguage.g:5514:1: ( ')' ) + // InternalVampireLanguage.g:5544:1: ( ( ')' ) ) + // InternalVampireLanguage.g:5545:1: ( ')' ) { - // InternalVampireLanguage.g:5514:1: ( ')' ) - // InternalVampireLanguage.g:5515:2: ')' + // InternalVampireLanguage.g:5545:1: ( ')' ) + // InternalVampireLanguage.g:5546:2: ')' { before(grammarAccess.getVLSAtomicFunctionAccess().getRightParenthesisKeyword_0_2_3()); match(input,57,FOLLOW_2); @@ -17131,16 +17227,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2_2__0" - // InternalVampireLanguage.g:5525:1: rule__VLSAtomicFunction__Group_0_2_2__0 : rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 ; + // InternalVampireLanguage.g:5556:1: rule__VLSAtomicFunction__Group_0_2_2__0 : rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 ; public final void rule__VLSAtomicFunction__Group_0_2_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5529:1: ( rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 ) - // InternalVampireLanguage.g:5530:2: rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 + // InternalVampireLanguage.g:5560:1: ( rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 ) + // InternalVampireLanguage.g:5561:2: rule__VLSAtomicFunction__Group_0_2_2__0__Impl rule__VLSAtomicFunction__Group_0_2_2__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSAtomicFunction__Group_0_2_2__0__Impl(); state._fsp--; @@ -17169,17 +17265,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2_2__0__Impl" - // InternalVampireLanguage.g:5537:1: rule__VLSAtomicFunction__Group_0_2_2__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:5568:1: rule__VLSAtomicFunction__Group_0_2_2__0__Impl : ( ',' ) ; public final void rule__VLSAtomicFunction__Group_0_2_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5541:1: ( ( ',' ) ) - // InternalVampireLanguage.g:5542:1: ( ',' ) + // InternalVampireLanguage.g:5572:1: ( ( ',' ) ) + // InternalVampireLanguage.g:5573:1: ( ',' ) { - // InternalVampireLanguage.g:5542:1: ( ',' ) - // InternalVampireLanguage.g:5543:2: ',' + // InternalVampireLanguage.g:5573:1: ( ',' ) + // InternalVampireLanguage.g:5574:2: ',' { before(grammarAccess.getVLSAtomicFunctionAccess().getCommaKeyword_0_2_2_0()); match(input,56,FOLLOW_2); @@ -17206,14 +17302,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2_2__1" - // InternalVampireLanguage.g:5552:1: rule__VLSAtomicFunction__Group_0_2_2__1 : rule__VLSAtomicFunction__Group_0_2_2__1__Impl ; + // InternalVampireLanguage.g:5583:1: rule__VLSAtomicFunction__Group_0_2_2__1 : rule__VLSAtomicFunction__Group_0_2_2__1__Impl ; public final void rule__VLSAtomicFunction__Group_0_2_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5556:1: ( rule__VLSAtomicFunction__Group_0_2_2__1__Impl ) - // InternalVampireLanguage.g:5557:2: rule__VLSAtomicFunction__Group_0_2_2__1__Impl + // InternalVampireLanguage.g:5587:1: ( rule__VLSAtomicFunction__Group_0_2_2__1__Impl ) + // InternalVampireLanguage.g:5588:2: rule__VLSAtomicFunction__Group_0_2_2__1__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_0_2_2__1__Impl(); @@ -17239,21 +17335,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_0_2_2__1__Impl" - // InternalVampireLanguage.g:5563:1: rule__VLSAtomicFunction__Group_0_2_2__1__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) ; + // InternalVampireLanguage.g:5594:1: rule__VLSAtomicFunction__Group_0_2_2__1__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) ; public final void rule__VLSAtomicFunction__Group_0_2_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5567:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) ) - // InternalVampireLanguage.g:5568:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) + // InternalVampireLanguage.g:5598:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) ) + // InternalVampireLanguage.g:5599:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) { - // InternalVampireLanguage.g:5568:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) - // InternalVampireLanguage.g:5569:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) + // InternalVampireLanguage.g:5599:1: ( ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) ) + // InternalVampireLanguage.g:5600:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsAssignment_0_2_2_1()); - // InternalVampireLanguage.g:5570:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) - // InternalVampireLanguage.g:5570:3: rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 + // InternalVampireLanguage.g:5601:2: ( rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 ) + // InternalVampireLanguage.g:5601:3: rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__TermsAssignment_0_2_2_1(); @@ -17286,16 +17382,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__0" - // InternalVampireLanguage.g:5579:1: rule__VLSAtomicFunction__Group_1__0 : rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 ; + // InternalVampireLanguage.g:5610:1: rule__VLSAtomicFunction__Group_1__0 : rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 ; public final void rule__VLSAtomicFunction__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5583:1: ( rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 ) - // InternalVampireLanguage.g:5584:2: rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 + // InternalVampireLanguage.g:5614:1: ( rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 ) + // InternalVampireLanguage.g:5615:2: rule__VLSAtomicFunction__Group_1__0__Impl rule__VLSAtomicFunction__Group_1__1 { - pushFollow(FOLLOW_59); + pushFollow(FOLLOW_60); rule__VLSAtomicFunction__Group_1__0__Impl(); state._fsp--; @@ -17324,21 +17420,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__0__Impl" - // InternalVampireLanguage.g:5591:1: rule__VLSAtomicFunction__Group_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:5622:1: rule__VLSAtomicFunction__Group_1__0__Impl : ( () ) ; public final void rule__VLSAtomicFunction__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5595:1: ( ( () ) ) - // InternalVampireLanguage.g:5596:1: ( () ) + // InternalVampireLanguage.g:5626:1: ( ( () ) ) + // InternalVampireLanguage.g:5627:1: ( () ) { - // InternalVampireLanguage.g:5596:1: ( () ) - // InternalVampireLanguage.g:5597:2: () + // InternalVampireLanguage.g:5627:1: ( () ) + // InternalVampireLanguage.g:5628:2: () { before(grammarAccess.getVLSAtomicFunctionAccess().getVLSLessAction_1_0()); - // InternalVampireLanguage.g:5598:2: () - // InternalVampireLanguage.g:5598:3: + // InternalVampireLanguage.g:5629:2: () + // InternalVampireLanguage.g:5629:3: { } @@ -17361,14 +17457,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__1" - // InternalVampireLanguage.g:5606:1: rule__VLSAtomicFunction__Group_1__1 : rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 ; + // InternalVampireLanguage.g:5637:1: rule__VLSAtomicFunction__Group_1__1 : rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 ; public final void rule__VLSAtomicFunction__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5610:1: ( rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 ) - // InternalVampireLanguage.g:5611:2: rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 + // InternalVampireLanguage.g:5641:1: ( rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 ) + // InternalVampireLanguage.g:5642:2: rule__VLSAtomicFunction__Group_1__1__Impl rule__VLSAtomicFunction__Group_1__2 { pushFollow(FOLLOW_22); rule__VLSAtomicFunction__Group_1__1__Impl(); @@ -17399,21 +17495,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__1__Impl" - // InternalVampireLanguage.g:5618:1: rule__VLSAtomicFunction__Group_1__1__Impl : ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:5649:1: rule__VLSAtomicFunction__Group_1__1__Impl : ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) ; public final void rule__VLSAtomicFunction__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5622:1: ( ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:5623:1: ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) + // InternalVampireLanguage.g:5653:1: ( ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:5654:1: ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) { - // InternalVampireLanguage.g:5623:1: ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) - // InternalVampireLanguage.g:5624:2: ( rule__VLSAtomicFunction__NameAssignment_1_1 ) + // InternalVampireLanguage.g:5654:1: ( ( rule__VLSAtomicFunction__NameAssignment_1_1 ) ) + // InternalVampireLanguage.g:5655:2: ( rule__VLSAtomicFunction__NameAssignment_1_1 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getNameAssignment_1_1()); - // InternalVampireLanguage.g:5625:2: ( rule__VLSAtomicFunction__NameAssignment_1_1 ) - // InternalVampireLanguage.g:5625:3: rule__VLSAtomicFunction__NameAssignment_1_1 + // InternalVampireLanguage.g:5656:2: ( rule__VLSAtomicFunction__NameAssignment_1_1 ) + // InternalVampireLanguage.g:5656:3: rule__VLSAtomicFunction__NameAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__NameAssignment_1_1(); @@ -17446,16 +17542,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__2" - // InternalVampireLanguage.g:5633:1: rule__VLSAtomicFunction__Group_1__2 : rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 ; + // InternalVampireLanguage.g:5664:1: rule__VLSAtomicFunction__Group_1__2 : rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 ; public final void rule__VLSAtomicFunction__Group_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5637:1: ( rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 ) - // InternalVampireLanguage.g:5638:2: rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 + // InternalVampireLanguage.g:5668:1: ( rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 ) + // InternalVampireLanguage.g:5669:2: rule__VLSAtomicFunction__Group_1__2__Impl rule__VLSAtomicFunction__Group_1__3 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSAtomicFunction__Group_1__2__Impl(); state._fsp--; @@ -17484,17 +17580,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__2__Impl" - // InternalVampireLanguage.g:5645:1: rule__VLSAtomicFunction__Group_1__2__Impl : ( '(' ) ; + // InternalVampireLanguage.g:5676:1: rule__VLSAtomicFunction__Group_1__2__Impl : ( '(' ) ; public final void rule__VLSAtomicFunction__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5649:1: ( ( '(' ) ) - // InternalVampireLanguage.g:5650:1: ( '(' ) + // InternalVampireLanguage.g:5680:1: ( ( '(' ) ) + // InternalVampireLanguage.g:5681:1: ( '(' ) { - // InternalVampireLanguage.g:5650:1: ( '(' ) - // InternalVampireLanguage.g:5651:2: '(' + // InternalVampireLanguage.g:5681:1: ( '(' ) + // InternalVampireLanguage.g:5682:2: '(' { before(grammarAccess.getVLSAtomicFunctionAccess().getLeftParenthesisKeyword_1_2()); match(input,55,FOLLOW_2); @@ -17521,14 +17617,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__3" - // InternalVampireLanguage.g:5660:1: rule__VLSAtomicFunction__Group_1__3 : rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 ; + // InternalVampireLanguage.g:5691:1: rule__VLSAtomicFunction__Group_1__3 : rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 ; public final void rule__VLSAtomicFunction__Group_1__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5664:1: ( rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 ) - // InternalVampireLanguage.g:5665:2: rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 + // InternalVampireLanguage.g:5695:1: ( rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 ) + // InternalVampireLanguage.g:5696:2: rule__VLSAtomicFunction__Group_1__3__Impl rule__VLSAtomicFunction__Group_1__4 { pushFollow(FOLLOW_24); rule__VLSAtomicFunction__Group_1__3__Impl(); @@ -17559,21 +17655,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__3__Impl" - // InternalVampireLanguage.g:5672:1: rule__VLSAtomicFunction__Group_1__3__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) ; + // InternalVampireLanguage.g:5703:1: rule__VLSAtomicFunction__Group_1__3__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) ; public final void rule__VLSAtomicFunction__Group_1__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5676:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) ) - // InternalVampireLanguage.g:5677:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) + // InternalVampireLanguage.g:5707:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) ) + // InternalVampireLanguage.g:5708:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) { - // InternalVampireLanguage.g:5677:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) - // InternalVampireLanguage.g:5678:2: ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) + // InternalVampireLanguage.g:5708:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) ) + // InternalVampireLanguage.g:5709:2: ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsAssignment_1_3()); - // InternalVampireLanguage.g:5679:2: ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) - // InternalVampireLanguage.g:5679:3: rule__VLSAtomicFunction__TermsAssignment_1_3 + // InternalVampireLanguage.g:5710:2: ( rule__VLSAtomicFunction__TermsAssignment_1_3 ) + // InternalVampireLanguage.g:5710:3: rule__VLSAtomicFunction__TermsAssignment_1_3 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__TermsAssignment_1_3(); @@ -17606,16 +17702,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__4" - // InternalVampireLanguage.g:5687:1: rule__VLSAtomicFunction__Group_1__4 : rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 ; + // InternalVampireLanguage.g:5718:1: rule__VLSAtomicFunction__Group_1__4 : rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 ; public final void rule__VLSAtomicFunction__Group_1__4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5691:1: ( rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 ) - // InternalVampireLanguage.g:5692:2: rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 + // InternalVampireLanguage.g:5722:1: ( rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 ) + // InternalVampireLanguage.g:5723:2: rule__VLSAtomicFunction__Group_1__4__Impl rule__VLSAtomicFunction__Group_1__5 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSAtomicFunction__Group_1__4__Impl(); state._fsp--; @@ -17644,17 +17740,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__4__Impl" - // InternalVampireLanguage.g:5699:1: rule__VLSAtomicFunction__Group_1__4__Impl : ( ',' ) ; + // InternalVampireLanguage.g:5730:1: rule__VLSAtomicFunction__Group_1__4__Impl : ( ',' ) ; public final void rule__VLSAtomicFunction__Group_1__4__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5703:1: ( ( ',' ) ) - // InternalVampireLanguage.g:5704:1: ( ',' ) + // InternalVampireLanguage.g:5734:1: ( ( ',' ) ) + // InternalVampireLanguage.g:5735:1: ( ',' ) { - // InternalVampireLanguage.g:5704:1: ( ',' ) - // InternalVampireLanguage.g:5705:2: ',' + // InternalVampireLanguage.g:5735:1: ( ',' ) + // InternalVampireLanguage.g:5736:2: ',' { before(grammarAccess.getVLSAtomicFunctionAccess().getCommaKeyword_1_4()); match(input,56,FOLLOW_2); @@ -17681,16 +17777,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__5" - // InternalVampireLanguage.g:5714:1: rule__VLSAtomicFunction__Group_1__5 : rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 ; + // InternalVampireLanguage.g:5745:1: rule__VLSAtomicFunction__Group_1__5 : rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 ; public final void rule__VLSAtomicFunction__Group_1__5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5718:1: ( rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 ) - // InternalVampireLanguage.g:5719:2: rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 + // InternalVampireLanguage.g:5749:1: ( rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 ) + // InternalVampireLanguage.g:5750:2: rule__VLSAtomicFunction__Group_1__5__Impl rule__VLSAtomicFunction__Group_1__6 { - pushFollow(FOLLOW_32); + pushFollow(FOLLOW_33); rule__VLSAtomicFunction__Group_1__5__Impl(); state._fsp--; @@ -17719,21 +17815,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__5__Impl" - // InternalVampireLanguage.g:5726:1: rule__VLSAtomicFunction__Group_1__5__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) ; + // InternalVampireLanguage.g:5757:1: rule__VLSAtomicFunction__Group_1__5__Impl : ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) ; public final void rule__VLSAtomicFunction__Group_1__5__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5730:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) ) - // InternalVampireLanguage.g:5731:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) + // InternalVampireLanguage.g:5761:1: ( ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) ) + // InternalVampireLanguage.g:5762:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) { - // InternalVampireLanguage.g:5731:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) - // InternalVampireLanguage.g:5732:2: ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) + // InternalVampireLanguage.g:5762:1: ( ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) ) + // InternalVampireLanguage.g:5763:2: ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsAssignment_1_5()); - // InternalVampireLanguage.g:5733:2: ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) - // InternalVampireLanguage.g:5733:3: rule__VLSAtomicFunction__TermsAssignment_1_5 + // InternalVampireLanguage.g:5764:2: ( rule__VLSAtomicFunction__TermsAssignment_1_5 ) + // InternalVampireLanguage.g:5764:3: rule__VLSAtomicFunction__TermsAssignment_1_5 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__TermsAssignment_1_5(); @@ -17766,14 +17862,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__6" - // InternalVampireLanguage.g:5741:1: rule__VLSAtomicFunction__Group_1__6 : rule__VLSAtomicFunction__Group_1__6__Impl ; + // InternalVampireLanguage.g:5772:1: rule__VLSAtomicFunction__Group_1__6 : rule__VLSAtomicFunction__Group_1__6__Impl ; public final void rule__VLSAtomicFunction__Group_1__6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5745:1: ( rule__VLSAtomicFunction__Group_1__6__Impl ) - // InternalVampireLanguage.g:5746:2: rule__VLSAtomicFunction__Group_1__6__Impl + // InternalVampireLanguage.g:5776:1: ( rule__VLSAtomicFunction__Group_1__6__Impl ) + // InternalVampireLanguage.g:5777:2: rule__VLSAtomicFunction__Group_1__6__Impl { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__Group_1__6__Impl(); @@ -17799,17 +17895,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__Group_1__6__Impl" - // InternalVampireLanguage.g:5752:1: rule__VLSAtomicFunction__Group_1__6__Impl : ( ')' ) ; + // InternalVampireLanguage.g:5783:1: rule__VLSAtomicFunction__Group_1__6__Impl : ( ')' ) ; public final void rule__VLSAtomicFunction__Group_1__6__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5756:1: ( ( ')' ) ) - // InternalVampireLanguage.g:5757:1: ( ')' ) + // InternalVampireLanguage.g:5787:1: ( ( ')' ) ) + // InternalVampireLanguage.g:5788:1: ( ')' ) { - // InternalVampireLanguage.g:5757:1: ( ')' ) - // InternalVampireLanguage.g:5758:2: ')' + // InternalVampireLanguage.g:5788:1: ( ')' ) + // InternalVampireLanguage.g:5789:2: ')' { before(grammarAccess.getVLSAtomicFunctionAccess().getRightParenthesisKeyword_1_6()); match(input,57,FOLLOW_2); @@ -17836,14 +17932,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group__0" - // InternalVampireLanguage.g:5768:1: rule__VLSFunctionAsTerm__Group__0 : rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 ; + // InternalVampireLanguage.g:5799:1: rule__VLSFunctionAsTerm__Group__0 : rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 ; public final void rule__VLSFunctionAsTerm__Group__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5772:1: ( rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 ) - // InternalVampireLanguage.g:5773:2: rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 + // InternalVampireLanguage.g:5803:1: ( rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 ) + // InternalVampireLanguage.g:5804:2: rule__VLSFunctionAsTerm__Group__0__Impl rule__VLSFunctionAsTerm__Group__1 { pushFollow(FOLLOW_22); rule__VLSFunctionAsTerm__Group__0__Impl(); @@ -17874,21 +17970,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group__0__Impl" - // InternalVampireLanguage.g:5780:1: rule__VLSFunctionAsTerm__Group__0__Impl : ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) ; + // InternalVampireLanguage.g:5811:1: rule__VLSFunctionAsTerm__Group__0__Impl : ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) ; public final void rule__VLSFunctionAsTerm__Group__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5784:1: ( ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) ) - // InternalVampireLanguage.g:5785:1: ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) + // InternalVampireLanguage.g:5815:1: ( ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) ) + // InternalVampireLanguage.g:5816:1: ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) { - // InternalVampireLanguage.g:5785:1: ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) - // InternalVampireLanguage.g:5786:2: ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) + // InternalVampireLanguage.g:5816:1: ( ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) ) + // InternalVampireLanguage.g:5817:2: ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorAssignment_0()); - // InternalVampireLanguage.g:5787:2: ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) - // InternalVampireLanguage.g:5787:3: rule__VLSFunctionAsTerm__FunctorAssignment_0 + // InternalVampireLanguage.g:5818:2: ( rule__VLSFunctionAsTerm__FunctorAssignment_0 ) + // InternalVampireLanguage.g:5818:3: rule__VLSFunctionAsTerm__FunctorAssignment_0 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__FunctorAssignment_0(); @@ -17921,14 +18017,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group__1" - // InternalVampireLanguage.g:5795:1: rule__VLSFunctionAsTerm__Group__1 : rule__VLSFunctionAsTerm__Group__1__Impl ; + // InternalVampireLanguage.g:5826:1: rule__VLSFunctionAsTerm__Group__1 : rule__VLSFunctionAsTerm__Group__1__Impl ; public final void rule__VLSFunctionAsTerm__Group__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5799:1: ( rule__VLSFunctionAsTerm__Group__1__Impl ) - // InternalVampireLanguage.g:5800:2: rule__VLSFunctionAsTerm__Group__1__Impl + // InternalVampireLanguage.g:5830:1: ( rule__VLSFunctionAsTerm__Group__1__Impl ) + // InternalVampireLanguage.g:5831:2: rule__VLSFunctionAsTerm__Group__1__Impl { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__Group__1__Impl(); @@ -17954,20 +18050,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group__1__Impl" - // InternalVampireLanguage.g:5806:1: rule__VLSFunctionAsTerm__Group__1__Impl : ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) ; + // InternalVampireLanguage.g:5837:1: rule__VLSFunctionAsTerm__Group__1__Impl : ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) ; public final void rule__VLSFunctionAsTerm__Group__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5810:1: ( ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) ) - // InternalVampireLanguage.g:5811:1: ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) + // InternalVampireLanguage.g:5841:1: ( ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) ) + // InternalVampireLanguage.g:5842:1: ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) { - // InternalVampireLanguage.g:5811:1: ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) - // InternalVampireLanguage.g:5812:2: ( rule__VLSFunctionAsTerm__Group_1__0 )? + // InternalVampireLanguage.g:5842:1: ( ( rule__VLSFunctionAsTerm__Group_1__0 )? ) + // InternalVampireLanguage.g:5843:2: ( rule__VLSFunctionAsTerm__Group_1__0 )? { before(grammarAccess.getVLSFunctionAsTermAccess().getGroup_1()); - // InternalVampireLanguage.g:5813:2: ( rule__VLSFunctionAsTerm__Group_1__0 )? + // InternalVampireLanguage.g:5844:2: ( rule__VLSFunctionAsTerm__Group_1__0 )? int alt43=2; int LA43_0 = input.LA(1); @@ -17976,7 +18072,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist } switch (alt43) { case 1 : - // InternalVampireLanguage.g:5813:3: rule__VLSFunctionAsTerm__Group_1__0 + // InternalVampireLanguage.g:5844:3: rule__VLSFunctionAsTerm__Group_1__0 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__Group_1__0(); @@ -18012,16 +18108,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__0" - // InternalVampireLanguage.g:5822:1: rule__VLSFunctionAsTerm__Group_1__0 : rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 ; + // InternalVampireLanguage.g:5853:1: rule__VLSFunctionAsTerm__Group_1__0 : rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 ; public final void rule__VLSFunctionAsTerm__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5826:1: ( rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 ) - // InternalVampireLanguage.g:5827:2: rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 + // InternalVampireLanguage.g:5857:1: ( rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 ) + // InternalVampireLanguage.g:5858:2: rule__VLSFunctionAsTerm__Group_1__0__Impl rule__VLSFunctionAsTerm__Group_1__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSFunctionAsTerm__Group_1__0__Impl(); state._fsp--; @@ -18050,17 +18146,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__0__Impl" - // InternalVampireLanguage.g:5834:1: rule__VLSFunctionAsTerm__Group_1__0__Impl : ( '(' ) ; + // InternalVampireLanguage.g:5865:1: rule__VLSFunctionAsTerm__Group_1__0__Impl : ( '(' ) ; public final void rule__VLSFunctionAsTerm__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5838:1: ( ( '(' ) ) - // InternalVampireLanguage.g:5839:1: ( '(' ) + // InternalVampireLanguage.g:5869:1: ( ( '(' ) ) + // InternalVampireLanguage.g:5870:1: ( '(' ) { - // InternalVampireLanguage.g:5839:1: ( '(' ) - // InternalVampireLanguage.g:5840:2: '(' + // InternalVampireLanguage.g:5870:1: ( '(' ) + // InternalVampireLanguage.g:5871:2: '(' { before(grammarAccess.getVLSFunctionAsTermAccess().getLeftParenthesisKeyword_1_0()); match(input,55,FOLLOW_2); @@ -18087,14 +18183,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__1" - // InternalVampireLanguage.g:5849:1: rule__VLSFunctionAsTerm__Group_1__1 : rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 ; + // InternalVampireLanguage.g:5880:1: rule__VLSFunctionAsTerm__Group_1__1 : rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 ; public final void rule__VLSFunctionAsTerm__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5853:1: ( rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 ) - // InternalVampireLanguage.g:5854:2: rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 + // InternalVampireLanguage.g:5884:1: ( rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 ) + // InternalVampireLanguage.g:5885:2: rule__VLSFunctionAsTerm__Group_1__1__Impl rule__VLSFunctionAsTerm__Group_1__2 { pushFollow(FOLLOW_27); rule__VLSFunctionAsTerm__Group_1__1__Impl(); @@ -18125,21 +18221,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__1__Impl" - // InternalVampireLanguage.g:5861:1: rule__VLSFunctionAsTerm__Group_1__1__Impl : ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:5892:1: rule__VLSFunctionAsTerm__Group_1__1__Impl : ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) ; public final void rule__VLSFunctionAsTerm__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5865:1: ( ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:5866:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) + // InternalVampireLanguage.g:5896:1: ( ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:5897:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) { - // InternalVampireLanguage.g:5866:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) - // InternalVampireLanguage.g:5867:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) + // InternalVampireLanguage.g:5897:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) ) + // InternalVampireLanguage.g:5898:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) { before(grammarAccess.getVLSFunctionAsTermAccess().getTermsAssignment_1_1()); - // InternalVampireLanguage.g:5868:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) - // InternalVampireLanguage.g:5868:3: rule__VLSFunctionAsTerm__TermsAssignment_1_1 + // InternalVampireLanguage.g:5899:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_1 ) + // InternalVampireLanguage.g:5899:3: rule__VLSFunctionAsTerm__TermsAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__TermsAssignment_1_1(); @@ -18172,14 +18268,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__2" - // InternalVampireLanguage.g:5876:1: rule__VLSFunctionAsTerm__Group_1__2 : rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 ; + // InternalVampireLanguage.g:5907:1: rule__VLSFunctionAsTerm__Group_1__2 : rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 ; public final void rule__VLSFunctionAsTerm__Group_1__2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5880:1: ( rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 ) - // InternalVampireLanguage.g:5881:2: rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 + // InternalVampireLanguage.g:5911:1: ( rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 ) + // InternalVampireLanguage.g:5912:2: rule__VLSFunctionAsTerm__Group_1__2__Impl rule__VLSFunctionAsTerm__Group_1__3 { pushFollow(FOLLOW_27); rule__VLSFunctionAsTerm__Group_1__2__Impl(); @@ -18210,20 +18306,20 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__2__Impl" - // InternalVampireLanguage.g:5888:1: rule__VLSFunctionAsTerm__Group_1__2__Impl : ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) ; + // InternalVampireLanguage.g:5919:1: rule__VLSFunctionAsTerm__Group_1__2__Impl : ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) ; public final void rule__VLSFunctionAsTerm__Group_1__2__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5892:1: ( ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) ) - // InternalVampireLanguage.g:5893:1: ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) + // InternalVampireLanguage.g:5923:1: ( ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) ) + // InternalVampireLanguage.g:5924:1: ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) { - // InternalVampireLanguage.g:5893:1: ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) - // InternalVampireLanguage.g:5894:2: ( rule__VLSFunctionAsTerm__Group_1_2__0 )* + // InternalVampireLanguage.g:5924:1: ( ( rule__VLSFunctionAsTerm__Group_1_2__0 )* ) + // InternalVampireLanguage.g:5925:2: ( rule__VLSFunctionAsTerm__Group_1_2__0 )* { before(grammarAccess.getVLSFunctionAsTermAccess().getGroup_1_2()); - // InternalVampireLanguage.g:5895:2: ( rule__VLSFunctionAsTerm__Group_1_2__0 )* + // InternalVampireLanguage.g:5926:2: ( rule__VLSFunctionAsTerm__Group_1_2__0 )* loop44: do { int alt44=2; @@ -18236,9 +18332,9 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist switch (alt44) { case 1 : - // InternalVampireLanguage.g:5895:3: rule__VLSFunctionAsTerm__Group_1_2__0 + // InternalVampireLanguage.g:5926:3: rule__VLSFunctionAsTerm__Group_1_2__0 { - pushFollow(FOLLOW_33); + pushFollow(FOLLOW_34); rule__VLSFunctionAsTerm__Group_1_2__0(); state._fsp--; @@ -18275,14 +18371,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__3" - // InternalVampireLanguage.g:5903:1: rule__VLSFunctionAsTerm__Group_1__3 : rule__VLSFunctionAsTerm__Group_1__3__Impl ; + // InternalVampireLanguage.g:5934:1: rule__VLSFunctionAsTerm__Group_1__3 : rule__VLSFunctionAsTerm__Group_1__3__Impl ; public final void rule__VLSFunctionAsTerm__Group_1__3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5907:1: ( rule__VLSFunctionAsTerm__Group_1__3__Impl ) - // InternalVampireLanguage.g:5908:2: rule__VLSFunctionAsTerm__Group_1__3__Impl + // InternalVampireLanguage.g:5938:1: ( rule__VLSFunctionAsTerm__Group_1__3__Impl ) + // InternalVampireLanguage.g:5939:2: rule__VLSFunctionAsTerm__Group_1__3__Impl { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__Group_1__3__Impl(); @@ -18308,17 +18404,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1__3__Impl" - // InternalVampireLanguage.g:5914:1: rule__VLSFunctionAsTerm__Group_1__3__Impl : ( ')' ) ; + // InternalVampireLanguage.g:5945:1: rule__VLSFunctionAsTerm__Group_1__3__Impl : ( ')' ) ; public final void rule__VLSFunctionAsTerm__Group_1__3__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5918:1: ( ( ')' ) ) - // InternalVampireLanguage.g:5919:1: ( ')' ) + // InternalVampireLanguage.g:5949:1: ( ( ')' ) ) + // InternalVampireLanguage.g:5950:1: ( ')' ) { - // InternalVampireLanguage.g:5919:1: ( ')' ) - // InternalVampireLanguage.g:5920:2: ')' + // InternalVampireLanguage.g:5950:1: ( ')' ) + // InternalVampireLanguage.g:5951:2: ')' { before(grammarAccess.getVLSFunctionAsTermAccess().getRightParenthesisKeyword_1_3()); match(input,57,FOLLOW_2); @@ -18345,16 +18441,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1_2__0" - // InternalVampireLanguage.g:5930:1: rule__VLSFunctionAsTerm__Group_1_2__0 : rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 ; + // InternalVampireLanguage.g:5961:1: rule__VLSFunctionAsTerm__Group_1_2__0 : rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 ; public final void rule__VLSFunctionAsTerm__Group_1_2__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5934:1: ( rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 ) - // InternalVampireLanguage.g:5935:2: rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 + // InternalVampireLanguage.g:5965:1: ( rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 ) + // InternalVampireLanguage.g:5966:2: rule__VLSFunctionAsTerm__Group_1_2__0__Impl rule__VLSFunctionAsTerm__Group_1_2__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSFunctionAsTerm__Group_1_2__0__Impl(); state._fsp--; @@ -18383,17 +18479,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1_2__0__Impl" - // InternalVampireLanguage.g:5942:1: rule__VLSFunctionAsTerm__Group_1_2__0__Impl : ( ',' ) ; + // InternalVampireLanguage.g:5973:1: rule__VLSFunctionAsTerm__Group_1_2__0__Impl : ( ',' ) ; public final void rule__VLSFunctionAsTerm__Group_1_2__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5946:1: ( ( ',' ) ) - // InternalVampireLanguage.g:5947:1: ( ',' ) + // InternalVampireLanguage.g:5977:1: ( ( ',' ) ) + // InternalVampireLanguage.g:5978:1: ( ',' ) { - // InternalVampireLanguage.g:5947:1: ( ',' ) - // InternalVampireLanguage.g:5948:2: ',' + // InternalVampireLanguage.g:5978:1: ( ',' ) + // InternalVampireLanguage.g:5979:2: ',' { before(grammarAccess.getVLSFunctionAsTermAccess().getCommaKeyword_1_2_0()); match(input,56,FOLLOW_2); @@ -18420,14 +18516,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1_2__1" - // InternalVampireLanguage.g:5957:1: rule__VLSFunctionAsTerm__Group_1_2__1 : rule__VLSFunctionAsTerm__Group_1_2__1__Impl ; + // InternalVampireLanguage.g:5988:1: rule__VLSFunctionAsTerm__Group_1_2__1 : rule__VLSFunctionAsTerm__Group_1_2__1__Impl ; public final void rule__VLSFunctionAsTerm__Group_1_2__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5961:1: ( rule__VLSFunctionAsTerm__Group_1_2__1__Impl ) - // InternalVampireLanguage.g:5962:2: rule__VLSFunctionAsTerm__Group_1_2__1__Impl + // InternalVampireLanguage.g:5992:1: ( rule__VLSFunctionAsTerm__Group_1_2__1__Impl ) + // InternalVampireLanguage.g:5993:2: rule__VLSFunctionAsTerm__Group_1_2__1__Impl { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__Group_1_2__1__Impl(); @@ -18453,21 +18549,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__Group_1_2__1__Impl" - // InternalVampireLanguage.g:5968:1: rule__VLSFunctionAsTerm__Group_1_2__1__Impl : ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) ; + // InternalVampireLanguage.g:5999:1: rule__VLSFunctionAsTerm__Group_1_2__1__Impl : ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) ; public final void rule__VLSFunctionAsTerm__Group_1_2__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5972:1: ( ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) ) - // InternalVampireLanguage.g:5973:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) + // InternalVampireLanguage.g:6003:1: ( ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) ) + // InternalVampireLanguage.g:6004:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) { - // InternalVampireLanguage.g:5973:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) - // InternalVampireLanguage.g:5974:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) + // InternalVampireLanguage.g:6004:1: ( ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) ) + // InternalVampireLanguage.g:6005:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) { before(grammarAccess.getVLSFunctionAsTermAccess().getTermsAssignment_1_2_1()); - // InternalVampireLanguage.g:5975:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) - // InternalVampireLanguage.g:5975:3: rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 + // InternalVampireLanguage.g:6006:2: ( rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 ) + // InternalVampireLanguage.g:6006:3: rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__TermsAssignment_1_2_1(); @@ -18500,16 +18596,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_0__0" - // InternalVampireLanguage.g:5984:1: rule__VLSDefinedTerm__Group_0__0 : rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 ; + // InternalVampireLanguage.g:6015:1: rule__VLSDefinedTerm__Group_0__0 : rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 ; public final void rule__VLSDefinedTerm__Group_0__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:5988:1: ( rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 ) - // InternalVampireLanguage.g:5989:2: rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 + // InternalVampireLanguage.g:6019:1: ( rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 ) + // InternalVampireLanguage.g:6020:2: rule__VLSDefinedTerm__Group_0__0__Impl rule__VLSDefinedTerm__Group_0__1 { - pushFollow(FOLLOW_60); + pushFollow(FOLLOW_61); rule__VLSDefinedTerm__Group_0__0__Impl(); state._fsp--; @@ -18538,21 +18634,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_0__0__Impl" - // InternalVampireLanguage.g:5996:1: rule__VLSDefinedTerm__Group_0__0__Impl : ( () ) ; + // InternalVampireLanguage.g:6027:1: rule__VLSDefinedTerm__Group_0__0__Impl : ( () ) ; public final void rule__VLSDefinedTerm__Group_0__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6000:1: ( ( () ) ) - // InternalVampireLanguage.g:6001:1: ( () ) + // InternalVampireLanguage.g:6031:1: ( ( () ) ) + // InternalVampireLanguage.g:6032:1: ( () ) { - // InternalVampireLanguage.g:6001:1: ( () ) - // InternalVampireLanguage.g:6002:2: () + // InternalVampireLanguage.g:6032:1: ( () ) + // InternalVampireLanguage.g:6033:2: () { before(grammarAccess.getVLSDefinedTermAccess().getVLSIntAction_0_0()); - // InternalVampireLanguage.g:6003:2: () - // InternalVampireLanguage.g:6003:3: + // InternalVampireLanguage.g:6034:2: () + // InternalVampireLanguage.g:6034:3: { } @@ -18575,14 +18671,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_0__1" - // InternalVampireLanguage.g:6011:1: rule__VLSDefinedTerm__Group_0__1 : rule__VLSDefinedTerm__Group_0__1__Impl ; + // InternalVampireLanguage.g:6042:1: rule__VLSDefinedTerm__Group_0__1 : rule__VLSDefinedTerm__Group_0__1__Impl ; public final void rule__VLSDefinedTerm__Group_0__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6015:1: ( rule__VLSDefinedTerm__Group_0__1__Impl ) - // InternalVampireLanguage.g:6016:2: rule__VLSDefinedTerm__Group_0__1__Impl + // InternalVampireLanguage.g:6046:1: ( rule__VLSDefinedTerm__Group_0__1__Impl ) + // InternalVampireLanguage.g:6047:2: rule__VLSDefinedTerm__Group_0__1__Impl { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__Group_0__1__Impl(); @@ -18608,21 +18704,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_0__1__Impl" - // InternalVampireLanguage.g:6022:1: rule__VLSDefinedTerm__Group_0__1__Impl : ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) ; + // InternalVampireLanguage.g:6053:1: rule__VLSDefinedTerm__Group_0__1__Impl : ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) ; public final void rule__VLSDefinedTerm__Group_0__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6026:1: ( ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) ) - // InternalVampireLanguage.g:6027:1: ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) + // InternalVampireLanguage.g:6057:1: ( ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) ) + // InternalVampireLanguage.g:6058:1: ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) { - // InternalVampireLanguage.g:6027:1: ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) - // InternalVampireLanguage.g:6028:2: ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) + // InternalVampireLanguage.g:6058:1: ( ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) ) + // InternalVampireLanguage.g:6059:2: ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) { before(grammarAccess.getVLSDefinedTermAccess().getValueAssignment_0_1()); - // InternalVampireLanguage.g:6029:2: ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) - // InternalVampireLanguage.g:6029:3: rule__VLSDefinedTerm__ValueAssignment_0_1 + // InternalVampireLanguage.g:6060:2: ( rule__VLSDefinedTerm__ValueAssignment_0_1 ) + // InternalVampireLanguage.g:6060:3: rule__VLSDefinedTerm__ValueAssignment_0_1 { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__ValueAssignment_0_1(); @@ -18655,16 +18751,16 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_1__0" - // InternalVampireLanguage.g:6038:1: rule__VLSDefinedTerm__Group_1__0 : rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 ; + // InternalVampireLanguage.g:6069:1: rule__VLSDefinedTerm__Group_1__0 : rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 ; public final void rule__VLSDefinedTerm__Group_1__0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6042:1: ( rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 ) - // InternalVampireLanguage.g:6043:2: rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 + // InternalVampireLanguage.g:6073:1: ( rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 ) + // InternalVampireLanguage.g:6074:2: rule__VLSDefinedTerm__Group_1__0__Impl rule__VLSDefinedTerm__Group_1__1 { - pushFollow(FOLLOW_35); + pushFollow(FOLLOW_36); rule__VLSDefinedTerm__Group_1__0__Impl(); state._fsp--; @@ -18693,21 +18789,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_1__0__Impl" - // InternalVampireLanguage.g:6050:1: rule__VLSDefinedTerm__Group_1__0__Impl : ( () ) ; + // InternalVampireLanguage.g:6081:1: rule__VLSDefinedTerm__Group_1__0__Impl : ( () ) ; public final void rule__VLSDefinedTerm__Group_1__0__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6054:1: ( ( () ) ) - // InternalVampireLanguage.g:6055:1: ( () ) + // InternalVampireLanguage.g:6085:1: ( ( () ) ) + // InternalVampireLanguage.g:6086:1: ( () ) { - // InternalVampireLanguage.g:6055:1: ( () ) - // InternalVampireLanguage.g:6056:2: () + // InternalVampireLanguage.g:6086:1: ( () ) + // InternalVampireLanguage.g:6087:2: () { before(grammarAccess.getVLSDefinedTermAccess().getVLSDoubleQuoteAction_1_0()); - // InternalVampireLanguage.g:6057:2: () - // InternalVampireLanguage.g:6057:3: + // InternalVampireLanguage.g:6088:2: () + // InternalVampireLanguage.g:6088:3: { } @@ -18730,14 +18826,14 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_1__1" - // InternalVampireLanguage.g:6065:1: rule__VLSDefinedTerm__Group_1__1 : rule__VLSDefinedTerm__Group_1__1__Impl ; + // InternalVampireLanguage.g:6096:1: rule__VLSDefinedTerm__Group_1__1 : rule__VLSDefinedTerm__Group_1__1__Impl ; public final void rule__VLSDefinedTerm__Group_1__1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6069:1: ( rule__VLSDefinedTerm__Group_1__1__Impl ) - // InternalVampireLanguage.g:6070:2: rule__VLSDefinedTerm__Group_1__1__Impl + // InternalVampireLanguage.g:6100:1: ( rule__VLSDefinedTerm__Group_1__1__Impl ) + // InternalVampireLanguage.g:6101:2: rule__VLSDefinedTerm__Group_1__1__Impl { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__Group_1__1__Impl(); @@ -18763,21 +18859,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__Group_1__1__Impl" - // InternalVampireLanguage.g:6076:1: rule__VLSDefinedTerm__Group_1__1__Impl : ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) ; + // InternalVampireLanguage.g:6107:1: rule__VLSDefinedTerm__Group_1__1__Impl : ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) ; public final void rule__VLSDefinedTerm__Group_1__1__Impl() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6080:1: ( ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) ) - // InternalVampireLanguage.g:6081:1: ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) + // InternalVampireLanguage.g:6111:1: ( ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) ) + // InternalVampireLanguage.g:6112:1: ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) { - // InternalVampireLanguage.g:6081:1: ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) - // InternalVampireLanguage.g:6082:2: ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) + // InternalVampireLanguage.g:6112:1: ( ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) ) + // InternalVampireLanguage.g:6113:2: ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) { before(grammarAccess.getVLSDefinedTermAccess().getValueAssignment_1_1()); - // InternalVampireLanguage.g:6083:2: ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) - // InternalVampireLanguage.g:6083:3: rule__VLSDefinedTerm__ValueAssignment_1_1 + // InternalVampireLanguage.g:6114:2: ( rule__VLSDefinedTerm__ValueAssignment_1_1 ) + // InternalVampireLanguage.g:6114:3: rule__VLSDefinedTerm__ValueAssignment_1_1 { pushFollow(FOLLOW_2); rule__VLSDefinedTerm__ValueAssignment_1_1(); @@ -18810,17 +18906,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VampireModel__CommentsAssignment_0" - // InternalVampireLanguage.g:6092:1: rule__VampireModel__CommentsAssignment_0 : ( ruleVLSComment ) ; + // InternalVampireLanguage.g:6123:1: rule__VampireModel__CommentsAssignment_0 : ( ruleVLSComment ) ; public final void rule__VampireModel__CommentsAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6096:1: ( ( ruleVLSComment ) ) - // InternalVampireLanguage.g:6097:2: ( ruleVLSComment ) + // InternalVampireLanguage.g:6127:1: ( ( ruleVLSComment ) ) + // InternalVampireLanguage.g:6128:2: ( ruleVLSComment ) { - // InternalVampireLanguage.g:6097:2: ( ruleVLSComment ) - // InternalVampireLanguage.g:6098:3: ruleVLSComment + // InternalVampireLanguage.g:6128:2: ( ruleVLSComment ) + // InternalVampireLanguage.g:6129:3: ruleVLSComment { before(grammarAccess.getVampireModelAccess().getCommentsVLSCommentParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -18851,17 +18947,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VampireModel__ConfirmationsAssignment_1" - // InternalVampireLanguage.g:6107:1: rule__VampireModel__ConfirmationsAssignment_1 : ( ruleVLSConfirmations ) ; + // InternalVampireLanguage.g:6138:1: rule__VampireModel__ConfirmationsAssignment_1 : ( ruleVLSConfirmations ) ; public final void rule__VampireModel__ConfirmationsAssignment_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6111:1: ( ( ruleVLSConfirmations ) ) - // InternalVampireLanguage.g:6112:2: ( ruleVLSConfirmations ) + // InternalVampireLanguage.g:6142:1: ( ( ruleVLSConfirmations ) ) + // InternalVampireLanguage.g:6143:2: ( ruleVLSConfirmations ) { - // InternalVampireLanguage.g:6112:2: ( ruleVLSConfirmations ) - // InternalVampireLanguage.g:6113:3: ruleVLSConfirmations + // InternalVampireLanguage.g:6143:2: ( ruleVLSConfirmations ) + // InternalVampireLanguage.g:6144:3: ruleVLSConfirmations { before(grammarAccess.getVampireModelAccess().getConfirmationsVLSConfirmationsParserRuleCall_1_0()); pushFollow(FOLLOW_2); @@ -18892,17 +18988,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VampireModel__FormulasAssignment_2" - // InternalVampireLanguage.g:6122:1: rule__VampireModel__FormulasAssignment_2 : ( ruleVLSFofFormula ) ; + // InternalVampireLanguage.g:6153:1: rule__VampireModel__FormulasAssignment_2 : ( ruleVLSFofFormula ) ; public final void rule__VampireModel__FormulasAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6126:1: ( ( ruleVLSFofFormula ) ) - // InternalVampireLanguage.g:6127:2: ( ruleVLSFofFormula ) + // InternalVampireLanguage.g:6157:1: ( ( ruleVLSFofFormula ) ) + // InternalVampireLanguage.g:6158:2: ( ruleVLSFofFormula ) { - // InternalVampireLanguage.g:6127:2: ( ruleVLSFofFormula ) - // InternalVampireLanguage.g:6128:3: ruleVLSFofFormula + // InternalVampireLanguage.g:6158:2: ( ruleVLSFofFormula ) + // InternalVampireLanguage.g:6159:3: ruleVLSFofFormula { before(grammarAccess.getVampireModelAccess().getFormulasVLSFofFormulaParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -18933,17 +19029,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VampireModel__TfformulasAssignment_3" - // InternalVampireLanguage.g:6137:1: rule__VampireModel__TfformulasAssignment_3 : ( ruleVLSTffFormula ) ; + // InternalVampireLanguage.g:6168:1: rule__VampireModel__TfformulasAssignment_3 : ( ruleVLSTffFormula ) ; public final void rule__VampireModel__TfformulasAssignment_3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6141:1: ( ( ruleVLSTffFormula ) ) - // InternalVampireLanguage.g:6142:2: ( ruleVLSTffFormula ) + // InternalVampireLanguage.g:6172:1: ( ( ruleVLSTffFormula ) ) + // InternalVampireLanguage.g:6173:2: ( ruleVLSTffFormula ) { - // InternalVampireLanguage.g:6142:2: ( ruleVLSTffFormula ) - // InternalVampireLanguage.g:6143:3: ruleVLSTffFormula + // InternalVampireLanguage.g:6173:2: ( ruleVLSTffFormula ) + // InternalVampireLanguage.g:6174:3: ruleVLSTffFormula { before(grammarAccess.getVampireModelAccess().getTfformulasVLSTffFormulaParserRuleCall_3_0()); pushFollow(FOLLOW_2); @@ -18974,17 +19070,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSComment__CommentAssignment" - // InternalVampireLanguage.g:6152:1: rule__VLSComment__CommentAssignment : ( RULE_SINGLE_COMMENT ) ; + // InternalVampireLanguage.g:6183:1: rule__VLSComment__CommentAssignment : ( RULE_SINGLE_COMMENT ) ; public final void rule__VLSComment__CommentAssignment() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6156:1: ( ( RULE_SINGLE_COMMENT ) ) - // InternalVampireLanguage.g:6157:2: ( RULE_SINGLE_COMMENT ) + // InternalVampireLanguage.g:6187:1: ( ( RULE_SINGLE_COMMENT ) ) + // InternalVampireLanguage.g:6188:2: ( RULE_SINGLE_COMMENT ) { - // InternalVampireLanguage.g:6157:2: ( RULE_SINGLE_COMMENT ) - // InternalVampireLanguage.g:6158:3: RULE_SINGLE_COMMENT + // InternalVampireLanguage.g:6188:2: ( RULE_SINGLE_COMMENT ) + // InternalVampireLanguage.g:6189:3: RULE_SINGLE_COMMENT { before(grammarAccess.getVLSCommentAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); match(input,RULE_SINGLE_COMMENT,FOLLOW_2); @@ -19011,17 +19107,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSConfirmations__NameAssignment_2_3" - // InternalVampireLanguage.g:6167:1: rule__VLSConfirmations__NameAssignment_2_3 : ( RULE_LITERAL ) ; + // InternalVampireLanguage.g:6198:1: rule__VLSConfirmations__NameAssignment_2_3 : ( RULE_LITERAL ) ; public final void rule__VLSConfirmations__NameAssignment_2_3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6171:1: ( ( RULE_LITERAL ) ) - // InternalVampireLanguage.g:6172:2: ( RULE_LITERAL ) + // InternalVampireLanguage.g:6202:1: ( ( RULE_LITERAL ) ) + // InternalVampireLanguage.g:6203:2: ( RULE_LITERAL ) { - // InternalVampireLanguage.g:6172:2: ( RULE_LITERAL ) - // InternalVampireLanguage.g:6173:3: RULE_LITERAL + // InternalVampireLanguage.g:6203:2: ( RULE_LITERAL ) + // InternalVampireLanguage.g:6204:3: RULE_LITERAL { before(grammarAccess.getVLSConfirmationsAccess().getNameLITERALTerminalRuleCall_2_3_0()); match(input,RULE_LITERAL,FOLLOW_2); @@ -19048,21 +19144,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__NameAssignment_2" - // InternalVampireLanguage.g:6182:1: rule__VLSFofFormula__NameAssignment_2 : ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) ; + // InternalVampireLanguage.g:6213:1: rule__VLSFofFormula__NameAssignment_2 : ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) ; public final void rule__VLSFofFormula__NameAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6186:1: ( ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) ) - // InternalVampireLanguage.g:6187:2: ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) + // InternalVampireLanguage.g:6217:1: ( ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) ) + // InternalVampireLanguage.g:6218:2: ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) { - // InternalVampireLanguage.g:6187:2: ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) - // InternalVampireLanguage.g:6188:3: ( rule__VLSFofFormula__NameAlternatives_2_0 ) + // InternalVampireLanguage.g:6218:2: ( ( rule__VLSFofFormula__NameAlternatives_2_0 ) ) + // InternalVampireLanguage.g:6219:3: ( rule__VLSFofFormula__NameAlternatives_2_0 ) { before(grammarAccess.getVLSFofFormulaAccess().getNameAlternatives_2_0()); - // InternalVampireLanguage.g:6189:3: ( rule__VLSFofFormula__NameAlternatives_2_0 ) - // InternalVampireLanguage.g:6189:4: rule__VLSFofFormula__NameAlternatives_2_0 + // InternalVampireLanguage.g:6220:3: ( rule__VLSFofFormula__NameAlternatives_2_0 ) + // InternalVampireLanguage.g:6220:4: rule__VLSFofFormula__NameAlternatives_2_0 { pushFollow(FOLLOW_2); rule__VLSFofFormula__NameAlternatives_2_0(); @@ -19095,17 +19191,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__FofRoleAssignment_4" - // InternalVampireLanguage.g:6197:1: rule__VLSFofFormula__FofRoleAssignment_4 : ( ruleVLSRole ) ; + // InternalVampireLanguage.g:6228:1: rule__VLSFofFormula__FofRoleAssignment_4 : ( ruleVLSRole ) ; public final void rule__VLSFofFormula__FofRoleAssignment_4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6201:1: ( ( ruleVLSRole ) ) - // InternalVampireLanguage.g:6202:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:6232:1: ( ( ruleVLSRole ) ) + // InternalVampireLanguage.g:6233:2: ( ruleVLSRole ) { - // InternalVampireLanguage.g:6202:2: ( ruleVLSRole ) - // InternalVampireLanguage.g:6203:3: ruleVLSRole + // InternalVampireLanguage.g:6233:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:6234:3: ruleVLSRole { before(grammarAccess.getVLSFofFormulaAccess().getFofRoleVLSRoleParserRuleCall_4_0()); pushFollow(FOLLOW_2); @@ -19136,17 +19232,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__FofFormulaAssignment_6" - // InternalVampireLanguage.g:6212:1: rule__VLSFofFormula__FofFormulaAssignment_6 : ( ruleVLSTerm ) ; + // InternalVampireLanguage.g:6243:1: rule__VLSFofFormula__FofFormulaAssignment_6 : ( ruleVLSTerm ) ; public final void rule__VLSFofFormula__FofFormulaAssignment_6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6216:1: ( ( ruleVLSTerm ) ) - // InternalVampireLanguage.g:6217:2: ( ruleVLSTerm ) + // InternalVampireLanguage.g:6247:1: ( ( ruleVLSTerm ) ) + // InternalVampireLanguage.g:6248:2: ( ruleVLSTerm ) { - // InternalVampireLanguage.g:6217:2: ( ruleVLSTerm ) - // InternalVampireLanguage.g:6218:3: ruleVLSTerm + // InternalVampireLanguage.g:6248:2: ( ruleVLSTerm ) + // InternalVampireLanguage.g:6249:3: ruleVLSTerm { before(grammarAccess.getVLSFofFormulaAccess().getFofFormulaVLSTermParserRuleCall_6_0()); pushFollow(FOLLOW_2); @@ -19177,17 +19273,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFofFormula__AnnotationsAssignment_7_1" - // InternalVampireLanguage.g:6227:1: rule__VLSFofFormula__AnnotationsAssignment_7_1 : ( ruleVLSAnnotation ) ; + // InternalVampireLanguage.g:6258:1: rule__VLSFofFormula__AnnotationsAssignment_7_1 : ( ruleVLSAnnotation ) ; public final void rule__VLSFofFormula__AnnotationsAssignment_7_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6231:1: ( ( ruleVLSAnnotation ) ) - // InternalVampireLanguage.g:6232:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6262:1: ( ( ruleVLSAnnotation ) ) + // InternalVampireLanguage.g:6263:2: ( ruleVLSAnnotation ) { - // InternalVampireLanguage.g:6232:2: ( ruleVLSAnnotation ) - // InternalVampireLanguage.g:6233:3: ruleVLSAnnotation + // InternalVampireLanguage.g:6263:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6264:3: ruleVLSAnnotation { before(grammarAccess.getVLSFofFormulaAccess().getAnnotationsVLSAnnotationParserRuleCall_7_1_0()); pushFollow(FOLLOW_2); @@ -19218,17 +19314,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__NameAssignment_2" - // InternalVampireLanguage.g:6242:1: rule__VLSTffFormula__NameAssignment_2 : ( ruleVLSTffName ) ; + // InternalVampireLanguage.g:6273:1: rule__VLSTffFormula__NameAssignment_2 : ( ruleVLSTffName ) ; public final void rule__VLSTffFormula__NameAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6246:1: ( ( ruleVLSTffName ) ) - // InternalVampireLanguage.g:6247:2: ( ruleVLSTffName ) + // InternalVampireLanguage.g:6277:1: ( ( ruleVLSTffName ) ) + // InternalVampireLanguage.g:6278:2: ( ruleVLSTffName ) { - // InternalVampireLanguage.g:6247:2: ( ruleVLSTffName ) - // InternalVampireLanguage.g:6248:3: ruleVLSTffName + // InternalVampireLanguage.g:6278:2: ( ruleVLSTffName ) + // InternalVampireLanguage.g:6279:3: ruleVLSTffName { before(grammarAccess.getVLSTffFormulaAccess().getNameVLSTffNameParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -19259,17 +19355,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__TffRoleAssignment_4" - // InternalVampireLanguage.g:6257:1: rule__VLSTffFormula__TffRoleAssignment_4 : ( ruleVLSRole ) ; + // InternalVampireLanguage.g:6288:1: rule__VLSTffFormula__TffRoleAssignment_4 : ( ruleVLSRole ) ; public final void rule__VLSTffFormula__TffRoleAssignment_4() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6261:1: ( ( ruleVLSRole ) ) - // InternalVampireLanguage.g:6262:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:6292:1: ( ( ruleVLSRole ) ) + // InternalVampireLanguage.g:6293:2: ( ruleVLSRole ) { - // InternalVampireLanguage.g:6262:2: ( ruleVLSRole ) - // InternalVampireLanguage.g:6263:3: ruleVLSRole + // InternalVampireLanguage.g:6293:2: ( ruleVLSRole ) + // InternalVampireLanguage.g:6294:3: ruleVLSRole { before(grammarAccess.getVLSTffFormulaAccess().getTffRoleVLSRoleParserRuleCall_4_0()); pushFollow(FOLLOW_2); @@ -19300,17 +19396,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__FofFormulaAssignment_6" - // InternalVampireLanguage.g:6272:1: rule__VLSTffFormula__FofFormulaAssignment_6 : ( ruleVLSTffTerm ) ; + // InternalVampireLanguage.g:6303:1: rule__VLSTffFormula__FofFormulaAssignment_6 : ( ruleVLSTffTerm ) ; public final void rule__VLSTffFormula__FofFormulaAssignment_6() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6276:1: ( ( ruleVLSTffTerm ) ) - // InternalVampireLanguage.g:6277:2: ( ruleVLSTffTerm ) + // InternalVampireLanguage.g:6307:1: ( ( ruleVLSTffTerm ) ) + // InternalVampireLanguage.g:6308:2: ( ruleVLSTffTerm ) { - // InternalVampireLanguage.g:6277:2: ( ruleVLSTffTerm ) - // InternalVampireLanguage.g:6278:3: ruleVLSTffTerm + // InternalVampireLanguage.g:6308:2: ( ruleVLSTffTerm ) + // InternalVampireLanguage.g:6309:3: ruleVLSTffTerm { before(grammarAccess.getVLSTffFormulaAccess().getFofFormulaVLSTffTermParserRuleCall_6_0()); pushFollow(FOLLOW_2); @@ -19341,17 +19437,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTffFormula__AnnotationsAssignment_7_1" - // InternalVampireLanguage.g:6287:1: rule__VLSTffFormula__AnnotationsAssignment_7_1 : ( ruleVLSAnnotation ) ; + // InternalVampireLanguage.g:6318:1: rule__VLSTffFormula__AnnotationsAssignment_7_1 : ( ruleVLSAnnotation ) ; public final void rule__VLSTffFormula__AnnotationsAssignment_7_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6291:1: ( ( ruleVLSAnnotation ) ) - // InternalVampireLanguage.g:6292:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6322:1: ( ( ruleVLSAnnotation ) ) + // InternalVampireLanguage.g:6323:2: ( ruleVLSAnnotation ) { - // InternalVampireLanguage.g:6292:2: ( ruleVLSAnnotation ) - // InternalVampireLanguage.g:6293:3: ruleVLSAnnotation + // InternalVampireLanguage.g:6323:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6324:3: ruleVLSAnnotation { before(grammarAccess.getVLSTffFormulaAccess().getAnnotationsVLSAnnotationParserRuleCall_7_1_0()); pushFollow(FOLLOW_2); @@ -19382,21 +19478,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__NameAssignment_1" - // InternalVampireLanguage.g:6302:1: rule__VLSAnnotation__NameAssignment_1 : ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) ; + // InternalVampireLanguage.g:6333:1: rule__VLSAnnotation__NameAssignment_1 : ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) ; public final void rule__VLSAnnotation__NameAssignment_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6306:1: ( ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) ) - // InternalVampireLanguage.g:6307:2: ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) + // InternalVampireLanguage.g:6337:1: ( ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) ) + // InternalVampireLanguage.g:6338:2: ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) { - // InternalVampireLanguage.g:6307:2: ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) - // InternalVampireLanguage.g:6308:3: ( rule__VLSAnnotation__NameAlternatives_1_0 ) + // InternalVampireLanguage.g:6338:2: ( ( rule__VLSAnnotation__NameAlternatives_1_0 ) ) + // InternalVampireLanguage.g:6339:3: ( rule__VLSAnnotation__NameAlternatives_1_0 ) { before(grammarAccess.getVLSAnnotationAccess().getNameAlternatives_1_0()); - // InternalVampireLanguage.g:6309:3: ( rule__VLSAnnotation__NameAlternatives_1_0 ) - // InternalVampireLanguage.g:6309:4: rule__VLSAnnotation__NameAlternatives_1_0 + // InternalVampireLanguage.g:6340:3: ( rule__VLSAnnotation__NameAlternatives_1_0 ) + // InternalVampireLanguage.g:6340:4: rule__VLSAnnotation__NameAlternatives_1_0 { pushFollow(FOLLOW_2); rule__VLSAnnotation__NameAlternatives_1_0(); @@ -19429,17 +19525,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotation__FollowupAssignment_2_1" - // InternalVampireLanguage.g:6317:1: rule__VLSAnnotation__FollowupAssignment_2_1 : ( ruleVLSAnnotationTerms ) ; + // InternalVampireLanguage.g:6348:1: rule__VLSAnnotation__FollowupAssignment_2_1 : ( ruleVLSAnnotationTerms ) ; public final void rule__VLSAnnotation__FollowupAssignment_2_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6321:1: ( ( ruleVLSAnnotationTerms ) ) - // InternalVampireLanguage.g:6322:2: ( ruleVLSAnnotationTerms ) + // InternalVampireLanguage.g:6352:1: ( ( ruleVLSAnnotationTerms ) ) + // InternalVampireLanguage.g:6353:2: ( ruleVLSAnnotationTerms ) { - // InternalVampireLanguage.g:6322:2: ( ruleVLSAnnotationTerms ) - // InternalVampireLanguage.g:6323:3: ruleVLSAnnotationTerms + // InternalVampireLanguage.g:6353:2: ( ruleVLSAnnotationTerms ) + // InternalVampireLanguage.g:6354:3: ruleVLSAnnotationTerms { before(grammarAccess.getVLSAnnotationAccess().getFollowupVLSAnnotationTermsParserRuleCall_2_1_0()); pushFollow(FOLLOW_2); @@ -19470,17 +19566,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__TermsAssignment_0" - // InternalVampireLanguage.g:6332:1: rule__VLSAnnotationTerms__TermsAssignment_0 : ( ruleVLSAnnotation ) ; + // InternalVampireLanguage.g:6363:1: rule__VLSAnnotationTerms__TermsAssignment_0 : ( ruleVLSAnnotation ) ; public final void rule__VLSAnnotationTerms__TermsAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6336:1: ( ( ruleVLSAnnotation ) ) - // InternalVampireLanguage.g:6337:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6367:1: ( ( ruleVLSAnnotation ) ) + // InternalVampireLanguage.g:6368:2: ( ruleVLSAnnotation ) { - // InternalVampireLanguage.g:6337:2: ( ruleVLSAnnotation ) - // InternalVampireLanguage.g:6338:3: ruleVLSAnnotation + // InternalVampireLanguage.g:6368:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6369:3: ruleVLSAnnotation { before(grammarAccess.getVLSAnnotationTermsAccess().getTermsVLSAnnotationParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -19511,17 +19607,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAnnotationTerms__TermsAssignment_1_1" - // InternalVampireLanguage.g:6347:1: rule__VLSAnnotationTerms__TermsAssignment_1_1 : ( ruleVLSAnnotation ) ; + // InternalVampireLanguage.g:6378:1: rule__VLSAnnotationTerms__TermsAssignment_1_1 : ( ruleVLSAnnotation ) ; public final void rule__VLSAnnotationTerms__TermsAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6351:1: ( ( ruleVLSAnnotation ) ) - // InternalVampireLanguage.g:6352:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6382:1: ( ( ruleVLSAnnotation ) ) + // InternalVampireLanguage.g:6383:2: ( ruleVLSAnnotation ) { - // InternalVampireLanguage.g:6352:2: ( ruleVLSAnnotation ) - // InternalVampireLanguage.g:6353:3: ruleVLSAnnotation + // InternalVampireLanguage.g:6383:2: ( ruleVLSAnnotation ) + // InternalVampireLanguage.g:6384:3: ruleVLSAnnotation { before(grammarAccess.getVLSAnnotationTermsAccess().getTermsVLSAnnotationParserRuleCall_1_1_0()); pushFollow(FOLLOW_2); @@ -19551,18 +19647,55 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR end "rule__VLSAnnotationTerms__TermsAssignment_1_1" + // $ANTLR start "rule__VLSCommentTerm__CommentAssignment" + // InternalVampireLanguage.g:6393:1: rule__VLSCommentTerm__CommentAssignment : ( RULE_SINGLE_COMMENT ) ; + public final void rule__VLSCommentTerm__CommentAssignment() throws RecognitionException { + + int stackSize = keepStackSize(); + + try { + // InternalVampireLanguage.g:6397:1: ( ( RULE_SINGLE_COMMENT ) ) + // InternalVampireLanguage.g:6398:2: ( RULE_SINGLE_COMMENT ) + { + // InternalVampireLanguage.g:6398:2: ( RULE_SINGLE_COMMENT ) + // InternalVampireLanguage.g:6399:3: RULE_SINGLE_COMMENT + { + before(grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); + match(input,RULE_SINGLE_COMMENT,FOLLOW_2); + after(grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); + + } + + + } + + } + catch (RecognitionException re) { + reportError(re); + recover(input,re); + } + finally { + + restoreStackSize(stackSize); + + } + return ; + } + // $ANTLR end "rule__VLSCommentTerm__CommentAssignment" + + // $ANTLR start "rule__VLSOtherDeclaration__NameAssignment_0" - // InternalVampireLanguage.g:6362:1: rule__VLSOtherDeclaration__NameAssignment_0 : ( ruleVLSAtomicConstant ) ; + // InternalVampireLanguage.g:6408:1: rule__VLSOtherDeclaration__NameAssignment_0 : ( ruleVLSAtomicConstant ) ; public final void rule__VLSOtherDeclaration__NameAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6366:1: ( ( ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:6367:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6412:1: ( ( ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:6413:2: ( ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:6367:2: ( ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:6368:3: ruleVLSAtomicConstant + // InternalVampireLanguage.g:6413:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6414:3: ruleVLSAtomicConstant { before(grammarAccess.getVLSOtherDeclarationAccess().getNameVLSAtomicConstantParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -19593,17 +19726,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSOtherDeclaration__TypeAssignment_2" - // InternalVampireLanguage.g:6377:1: rule__VLSOtherDeclaration__TypeAssignment_2 : ( ruleVLSTypeDef ) ; + // InternalVampireLanguage.g:6423:1: rule__VLSOtherDeclaration__TypeAssignment_2 : ( ruleVLSTypeDef ) ; public final void rule__VLSOtherDeclaration__TypeAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6381:1: ( ( ruleVLSTypeDef ) ) - // InternalVampireLanguage.g:6382:2: ( ruleVLSTypeDef ) + // InternalVampireLanguage.g:6427:1: ( ( ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:6428:2: ( ruleVLSTypeDef ) { - // InternalVampireLanguage.g:6382:2: ( ruleVLSTypeDef ) - // InternalVampireLanguage.g:6383:3: ruleVLSTypeDef + // InternalVampireLanguage.g:6428:2: ( ruleVLSTypeDef ) + // InternalVampireLanguage.g:6429:3: ruleVLSTypeDef { before(grammarAccess.getVLSOtherDeclarationAccess().getTypeVLSTypeDefParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -19634,17 +19767,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__NameAssignment_0" - // InternalVampireLanguage.g:6392:1: rule__VLSVariableDeclaration__NameAssignment_0 : ( ruleVLSVariable ) ; + // InternalVampireLanguage.g:6438:1: rule__VLSVariableDeclaration__NameAssignment_0 : ( ruleVLSVariable ) ; public final void rule__VLSVariableDeclaration__NameAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6396:1: ( ( ruleVLSVariable ) ) - // InternalVampireLanguage.g:6397:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:6442:1: ( ( ruleVLSVariable ) ) + // InternalVampireLanguage.g:6443:2: ( ruleVLSVariable ) { - // InternalVampireLanguage.g:6397:2: ( ruleVLSVariable ) - // InternalVampireLanguage.g:6398:3: ruleVLSVariable + // InternalVampireLanguage.g:6443:2: ( ruleVLSVariable ) + // InternalVampireLanguage.g:6444:3: ruleVLSVariable { before(grammarAccess.getVLSVariableDeclarationAccess().getNameVLSVariableParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -19675,17 +19808,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariableDeclaration__TypeAssignment_2" - // InternalVampireLanguage.g:6407:1: rule__VLSVariableDeclaration__TypeAssignment_2 : ( ruleVLSTypeDef ) ; + // InternalVampireLanguage.g:6453:1: rule__VLSVariableDeclaration__TypeAssignment_2 : ( ruleVLSTypeDef ) ; public final void rule__VLSVariableDeclaration__TypeAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6411:1: ( ( ruleVLSTypeDef ) ) - // InternalVampireLanguage.g:6412:2: ( ruleVLSTypeDef ) + // InternalVampireLanguage.g:6457:1: ( ( ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:6458:2: ( ruleVLSTypeDef ) { - // InternalVampireLanguage.g:6412:2: ( ruleVLSTypeDef ) - // InternalVampireLanguage.g:6413:3: ruleVLSTypeDef + // InternalVampireLanguage.g:6458:2: ( ruleVLSTypeDef ) + // InternalVampireLanguage.g:6459:3: ruleVLSTypeDef { before(grammarAccess.getVLSVariableDeclarationAccess().getTypeVLSTypeDefParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -19716,17 +19849,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__TypeSigAssignment_0" - // InternalVampireLanguage.g:6422:1: rule__VLSTypeDef__TypeSigAssignment_0 : ( ruleVLSUnitaryTerm ) ; + // InternalVampireLanguage.g:6468:1: rule__VLSTypeDef__TypeSigAssignment_0 : ( ruleVLSUnitaryTerm ) ; public final void rule__VLSTypeDef__TypeSigAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6426:1: ( ( ruleVLSUnitaryTerm ) ) - // InternalVampireLanguage.g:6427:2: ( ruleVLSUnitaryTerm ) + // InternalVampireLanguage.g:6472:1: ( ( ruleVLSUnitaryTerm ) ) + // InternalVampireLanguage.g:6473:2: ( ruleVLSUnitaryTerm ) { - // InternalVampireLanguage.g:6427:2: ( ruleVLSUnitaryTerm ) - // InternalVampireLanguage.g:6428:3: ruleVLSUnitaryTerm + // InternalVampireLanguage.g:6473:2: ( ruleVLSUnitaryTerm ) + // InternalVampireLanguage.g:6474:3: ruleVLSUnitaryTerm { before(grammarAccess.getVLSTypeDefAccess().getTypeSigVLSUnitaryTermParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -19757,17 +19890,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSTypeDef__MapsToAssignment_1_1" - // InternalVampireLanguage.g:6437:1: rule__VLSTypeDef__MapsToAssignment_1_1 : ( ruleVLSAtomicConstant ) ; + // InternalVampireLanguage.g:6483:1: rule__VLSTypeDef__MapsToAssignment_1_1 : ( ruleVLSAtomicConstant ) ; public final void rule__VLSTypeDef__MapsToAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6441:1: ( ( ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:6442:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6487:1: ( ( ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:6488:2: ( ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:6442:2: ( ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:6443:3: ruleVLSAtomicConstant + // InternalVampireLanguage.g:6488:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6489:3: ruleVLSAtomicConstant { before(grammarAccess.getVLSTypeDefAccess().getMapsToVLSAtomicConstantParserRuleCall_1_1_0()); pushFollow(FOLLOW_2); @@ -19798,17 +19931,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__InitTypeAssignment_0" - // InternalVampireLanguage.g:6452:1: rule__VLSUnitaryTerm__InitTypeAssignment_0 : ( ruleVLSAtomic ) ; + // InternalVampireLanguage.g:6498:1: rule__VLSUnitaryTerm__InitTypeAssignment_0 : ( ruleVLSAtomic ) ; public final void rule__VLSUnitaryTerm__InitTypeAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6456:1: ( ( ruleVLSAtomic ) ) - // InternalVampireLanguage.g:6457:2: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:6502:1: ( ( ruleVLSAtomic ) ) + // InternalVampireLanguage.g:6503:2: ( ruleVLSAtomic ) { - // InternalVampireLanguage.g:6457:2: ( ruleVLSAtomic ) - // InternalVampireLanguage.g:6458:3: ruleVLSAtomic + // InternalVampireLanguage.g:6503:2: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:6504:3: ruleVLSAtomic { before(grammarAccess.getVLSUnitaryTermAccess().getInitTypeVLSAtomicParserRuleCall_0_0()); pushFollow(FOLLOW_2); @@ -19839,17 +19972,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnitaryTerm__NextTypeAssignment_1_1" - // InternalVampireLanguage.g:6467:1: rule__VLSUnitaryTerm__NextTypeAssignment_1_1 : ( ruleVLSAtomicConstant ) ; + // InternalVampireLanguage.g:6513:1: rule__VLSUnitaryTerm__NextTypeAssignment_1_1 : ( ruleVLSAtomicConstant ) ; public final void rule__VLSUnitaryTerm__NextTypeAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6471:1: ( ( ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:6472:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6517:1: ( ( ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:6518:2: ( ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:6472:2: ( ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:6473:3: ruleVLSAtomicConstant + // InternalVampireLanguage.g:6518:2: ( ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:6519:3: ruleVLSAtomicConstant { before(grammarAccess.getVLSUnitaryTermAccess().getNextTypeVLSAtomicConstantParserRuleCall_1_1_0()); pushFollow(FOLLOW_2); @@ -19880,17 +20013,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__RightAssignment_1_0_1" - // InternalVampireLanguage.g:6482:1: rule__VLSBinary__RightAssignment_1_0_1 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6528:1: rule__VLSBinary__RightAssignment_1_0_1 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSBinary__RightAssignment_1_0_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6486:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6487:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6532:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6533:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6487:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6488:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6533:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6534:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_0_1_0()); pushFollow(FOLLOW_2); @@ -19921,17 +20054,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__RightAssignment_1_1_2" - // InternalVampireLanguage.g:6497:1: rule__VLSBinary__RightAssignment_1_1_2 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6543:1: rule__VLSBinary__RightAssignment_1_1_2 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSBinary__RightAssignment_1_1_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6501:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6502:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6547:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6548:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6502:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6503:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6548:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6549:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_1_2_0()); pushFollow(FOLLOW_2); @@ -19962,17 +20095,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSBinary__RightAssignment_1_2_2" - // InternalVampireLanguage.g:6512:1: rule__VLSBinary__RightAssignment_1_2_2 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6558:1: rule__VLSBinary__RightAssignment_1_2_2 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSBinary__RightAssignment_1_2_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6516:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6517:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6562:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6563:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6517:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6518:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6563:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6564:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_2_2_0()); pushFollow(FOLLOW_2); @@ -20003,21 +20136,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__VariablesAssignment_1_2" - // InternalVampireLanguage.g:6527:1: rule__VLSUniversalQuantifier__VariablesAssignment_1_2 : ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) ; + // InternalVampireLanguage.g:6573:1: rule__VLSUniversalQuantifier__VariablesAssignment_1_2 : ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) ; public final void rule__VLSUniversalQuantifier__VariablesAssignment_1_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6531:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) ) - // InternalVampireLanguage.g:6532:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) + // InternalVampireLanguage.g:6577:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) ) + // InternalVampireLanguage.g:6578:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) { - // InternalVampireLanguage.g:6532:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) - // InternalVampireLanguage.g:6533:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) + // InternalVampireLanguage.g:6578:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) ) + // InternalVampireLanguage.g:6579:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesAlternatives_1_2_0()); - // InternalVampireLanguage.g:6534:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) - // InternalVampireLanguage.g:6534:4: rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 + // InternalVampireLanguage.g:6580:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 ) + // InternalVampireLanguage.g:6580:4: rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__VariablesAlternatives_1_2_0(); @@ -20050,21 +20183,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1" - // InternalVampireLanguage.g:6542:1: rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 : ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) ; + // InternalVampireLanguage.g:6588:1: rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1 : ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) ; public final void rule__VLSUniversalQuantifier__VariablesAssignment_1_3_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6546:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) ) - // InternalVampireLanguage.g:6547:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) + // InternalVampireLanguage.g:6592:1: ( ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) ) + // InternalVampireLanguage.g:6593:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) { - // InternalVampireLanguage.g:6547:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) - // InternalVampireLanguage.g:6548:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) + // InternalVampireLanguage.g:6593:2: ( ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) ) + // InternalVampireLanguage.g:6594:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) { before(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesAlternatives_1_3_1_0()); - // InternalVampireLanguage.g:6549:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) - // InternalVampireLanguage.g:6549:4: rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 + // InternalVampireLanguage.g:6595:3: ( rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 ) + // InternalVampireLanguage.g:6595:4: rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0 { pushFollow(FOLLOW_2); rule__VLSUniversalQuantifier__VariablesAlternatives_1_3_1_0(); @@ -20097,17 +20230,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUniversalQuantifier__OperandAssignment_2" - // InternalVampireLanguage.g:6557:1: rule__VLSUniversalQuantifier__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6603:1: rule__VLSUniversalQuantifier__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSUniversalQuantifier__OperandAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6561:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6562:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6607:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6608:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6562:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6563:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6608:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6609:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSUniversalQuantifierAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -20138,21 +20271,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__VariablesAssignment_1_2" - // InternalVampireLanguage.g:6572:1: rule__VLSExistentialQuantifier__VariablesAssignment_1_2 : ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) ; + // InternalVampireLanguage.g:6618:1: rule__VLSExistentialQuantifier__VariablesAssignment_1_2 : ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) ; public final void rule__VLSExistentialQuantifier__VariablesAssignment_1_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6576:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) ) - // InternalVampireLanguage.g:6577:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) + // InternalVampireLanguage.g:6622:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) ) + // InternalVampireLanguage.g:6623:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) { - // InternalVampireLanguage.g:6577:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) - // InternalVampireLanguage.g:6578:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) + // InternalVampireLanguage.g:6623:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) ) + // InternalVampireLanguage.g:6624:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesAlternatives_1_2_0()); - // InternalVampireLanguage.g:6579:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) - // InternalVampireLanguage.g:6579:4: rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 + // InternalVampireLanguage.g:6625:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 ) + // InternalVampireLanguage.g:6625:4: rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__VariablesAlternatives_1_2_0(); @@ -20185,21 +20318,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1" - // InternalVampireLanguage.g:6587:1: rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 : ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) ; + // InternalVampireLanguage.g:6633:1: rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1 : ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) ; public final void rule__VLSExistentialQuantifier__VariablesAssignment_1_3_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6591:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) ) - // InternalVampireLanguage.g:6592:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) + // InternalVampireLanguage.g:6637:1: ( ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) ) + // InternalVampireLanguage.g:6638:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) { - // InternalVampireLanguage.g:6592:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) - // InternalVampireLanguage.g:6593:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) + // InternalVampireLanguage.g:6638:2: ( ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) ) + // InternalVampireLanguage.g:6639:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) { before(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesAlternatives_1_3_1_0()); - // InternalVampireLanguage.g:6594:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) - // InternalVampireLanguage.g:6594:4: rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 + // InternalVampireLanguage.g:6640:3: ( rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 ) + // InternalVampireLanguage.g:6640:4: rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0 { pushFollow(FOLLOW_2); rule__VLSExistentialQuantifier__VariablesAlternatives_1_3_1_0(); @@ -20232,17 +20365,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSExistentialQuantifier__OperandAssignment_2" - // InternalVampireLanguage.g:6602:1: rule__VLSExistentialQuantifier__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6648:1: rule__VLSExistentialQuantifier__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSExistentialQuantifier__OperandAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6606:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6607:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6652:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6653:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6607:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6608:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6653:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6654:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSExistentialQuantifierAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -20273,17 +20406,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryNegation__OperandAssignment_2" - // InternalVampireLanguage.g:6617:1: rule__VLSUnaryNegation__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; + // InternalVampireLanguage.g:6663:1: rule__VLSUnaryNegation__OperandAssignment_2 : ( ruleVLSUnitaryFormula ) ; public final void rule__VLSUnaryNegation__OperandAssignment_2() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6621:1: ( ( ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:6622:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6667:1: ( ( ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:6668:2: ( ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:6622:2: ( ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:6623:3: ruleVLSUnitaryFormula + // InternalVampireLanguage.g:6668:2: ( ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:6669:3: ruleVLSUnitaryFormula { before(grammarAccess.getVLSUnaryNegationAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); pushFollow(FOLLOW_2); @@ -20314,17 +20447,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSUnaryInfix__RightAssignment_1_1" - // InternalVampireLanguage.g:6632:1: rule__VLSUnaryInfix__RightAssignment_1_1 : ( ruleVLSAtomic ) ; + // InternalVampireLanguage.g:6678:1: rule__VLSUnaryInfix__RightAssignment_1_1 : ( ruleVLSAtomic ) ; public final void rule__VLSUnaryInfix__RightAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6636:1: ( ( ruleVLSAtomic ) ) - // InternalVampireLanguage.g:6637:2: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:6682:1: ( ( ruleVLSAtomic ) ) + // InternalVampireLanguage.g:6683:2: ( ruleVLSAtomic ) { - // InternalVampireLanguage.g:6637:2: ( ruleVLSAtomic ) - // InternalVampireLanguage.g:6638:3: ruleVLSAtomic + // InternalVampireLanguage.g:6683:2: ( ruleVLSAtomic ) + // InternalVampireLanguage.g:6684:3: ruleVLSAtomic { before(grammarAccess.getVLSUnaryInfixAccess().getRightVLSAtomicParserRuleCall_1_1_0()); pushFollow(FOLLOW_2); @@ -20355,21 +20488,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicConstant__NameAssignment_0_1" - // InternalVampireLanguage.g:6647:1: rule__VLSAtomicConstant__NameAssignment_0_1 : ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) ; + // InternalVampireLanguage.g:6693:1: rule__VLSAtomicConstant__NameAssignment_0_1 : ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) ; public final void rule__VLSAtomicConstant__NameAssignment_0_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6651:1: ( ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) ) - // InternalVampireLanguage.g:6652:2: ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) + // InternalVampireLanguage.g:6697:1: ( ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) ) + // InternalVampireLanguage.g:6698:2: ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) { - // InternalVampireLanguage.g:6652:2: ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) - // InternalVampireLanguage.g:6653:3: ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) + // InternalVampireLanguage.g:6698:2: ( ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) ) + // InternalVampireLanguage.g:6699:3: ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) { before(grammarAccess.getVLSAtomicConstantAccess().getNameAlternatives_0_1_0()); - // InternalVampireLanguage.g:6654:3: ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) - // InternalVampireLanguage.g:6654:4: rule__VLSAtomicConstant__NameAlternatives_0_1_0 + // InternalVampireLanguage.g:6700:3: ( rule__VLSAtomicConstant__NameAlternatives_0_1_0 ) + // InternalVampireLanguage.g:6700:4: rule__VLSAtomicConstant__NameAlternatives_0_1_0 { pushFollow(FOLLOW_2); rule__VLSAtomicConstant__NameAlternatives_0_1_0(); @@ -20402,21 +20535,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__ConstantAssignment_0_1" - // InternalVampireLanguage.g:6662:1: rule__VLSAtomicFunction__ConstantAssignment_0_1 : ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) ; + // InternalVampireLanguage.g:6708:1: rule__VLSAtomicFunction__ConstantAssignment_0_1 : ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) ; public final void rule__VLSAtomicFunction__ConstantAssignment_0_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6666:1: ( ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) ) - // InternalVampireLanguage.g:6667:2: ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) + // InternalVampireLanguage.g:6712:1: ( ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) ) + // InternalVampireLanguage.g:6713:2: ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) { - // InternalVampireLanguage.g:6667:2: ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) - // InternalVampireLanguage.g:6668:3: ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) + // InternalVampireLanguage.g:6713:2: ( ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) ) + // InternalVampireLanguage.g:6714:3: ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) { before(grammarAccess.getVLSAtomicFunctionAccess().getConstantAlternatives_0_1_0()); - // InternalVampireLanguage.g:6669:3: ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) - // InternalVampireLanguage.g:6669:4: rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 + // InternalVampireLanguage.g:6715:3: ( rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 ) + // InternalVampireLanguage.g:6715:4: rule__VLSAtomicFunction__ConstantAlternatives_0_1_0 { pushFollow(FOLLOW_2); rule__VLSAtomicFunction__ConstantAlternatives_0_1_0(); @@ -20449,17 +20582,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__TermsAssignment_0_2_1" - // InternalVampireLanguage.g:6677:1: rule__VLSAtomicFunction__TermsAssignment_0_2_1 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6723:1: rule__VLSAtomicFunction__TermsAssignment_0_2_1 : ( ruleVLSFofTerm ) ; public final void rule__VLSAtomicFunction__TermsAssignment_0_2_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6681:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6682:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6727:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6728:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6682:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6683:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6728:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6729:3: ruleVLSFofTerm { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_0_2_1_0()); pushFollow(FOLLOW_2); @@ -20490,17 +20623,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__TermsAssignment_0_2_2_1" - // InternalVampireLanguage.g:6692:1: rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6738:1: rule__VLSAtomicFunction__TermsAssignment_0_2_2_1 : ( ruleVLSFofTerm ) ; public final void rule__VLSAtomicFunction__TermsAssignment_0_2_2_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6696:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6697:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6742:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6743:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6697:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6698:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6743:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6744:3: ruleVLSFofTerm { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_0_2_2_1_0()); pushFollow(FOLLOW_2); @@ -20531,21 +20664,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__NameAssignment_1_1" - // InternalVampireLanguage.g:6707:1: rule__VLSAtomicFunction__NameAssignment_1_1 : ( ( '$less' ) ) ; + // InternalVampireLanguage.g:6753:1: rule__VLSAtomicFunction__NameAssignment_1_1 : ( ( '$less' ) ) ; public final void rule__VLSAtomicFunction__NameAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6711:1: ( ( ( '$less' ) ) ) - // InternalVampireLanguage.g:6712:2: ( ( '$less' ) ) + // InternalVampireLanguage.g:6757:1: ( ( ( '$less' ) ) ) + // InternalVampireLanguage.g:6758:2: ( ( '$less' ) ) { - // InternalVampireLanguage.g:6712:2: ( ( '$less' ) ) - // InternalVampireLanguage.g:6713:3: ( '$less' ) + // InternalVampireLanguage.g:6758:2: ( ( '$less' ) ) + // InternalVampireLanguage.g:6759:3: ( '$less' ) { before(grammarAccess.getVLSAtomicFunctionAccess().getNameLessKeyword_1_1_0()); - // InternalVampireLanguage.g:6714:3: ( '$less' ) - // InternalVampireLanguage.g:6715:4: '$less' + // InternalVampireLanguage.g:6760:3: ( '$less' ) + // InternalVampireLanguage.g:6761:4: '$less' { before(grammarAccess.getVLSAtomicFunctionAccess().getNameLessKeyword_1_1_0()); match(input,80,FOLLOW_2); @@ -20576,17 +20709,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__TermsAssignment_1_3" - // InternalVampireLanguage.g:6726:1: rule__VLSAtomicFunction__TermsAssignment_1_3 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6772:1: rule__VLSAtomicFunction__TermsAssignment_1_3 : ( ruleVLSFofTerm ) ; public final void rule__VLSAtomicFunction__TermsAssignment_1_3() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6730:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6731:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6776:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6777:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6731:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6732:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6777:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6778:3: ruleVLSFofTerm { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_1_3_0()); pushFollow(FOLLOW_2); @@ -20617,17 +20750,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSAtomicFunction__TermsAssignment_1_5" - // InternalVampireLanguage.g:6741:1: rule__VLSAtomicFunction__TermsAssignment_1_5 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6787:1: rule__VLSAtomicFunction__TermsAssignment_1_5 : ( ruleVLSFofTerm ) ; public final void rule__VLSAtomicFunction__TermsAssignment_1_5() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6745:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6746:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6791:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6792:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6746:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6747:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6792:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6793:3: ruleVLSFofTerm { before(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_1_5_0()); pushFollow(FOLLOW_2); @@ -20658,17 +20791,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSVariable__NameAssignment" - // InternalVampireLanguage.g:6756:1: rule__VLSVariable__NameAssignment : ( RULE_UPPER_WORD_ID ) ; + // InternalVampireLanguage.g:6802:1: rule__VLSVariable__NameAssignment : ( RULE_UPPER_WORD_ID ) ; public final void rule__VLSVariable__NameAssignment() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6760:1: ( ( RULE_UPPER_WORD_ID ) ) - // InternalVampireLanguage.g:6761:2: ( RULE_UPPER_WORD_ID ) + // InternalVampireLanguage.g:6806:1: ( ( RULE_UPPER_WORD_ID ) ) + // InternalVampireLanguage.g:6807:2: ( RULE_UPPER_WORD_ID ) { - // InternalVampireLanguage.g:6761:2: ( RULE_UPPER_WORD_ID ) - // InternalVampireLanguage.g:6762:3: RULE_UPPER_WORD_ID + // InternalVampireLanguage.g:6807:2: ( RULE_UPPER_WORD_ID ) + // InternalVampireLanguage.g:6808:3: RULE_UPPER_WORD_ID { before(grammarAccess.getVLSVariableAccess().getNameUPPER_WORD_IDTerminalRuleCall_0()); match(input,RULE_UPPER_WORD_ID,FOLLOW_2); @@ -20695,21 +20828,21 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__FunctorAssignment_0" - // InternalVampireLanguage.g:6771:1: rule__VLSFunctionAsTerm__FunctorAssignment_0 : ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) ; + // InternalVampireLanguage.g:6817:1: rule__VLSFunctionAsTerm__FunctorAssignment_0 : ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) ; public final void rule__VLSFunctionAsTerm__FunctorAssignment_0() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6775:1: ( ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) ) - // InternalVampireLanguage.g:6776:2: ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) + // InternalVampireLanguage.g:6821:1: ( ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) ) + // InternalVampireLanguage.g:6822:2: ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) { - // InternalVampireLanguage.g:6776:2: ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) - // InternalVampireLanguage.g:6777:3: ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) + // InternalVampireLanguage.g:6822:2: ( ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) ) + // InternalVampireLanguage.g:6823:3: ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) { before(grammarAccess.getVLSFunctionAsTermAccess().getFunctorAlternatives_0_0()); - // InternalVampireLanguage.g:6778:3: ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) - // InternalVampireLanguage.g:6778:4: rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 + // InternalVampireLanguage.g:6824:3: ( rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 ) + // InternalVampireLanguage.g:6824:4: rule__VLSFunctionAsTerm__FunctorAlternatives_0_0 { pushFollow(FOLLOW_2); rule__VLSFunctionAsTerm__FunctorAlternatives_0_0(); @@ -20742,17 +20875,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__TermsAssignment_1_1" - // InternalVampireLanguage.g:6786:1: rule__VLSFunctionAsTerm__TermsAssignment_1_1 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6832:1: rule__VLSFunctionAsTerm__TermsAssignment_1_1 : ( ruleVLSFofTerm ) ; public final void rule__VLSFunctionAsTerm__TermsAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6790:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6791:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6836:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6837:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6791:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6792:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6837:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6838:3: ruleVLSFofTerm { before(grammarAccess.getVLSFunctionAsTermAccess().getTermsVLSFofTermParserRuleCall_1_1_0()); pushFollow(FOLLOW_2); @@ -20783,17 +20916,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSFunctionAsTerm__TermsAssignment_1_2_1" - // InternalVampireLanguage.g:6801:1: rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 : ( ruleVLSFofTerm ) ; + // InternalVampireLanguage.g:6847:1: rule__VLSFunctionAsTerm__TermsAssignment_1_2_1 : ( ruleVLSFofTerm ) ; public final void rule__VLSFunctionAsTerm__TermsAssignment_1_2_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6805:1: ( ( ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:6806:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6851:1: ( ( ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:6852:2: ( ruleVLSFofTerm ) { - // InternalVampireLanguage.g:6806:2: ( ruleVLSFofTerm ) - // InternalVampireLanguage.g:6807:3: ruleVLSFofTerm + // InternalVampireLanguage.g:6852:2: ( ruleVLSFofTerm ) + // InternalVampireLanguage.g:6853:3: ruleVLSFofTerm { before(grammarAccess.getVLSFunctionAsTermAccess().getTermsVLSFofTermParserRuleCall_1_2_1_0()); pushFollow(FOLLOW_2); @@ -20824,17 +20957,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__ValueAssignment_0_1" - // InternalVampireLanguage.g:6816:1: rule__VLSDefinedTerm__ValueAssignment_0_1 : ( RULE_SIGNED_LITERAL ) ; + // InternalVampireLanguage.g:6862:1: rule__VLSDefinedTerm__ValueAssignment_0_1 : ( RULE_SIGNED_LITERAL ) ; public final void rule__VLSDefinedTerm__ValueAssignment_0_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6820:1: ( ( RULE_SIGNED_LITERAL ) ) - // InternalVampireLanguage.g:6821:2: ( RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:6866:1: ( ( RULE_SIGNED_LITERAL ) ) + // InternalVampireLanguage.g:6867:2: ( RULE_SIGNED_LITERAL ) { - // InternalVampireLanguage.g:6821:2: ( RULE_SIGNED_LITERAL ) - // InternalVampireLanguage.g:6822:3: RULE_SIGNED_LITERAL + // InternalVampireLanguage.g:6867:2: ( RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:6868:3: RULE_SIGNED_LITERAL { before(grammarAccess.getVLSDefinedTermAccess().getValueSIGNED_LITERALTerminalRuleCall_0_1_0()); match(input,RULE_SIGNED_LITERAL,FOLLOW_2); @@ -20861,17 +20994,17 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist // $ANTLR start "rule__VLSDefinedTerm__ValueAssignment_1_1" - // InternalVampireLanguage.g:6831:1: rule__VLSDefinedTerm__ValueAssignment_1_1 : ( RULE_DOUBLE_QUOTE ) ; + // InternalVampireLanguage.g:6877:1: rule__VLSDefinedTerm__ValueAssignment_1_1 : ( RULE_DOUBLE_QUOTE ) ; public final void rule__VLSDefinedTerm__ValueAssignment_1_1() throws RecognitionException { int stackSize = keepStackSize(); try { - // InternalVampireLanguage.g:6835:1: ( ( RULE_DOUBLE_QUOTE ) ) - // InternalVampireLanguage.g:6836:2: ( RULE_DOUBLE_QUOTE ) + // InternalVampireLanguage.g:6881:1: ( ( RULE_DOUBLE_QUOTE ) ) + // InternalVampireLanguage.g:6882:2: ( RULE_DOUBLE_QUOTE ) { - // InternalVampireLanguage.g:6836:2: ( RULE_DOUBLE_QUOTE ) - // InternalVampireLanguage.g:6837:3: RULE_DOUBLE_QUOTE + // InternalVampireLanguage.g:6882:2: ( RULE_DOUBLE_QUOTE ) + // InternalVampireLanguage.g:6883:3: RULE_DOUBLE_QUOTE { before(grammarAccess.getVLSDefinedTermAccess().getValueDOUBLE_QUOTETerminalRuleCall_1_1_0()); match(input,RULE_DOUBLE_QUOTE,FOLLOW_2); @@ -20901,37 +21034,38 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist protected DFA9 dfa9 = new DFA9(this); protected DFA21 dfa21 = new DFA21(this); - static final String dfa_1s = "\31\uffff"; - static final String dfa_2s = "\2\uffff\26\1\1\uffff"; - static final String dfa_3s = "\1\4\1\uffff\23\67\3\70\1\uffff"; - static final String dfa_4s = "\1\120\1\uffff\26\115\1\uffff"; - static final String dfa_5s = "\1\uffff\1\1\26\uffff\1\2"; - static final String dfa_6s = "\31\uffff}>"; + static final String dfa_1s = "\32\uffff"; + static final String dfa_2s = "\2\uffff\26\1\2\uffff"; + static final String dfa_3s = "\1\4\1\uffff\23\67\3\70\2\uffff"; + static final String dfa_4s = "\1\120\1\uffff\26\115\2\uffff"; + static final String dfa_5s = "\1\uffff\1\1\26\uffff\1\3\1\2"; + static final String dfa_6s = "\32\uffff}>"; static final String[] dfa_7s = { - "\1\2\1\1\1\3\1\4\1\5\2\uffff\1\27\1\1\13\uffff\1\6\1\7\1\10\1\11\1\12\1\13\1\14\1\15\1\16\1\17\1\20\1\21\1\22\1\23\1\24\20\uffff\1\1\20\uffff\3\1\3\uffff\1\25\1\26\1\1", + "\1\2\1\1\1\3\1\4\1\5\1\30\1\uffff\1\27\1\1\13\uffff\1\6\1\7\1\10\1\11\1\12\1\13\1\14\1\15\1\16\1\17\1\20\1\21\1\22\1\23\1\24\20\uffff\1\1\20\uffff\3\1\3\uffff\1\25\1\26\1\1", + "", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\3\uffff\1\31\2\uffff\10\1\3\uffff\3\1", "", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\3\uffff\1\30\2\uffff\10\1\3\uffff\3\1", "" }; @@ -20957,7 +21091,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist this.transition = dfa_7; } public String getDescription() { - return "1119:1: rule__VLSTffTerm__Alternatives : ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) );"; + return "1144:1: rule__VLSTffTerm__Alternatives : ( ( ruleVLSTerm ) | ( ruleVLSDeclaration ) | ( ruleVLSCommentTerm ) );"; } } static final String dfa_8s = "\30\uffff"; @@ -21015,7 +21149,7 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist this.transition = dfa_14; } public String getDescription() { - return "1397:1: rule__VLSAtomic__Alternatives : ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) );"; + return "1428:1: rule__VLSAtomic__Alternatives : ( ( ruleVLSAtomicConstant ) | ( ruleVLSAtomicFunction ) | ( ruleVLSVariable ) | ( ruleVLSDefinedTerm ) );"; } } @@ -21050,35 +21184,36 @@ public class InternalVampireLanguageParser extends AbstractInternalContentAssist public static final BitSet FOLLOW_28 = new BitSet(new long[]{0x0400000000000000L}); public static final BitSet FOLLOW_29 = new BitSet(new long[]{0x0086007FFF000050L}); public static final BitSet FOLLOW_30 = new BitSet(new long[]{0x1000000000C00010L}); - public static final BitSet FOLLOW_31 = new BitSet(new long[]{0x0000000000000080L}); - public static final BitSet FOLLOW_32 = new BitSet(new long[]{0x0200000000000000L}); - public static final BitSet FOLLOW_33 = new BitSet(new long[]{0x0100000000000002L}); - public static final BitSet FOLLOW_34 = new BitSet(new long[]{0x2000000000000000L}); - public static final BitSet FOLLOW_35 = new BitSet(new long[]{0x0000007FFF0019F0L,0x000000000001C000L}); - public static final BitSet FOLLOW_36 = new BitSet(new long[]{0x4000000000000000L}); - public static final BitSet FOLLOW_37 = new BitSet(new long[]{0x0000007FFF0001D0L,0x000000000000C000L}); - public static final BitSet FOLLOW_38 = new BitSet(new long[]{0x8000000000000000L}); - public static final BitSet FOLLOW_39 = new BitSet(new long[]{0x8000000000000002L}); - public static final BitSet FOLLOW_40 = new BitSet(new long[]{0x0000000000000000L,0x00000000000000FFL}); - public static final BitSet FOLLOW_41 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000001L}); - public static final BitSet FOLLOW_42 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000002L}); - public static final BitSet FOLLOW_43 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000004L}); - public static final BitSet FOLLOW_44 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000008L}); - public static final BitSet FOLLOW_45 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000010L}); - public static final BitSet FOLLOW_46 = new BitSet(new long[]{0x0000000000000000L,0x000000000000003FL}); - public static final BitSet FOLLOW_47 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000040L}); - public static final BitSet FOLLOW_48 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000080L}); - public static final BitSet FOLLOW_49 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000100L}); - public static final BitSet FOLLOW_50 = new BitSet(new long[]{0x0000000000000800L}); - public static final BitSet FOLLOW_51 = new BitSet(new long[]{0x0104000000000000L}); - public static final BitSet FOLLOW_52 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000200L}); - public static final BitSet FOLLOW_53 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000400L}); - public static final BitSet FOLLOW_54 = new BitSet(new long[]{0x0000000000000000L,0x0000000000003800L}); - public static final BitSet FOLLOW_55 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000800L}); - public static final BitSet FOLLOW_56 = new BitSet(new long[]{0x0000000000000000L,0x0000000000001000L}); - public static final BitSet FOLLOW_57 = new BitSet(new long[]{0x0000007FFF0001D0L}); - public static final BitSet FOLLOW_58 = new BitSet(new long[]{0x0000000000000000L,0x0000000000004000L}); - public static final BitSet FOLLOW_59 = new BitSet(new long[]{0x0000007FFF0001D0L,0x0000000000010000L}); - public static final BitSet FOLLOW_60 = new BitSet(new long[]{0x0000000000000020L}); + public static final BitSet FOLLOW_31 = new BitSet(new long[]{0x0080007FFF001BF0L,0x000000000001C700L}); + public static final BitSet FOLLOW_32 = new BitSet(new long[]{0x0000000000000080L}); + public static final BitSet FOLLOW_33 = new BitSet(new long[]{0x0200000000000000L}); + public static final BitSet FOLLOW_34 = new BitSet(new long[]{0x0100000000000002L}); + public static final BitSet FOLLOW_35 = new BitSet(new long[]{0x2000000000000000L}); + public static final BitSet FOLLOW_36 = new BitSet(new long[]{0x0000007FFF0019F0L,0x000000000001C000L}); + public static final BitSet FOLLOW_37 = new BitSet(new long[]{0x4000000000000000L}); + public static final BitSet FOLLOW_38 = new BitSet(new long[]{0x0000007FFF0001D0L,0x000000000000C000L}); + public static final BitSet FOLLOW_39 = new BitSet(new long[]{0x8000000000000000L}); + public static final BitSet FOLLOW_40 = new BitSet(new long[]{0x8000000000000002L}); + public static final BitSet FOLLOW_41 = new BitSet(new long[]{0x0000000000000000L,0x00000000000000FFL}); + public static final BitSet FOLLOW_42 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000001L}); + public static final BitSet FOLLOW_43 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000002L}); + public static final BitSet FOLLOW_44 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000004L}); + public static final BitSet FOLLOW_45 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000008L}); + public static final BitSet FOLLOW_46 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000010L}); + public static final BitSet FOLLOW_47 = new BitSet(new long[]{0x0000000000000000L,0x000000000000003FL}); + public static final BitSet FOLLOW_48 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000040L}); + public static final BitSet FOLLOW_49 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000080L}); + public static final BitSet FOLLOW_50 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000100L}); + public static final BitSet FOLLOW_51 = new BitSet(new long[]{0x0000000000000800L}); + public static final BitSet FOLLOW_52 = new BitSet(new long[]{0x0104000000000000L}); + public static final BitSet FOLLOW_53 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000200L}); + public static final BitSet FOLLOW_54 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000400L}); + public static final BitSet FOLLOW_55 = new BitSet(new long[]{0x0000000000000000L,0x0000000000003800L}); + public static final BitSet FOLLOW_56 = new BitSet(new long[]{0x0000000000000000L,0x0000000000000800L}); + public static final BitSet FOLLOW_57 = new BitSet(new long[]{0x0000000000000000L,0x0000000000001000L}); + public static final BitSet FOLLOW_58 = new BitSet(new long[]{0x0000007FFF0001D0L}); + public static final BitSet FOLLOW_59 = new BitSet(new long[]{0x0000000000000000L,0x0000000000004000L}); + public static final BitSet FOLLOW_60 = new BitSet(new long[]{0x0000007FFF0001D0L,0x0000000000010000L}); + public static final BitSet FOLLOW_61 = new BitSet(new long[]{0x0000000000000020L}); } \ No newline at end of file diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 0aefc3c7..2a46499b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index f93445d1..e5f3b018 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/src-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/AbstractVampireLanguageProposalProvider.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/src-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/AbstractVampireLanguageProposalProvider.java index a76460ba..84b77335 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/src-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/AbstractVampireLanguageProposalProvider.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/src-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/AbstractVampireLanguageProposalProvider.java @@ -73,6 +73,9 @@ public abstract class AbstractVampireLanguageProposalProvider extends TerminalsP public void completeVLSAnnotationTerms_Terms(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); } + public void completeVLSCommentTerm_Comment(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { + completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); + } public void completeVLSOtherDeclaration_Name(EObject model, Assignment assignment, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { completeRuleCall(((RuleCall)assignment.getTerminal()), context, acceptor); } @@ -228,6 +231,9 @@ public abstract class AbstractVampireLanguageProposalProvider extends TerminalsP public void complete_VLSTffTerm(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { // subclasses may override } + public void complete_VLSCommentTerm(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { + // subclasses may override + } public void complete_VLSDeclaration(EObject model, RuleCall ruleCall, ContentAssistContext context, ICompletionProposalAcceptor acceptor) { // subclasses may override } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 4266e495..cdc646f3 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index ff67b75e..8d3c30f6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 67f6087a..40d6d3a8 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index ebd73974..999df988 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index cdb3137a..b3a37f45 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 62560a49..dcca29b0 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.ecore b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.ecore index 1ba1bbf7..49f8b3a9 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.ecore +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.ecore @@ -40,6 +40,9 @@ eType="#//VLSAnnotation" containment="true"/> + + + @@ -62,7 +65,6 @@ - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.genmodel b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.genmodel index 7800e85e..cb3c1036 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.genmodel +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/model/generated/VampireLanguage.genmodel @@ -34,6 +34,9 @@ + + + @@ -49,7 +52,6 @@ - diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtextbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtextbin index 0b7b2a35..e5a377b6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtextbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtextbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguage.g b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguage.g index 6edaf50e..231a525b 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguage.g +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguage.g @@ -1061,6 +1061,50 @@ ruleVLSTffTerm returns [EObject current=null] $current = $this_VLSDeclaration_1.current; afterParserOrEnumRuleCall(); } + | + { + newCompositeNode(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); + } + this_VLSCommentTerm_2=ruleVLSCommentTerm + { + $current = $this_VLSCommentTerm_2.current; + afterParserOrEnumRuleCall(); + } + ) +; + +// Entry rule entryRuleVLSCommentTerm +entryRuleVLSCommentTerm returns [EObject current=null]: + { newCompositeNode(grammarAccess.getVLSCommentTermRule()); } + iv_ruleVLSCommentTerm=ruleVLSCommentTerm + { $current=$iv_ruleVLSCommentTerm.current; } + EOF; + +// Rule VLSCommentTerm +ruleVLSCommentTerm returns [EObject current=null] +@init { + enterRule(); +} +@after { + leaveRule(); +}: + ( + ( + lv_comment_0_0=RULE_SINGLE_COMMENT + { + newLeafNode(lv_comment_0_0, grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); + } + { + if ($current==null) { + $current = createModelElement(grammarAccess.getVLSCommentTermRule()); + } + setWithLastConsumed( + $current, + "comment", + lv_comment_0_0, + "ca.mcgill.ecse.dslreasoner.VampireLanguage.SINGLE_COMMENT"); + } + ) ) ; diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageLexer.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageLexer.java index a35c88e6..f3377c74 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageLexer.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageLexer.java @@ -1331,8 +1331,8 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_ALPHA_NUMERIC" public final void mRULE_ALPHA_NUMERIC() throws RecognitionException { try { - // InternalVampireLanguage.g:2796:29: ( ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) ) - // InternalVampireLanguage.g:2796:31: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) + // InternalVampireLanguage.g:2840:29: ( ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) ) + // InternalVampireLanguage.g:2840:31: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' ) { if ( (input.LA(1)>='0' && input.LA(1)<='9')||(input.LA(1)>='A' && input.LA(1)<='Z')||input.LA(1)=='_'||(input.LA(1)>='a' && input.LA(1)<='z') ) { input.consume(); @@ -1357,11 +1357,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_UPPER_WORD_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2798:20: ( 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* ) - // InternalVampireLanguage.g:2798:22: 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:2842:20: ( 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* ) + // InternalVampireLanguage.g:2842:22: 'A' .. 'Z' ( RULE_ALPHA_NUMERIC )* { matchRange('A','Z'); - // InternalVampireLanguage.g:2798:31: ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:2842:31: ( RULE_ALPHA_NUMERIC )* loop1: do { int alt1=2; @@ -1374,7 +1374,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt1) { case 1 : - // InternalVampireLanguage.g:2798:31: RULE_ALPHA_NUMERIC + // InternalVampireLanguage.g:2842:31: RULE_ALPHA_NUMERIC { mRULE_ALPHA_NUMERIC(); @@ -1402,11 +1402,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_LOWER_WORD_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2800:20: ( 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* ) - // InternalVampireLanguage.g:2800:22: 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:2844:20: ( 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* ) + // InternalVampireLanguage.g:2844:22: 'a' .. 'z' ( RULE_ALPHA_NUMERIC )* { matchRange('a','z'); - // InternalVampireLanguage.g:2800:31: ( RULE_ALPHA_NUMERIC )* + // InternalVampireLanguage.g:2844:31: ( RULE_ALPHA_NUMERIC )* loop2: do { int alt2=2; @@ -1419,7 +1419,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt2) { case 1 : - // InternalVampireLanguage.g:2800:31: RULE_ALPHA_NUMERIC + // InternalVampireLanguage.g:2844:31: RULE_ALPHA_NUMERIC { mRULE_ALPHA_NUMERIC(); @@ -1447,11 +1447,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOUBLE_QUOTE; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2802:19: ( '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' ) - // InternalVampireLanguage.g:2802:21: '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' + // InternalVampireLanguage.g:2846:19: ( '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' ) + // InternalVampireLanguage.g:2846:21: '\"' ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* '\"' { match('\"'); - // InternalVampireLanguage.g:2802:25: ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* + // InternalVampireLanguage.g:2846:25: ( '\\\\' ( '\"' | '\\\\' ) | ~ ( ( '\\\\' | '\"' ) ) )* loop3: do { int alt3=3; @@ -1467,7 +1467,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt3) { case 1 : - // InternalVampireLanguage.g:2802:26: '\\\\' ( '\"' | '\\\\' ) + // InternalVampireLanguage.g:2846:26: '\\\\' ( '\"' | '\\\\' ) { match('\\'); if ( input.LA(1)=='\"'||input.LA(1)=='\\' ) { @@ -1483,7 +1483,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:2802:42: ~ ( ( '\\\\' | '\"' ) ) + // InternalVampireLanguage.g:2846:42: ~ ( ( '\\\\' | '\"' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='!')||(input.LA(1)>='#' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1520,11 +1520,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SINGLE_QUOTE; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2804:19: ( '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' ) - // InternalVampireLanguage.g:2804:21: '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' + // InternalVampireLanguage.g:2848:19: ( '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' ) + // InternalVampireLanguage.g:2848:21: '\\'' ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ '\\'' { match('\''); - // InternalVampireLanguage.g:2804:26: ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ + // InternalVampireLanguage.g:2848:26: ( '\\\\' ( '\\'' | '\\\\' ) | ~ ( ( '\\\\' | '\\'' ) ) )+ int cnt4=0; loop4: do { @@ -1541,7 +1541,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt4) { case 1 : - // InternalVampireLanguage.g:2804:27: '\\\\' ( '\\'' | '\\\\' ) + // InternalVampireLanguage.g:2848:27: '\\\\' ( '\\'' | '\\\\' ) { match('\\'); if ( input.LA(1)=='\''||input.LA(1)=='\\' ) { @@ -1557,7 +1557,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:2804:44: ~ ( ( '\\\\' | '\\'' ) ) + // InternalVampireLanguage.g:2848:44: ~ ( ( '\\\\' | '\\'' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='&')||(input.LA(1)>='(' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1596,8 +1596,8 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_SIGN" public final void mRULE_SIGN() throws RecognitionException { try { - // InternalVampireLanguage.g:2806:20: ( ( '+' | '-' ) ) - // InternalVampireLanguage.g:2806:22: ( '+' | '-' ) + // InternalVampireLanguage.g:2850:20: ( ( '+' | '-' ) ) + // InternalVampireLanguage.g:2850:22: ( '+' | '-' ) { if ( input.LA(1)=='+'||input.LA(1)=='-' ) { input.consume(); @@ -1622,8 +1622,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOLLAR_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2808:16: ( '$' RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:2808:18: '$' RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:2852:16: ( '$' RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:2852:18: '$' RULE_LOWER_WORD_ID { match('$'); mRULE_LOWER_WORD_ID(); @@ -1643,8 +1643,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_DOUBLE_DOLLAR_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2810:23: ( '$$' RULE_LOWER_WORD_ID ) - // InternalVampireLanguage.g:2810:25: '$$' RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:2854:23: ( '$$' RULE_LOWER_WORD_ID ) + // InternalVampireLanguage.g:2854:25: '$$' RULE_LOWER_WORD_ID { match("$$"); @@ -1665,10 +1665,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_LITERAL; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2812:14: ( ( '0' | '1' .. '9' ( RULE_INT )? ) ) - // InternalVampireLanguage.g:2812:16: ( '0' | '1' .. '9' ( RULE_INT )? ) + // InternalVampireLanguage.g:2856:14: ( ( '0' | '1' .. '9' ( RULE_INT )? ) ) + // InternalVampireLanguage.g:2856:16: ( '0' | '1' .. '9' ( RULE_INT )? ) { - // InternalVampireLanguage.g:2812:16: ( '0' | '1' .. '9' ( RULE_INT )? ) + // InternalVampireLanguage.g:2856:16: ( '0' | '1' .. '9' ( RULE_INT )? ) int alt6=2; int LA6_0 = input.LA(1); @@ -1686,17 +1686,17 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt6) { case 1 : - // InternalVampireLanguage.g:2812:17: '0' + // InternalVampireLanguage.g:2856:17: '0' { match('0'); } break; case 2 : - // InternalVampireLanguage.g:2812:21: '1' .. '9' ( RULE_INT )? + // InternalVampireLanguage.g:2856:21: '1' .. '9' ( RULE_INT )? { matchRange('1','9'); - // InternalVampireLanguage.g:2812:30: ( RULE_INT )? + // InternalVampireLanguage.g:2856:30: ( RULE_INT )? int alt5=2; int LA5_0 = input.LA(1); @@ -1705,7 +1705,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt5) { case 1 : - // InternalVampireLanguage.g:2812:30: RULE_INT + // InternalVampireLanguage.g:2856:30: RULE_INT { mRULE_INT(); @@ -1736,10 +1736,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SIGNED_LITERAL; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2814:21: ( ( RULE_SIGN )* RULE_LITERAL ) - // InternalVampireLanguage.g:2814:23: ( RULE_SIGN )* RULE_LITERAL + // InternalVampireLanguage.g:2858:21: ( ( RULE_SIGN )* RULE_LITERAL ) + // InternalVampireLanguage.g:2858:23: ( RULE_SIGN )* RULE_LITERAL { - // InternalVampireLanguage.g:2814:23: ( RULE_SIGN )* + // InternalVampireLanguage.g:2858:23: ( RULE_SIGN )* loop7: do { int alt7=2; @@ -1752,7 +1752,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt7) { case 1 : - // InternalVampireLanguage.g:2814:23: RULE_SIGN + // InternalVampireLanguage.g:2858:23: RULE_SIGN { mRULE_SIGN(); @@ -1781,11 +1781,11 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SINGLE_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2816:21: ( '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) - // InternalVampireLanguage.g:2816:23: '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:2860:21: ( '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) + // InternalVampireLanguage.g:2860:23: '%' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? { match('%'); - // InternalVampireLanguage.g:2816:27: (~ ( ( '\\n' | '\\r' ) ) )* + // InternalVampireLanguage.g:2860:27: (~ ( ( '\\n' | '\\r' ) ) )* loop8: do { int alt8=2; @@ -1798,7 +1798,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt8) { case 1 : - // InternalVampireLanguage.g:2816:27: ~ ( ( '\\n' | '\\r' ) ) + // InternalVampireLanguage.g:2860:27: ~ ( ( '\\n' | '\\r' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='\t')||(input.LA(1)>='\u000B' && input.LA(1)<='\f')||(input.LA(1)>='\u000E' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -1818,7 +1818,7 @@ public class InternalVampireLanguageLexer extends Lexer { } } while (true); - // InternalVampireLanguage.g:2816:43: ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:2860:43: ( ( '\\r' )? '\\n' )? int alt10=2; int LA10_0 = input.LA(1); @@ -1827,9 +1827,9 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt10) { case 1 : - // InternalVampireLanguage.g:2816:44: ( '\\r' )? '\\n' + // InternalVampireLanguage.g:2860:44: ( '\\r' )? '\\n' { - // InternalVampireLanguage.g:2816:44: ( '\\r' )? + // InternalVampireLanguage.g:2860:44: ( '\\r' )? int alt9=2; int LA9_0 = input.LA(1); @@ -1838,7 +1838,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt9) { case 1 : - // InternalVampireLanguage.g:2816:44: '\\r' + // InternalVampireLanguage.g:2860:44: '\\r' { match('\r'); @@ -1870,10 +1870,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ID; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2818:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* ) - // InternalVampireLanguage.g:2818:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* + // InternalVampireLanguage.g:2862:9: ( ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* ) + // InternalVampireLanguage.g:2862:11: ( '^' )? ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* { - // InternalVampireLanguage.g:2818:11: ( '^' )? + // InternalVampireLanguage.g:2862:11: ( '^' )? int alt11=2; int LA11_0 = input.LA(1); @@ -1882,7 +1882,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt11) { case 1 : - // InternalVampireLanguage.g:2818:11: '^' + // InternalVampireLanguage.g:2862:11: '^' { match('^'); @@ -1900,7 +1900,7 @@ public class InternalVampireLanguageLexer extends Lexer { recover(mse); throw mse;} - // InternalVampireLanguage.g:2818:40: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* + // InternalVampireLanguage.g:2862:40: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* loop12: do { int alt12=2; @@ -1947,10 +1947,10 @@ public class InternalVampireLanguageLexer extends Lexer { // $ANTLR start "RULE_INT" public final void mRULE_INT() throws RecognitionException { try { - // InternalVampireLanguage.g:2820:19: ( ( '0' .. '9' )+ ) - // InternalVampireLanguage.g:2820:21: ( '0' .. '9' )+ + // InternalVampireLanguage.g:2864:19: ( ( '0' .. '9' )+ ) + // InternalVampireLanguage.g:2864:21: ( '0' .. '9' )+ { - // InternalVampireLanguage.g:2820:21: ( '0' .. '9' )+ + // InternalVampireLanguage.g:2864:21: ( '0' .. '9' )+ int cnt13=0; loop13: do { @@ -1964,7 +1964,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt13) { case 1 : - // InternalVampireLanguage.g:2820:22: '0' .. '9' + // InternalVampireLanguage.g:2864:22: '0' .. '9' { matchRange('0','9'); @@ -1994,10 +1994,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_STRING; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2822:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) ) - // InternalVampireLanguage.g:2822:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) + // InternalVampireLanguage.g:2866:13: ( ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) ) + // InternalVampireLanguage.g:2866:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) { - // InternalVampireLanguage.g:2822:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) + // InternalVampireLanguage.g:2866:15: ( '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' | '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' ) int alt16=2; int LA16_0 = input.LA(1); @@ -2015,10 +2015,10 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt16) { case 1 : - // InternalVampireLanguage.g:2822:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' + // InternalVampireLanguage.g:2866:16: '\"' ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* '\"' { match('\"'); - // InternalVampireLanguage.g:2822:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* + // InternalVampireLanguage.g:2866:20: ( '\\\\' . | ~ ( ( '\\\\' | '\"' ) ) )* loop14: do { int alt14=3; @@ -2034,7 +2034,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt14) { case 1 : - // InternalVampireLanguage.g:2822:21: '\\\\' . + // InternalVampireLanguage.g:2866:21: '\\\\' . { match('\\'); matchAny(); @@ -2042,7 +2042,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:2822:28: ~ ( ( '\\\\' | '\"' ) ) + // InternalVampireLanguage.g:2866:28: ~ ( ( '\\\\' | '\"' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='!')||(input.LA(1)>='#' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2067,10 +2067,10 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:2822:48: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' + // InternalVampireLanguage.g:2866:48: '\\'' ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* '\\'' { match('\''); - // InternalVampireLanguage.g:2822:53: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* + // InternalVampireLanguage.g:2866:53: ( '\\\\' . | ~ ( ( '\\\\' | '\\'' ) ) )* loop15: do { int alt15=3; @@ -2086,7 +2086,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt15) { case 1 : - // InternalVampireLanguage.g:2822:54: '\\\\' . + // InternalVampireLanguage.g:2866:54: '\\\\' . { match('\\'); matchAny(); @@ -2094,7 +2094,7 @@ public class InternalVampireLanguageLexer extends Lexer { } break; case 2 : - // InternalVampireLanguage.g:2822:61: ~ ( ( '\\\\' | '\\'' ) ) + // InternalVampireLanguage.g:2866:61: ~ ( ( '\\\\' | '\\'' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='&')||(input.LA(1)>='(' && input.LA(1)<='[')||(input.LA(1)>=']' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2137,12 +2137,12 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ML_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2824:17: ( '/*' ( options {greedy=false; } : . )* '*/' ) - // InternalVampireLanguage.g:2824:19: '/*' ( options {greedy=false; } : . )* '*/' + // InternalVampireLanguage.g:2868:17: ( '/*' ( options {greedy=false; } : . )* '*/' ) + // InternalVampireLanguage.g:2868:19: '/*' ( options {greedy=false; } : . )* '*/' { match("/*"); - // InternalVampireLanguage.g:2824:24: ( options {greedy=false; } : . )* + // InternalVampireLanguage.g:2868:24: ( options {greedy=false; } : . )* loop17: do { int alt17=2; @@ -2167,7 +2167,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt17) { case 1 : - // InternalVampireLanguage.g:2824:52: . + // InternalVampireLanguage.g:2868:52: . { matchAny(); @@ -2197,12 +2197,12 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_SL_COMMENT; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2826:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) - // InternalVampireLanguage.g:2826:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:2870:17: ( '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? ) + // InternalVampireLanguage.g:2870:19: '//' (~ ( ( '\\n' | '\\r' ) ) )* ( ( '\\r' )? '\\n' )? { match("//"); - // InternalVampireLanguage.g:2826:24: (~ ( ( '\\n' | '\\r' ) ) )* + // InternalVampireLanguage.g:2870:24: (~ ( ( '\\n' | '\\r' ) ) )* loop18: do { int alt18=2; @@ -2215,7 +2215,7 @@ public class InternalVampireLanguageLexer extends Lexer { switch (alt18) { case 1 : - // InternalVampireLanguage.g:2826:24: ~ ( ( '\\n' | '\\r' ) ) + // InternalVampireLanguage.g:2870:24: ~ ( ( '\\n' | '\\r' ) ) { if ( (input.LA(1)>='\u0000' && input.LA(1)<='\t')||(input.LA(1)>='\u000B' && input.LA(1)<='\f')||(input.LA(1)>='\u000E' && input.LA(1)<='\uFFFF') ) { input.consume(); @@ -2235,7 +2235,7 @@ public class InternalVampireLanguageLexer extends Lexer { } } while (true); - // InternalVampireLanguage.g:2826:40: ( ( '\\r' )? '\\n' )? + // InternalVampireLanguage.g:2870:40: ( ( '\\r' )? '\\n' )? int alt20=2; int LA20_0 = input.LA(1); @@ -2244,9 +2244,9 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt20) { case 1 : - // InternalVampireLanguage.g:2826:41: ( '\\r' )? '\\n' + // InternalVampireLanguage.g:2870:41: ( '\\r' )? '\\n' { - // InternalVampireLanguage.g:2826:41: ( '\\r' )? + // InternalVampireLanguage.g:2870:41: ( '\\r' )? int alt19=2; int LA19_0 = input.LA(1); @@ -2255,7 +2255,7 @@ public class InternalVampireLanguageLexer extends Lexer { } switch (alt19) { case 1 : - // InternalVampireLanguage.g:2826:41: '\\r' + // InternalVampireLanguage.g:2870:41: '\\r' { match('\r'); @@ -2287,10 +2287,10 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_WS; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2828:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ ) - // InternalVampireLanguage.g:2828:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ + // InternalVampireLanguage.g:2872:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ ) + // InternalVampireLanguage.g:2872:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ { - // InternalVampireLanguage.g:2828:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ + // InternalVampireLanguage.g:2872:11: ( ' ' | '\\t' | '\\r' | '\\n' )+ int cnt21=0; loop21: do { @@ -2344,8 +2344,8 @@ public class InternalVampireLanguageLexer extends Lexer { try { int _type = RULE_ANY_OTHER; int _channel = DEFAULT_TOKEN_CHANNEL; - // InternalVampireLanguage.g:2830:16: ( . ) - // InternalVampireLanguage.g:2830:18: . + // InternalVampireLanguage.g:2874:16: ( . ) + // InternalVampireLanguage.g:2874:18: . { matchAny(); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageParser.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageParser.java index bf37606b..910e3422 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageParser.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/parser/antlr/internal/InternalVampireLanguageParser.java @@ -1264,7 +1264,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_5=(Token)match(input,39,FOLLOW_20); + otherlv_5=(Token)match(input,39,FOLLOW_26); newLeafNode(otherlv_5, grammarAccess.getVLSTffFormulaAccess().getCommaKeyword_5()); @@ -1768,7 +1768,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // InternalVampireLanguage.g:724:3: (kw= 'declare_' this_DOLLAR_ID_1= RULE_DOLLAR_ID ) // InternalVampireLanguage.g:725:4: kw= 'declare_' this_DOLLAR_ID_1= RULE_DOLLAR_ID { - kw=(Token)match(input,45,FOLLOW_26); + kw=(Token)match(input,45,FOLLOW_27); current.merge(kw); newLeafNode(kw, grammarAccess.getVLSTffDeclPredAccess().getDeclare_Keyword_0_0()); @@ -2217,7 +2217,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { case 1 : // InternalVampireLanguage.g:874:4: otherlv_0= '[' { - otherlv_0=(Token)match(input,32,FOLLOW_27); + otherlv_0=(Token)match(input,32,FOLLOW_28); newLeafNode(otherlv_0, grammarAccess.getVLSAnnotationAccess().getLeftSquareBracketKeyword_0()); @@ -2284,7 +2284,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { case 1 : // InternalVampireLanguage.g:882:6: lv_name_1_1= RULE_LOWER_WORD_ID { - lv_name_1_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_28); + lv_name_1_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_29); newLeafNode(lv_name_1_1, grammarAccess.getVLSAnnotationAccess().getNameLOWER_WORD_IDTerminalRuleCall_1_0_0()); @@ -2304,7 +2304,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { case 2 : // InternalVampireLanguage.g:897:6: lv_name_1_2= RULE_SINGLE_QUOTE { - lv_name_1_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_28); + lv_name_1_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_29); newLeafNode(lv_name_1_2, grammarAccess.getVLSAnnotationAccess().getNameSINGLE_QUOTETerminalRuleCall_1_0_1()); @@ -2327,7 +2327,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newCompositeNode(grammarAccess.getVLSAnnotationAccess().getNameVLSRoleParserRuleCall_1_0_2()); - pushFollow(FOLLOW_28); + pushFollow(FOLLOW_29); lv_name_1_3=ruleVLSRole(); state._fsp--; @@ -2369,7 +2369,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { case 1 : // InternalVampireLanguage.g:931:4: otherlv_2= '(' ( (lv_followup_3_0= ruleVLSAnnotationTerms ) ) otherlv_4= ')' { - otherlv_2=(Token)match(input,38,FOLLOW_29); + otherlv_2=(Token)match(input,38,FOLLOW_30); newLeafNode(otherlv_2, grammarAccess.getVLSAnnotationAccess().getLeftParenthesisKeyword_2_0()); @@ -2404,7 +2404,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_4=(Token)match(input,40,FOLLOW_30); + otherlv_4=(Token)match(input,40,FOLLOW_31); newLeafNode(otherlv_4, grammarAccess.getVLSAnnotationAccess().getRightParenthesisKeyword_2_2()); @@ -2523,7 +2523,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newCompositeNode(grammarAccess.getVLSAnnotationTermsAccess().getTermsVLSAnnotationParserRuleCall_0_0()); - pushFollow(FOLLOW_31); + pushFollow(FOLLOW_32); lv_terms_0_0=ruleVLSAnnotation(); state._fsp--; @@ -2560,7 +2560,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { case 1 : // InternalVampireLanguage.g:1004:4: otherlv_1= ',' ( (lv_terms_2_0= ruleVLSAnnotation ) ) { - otherlv_1=(Token)match(input,39,FOLLOW_29); + otherlv_1=(Token)match(input,39,FOLLOW_30); newLeafNode(otherlv_1, grammarAccess.getVLSAnnotationTermsAccess().getCommaKeyword_1_0()); @@ -2573,7 +2573,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newCompositeNode(grammarAccess.getVLSAnnotationTermsAccess().getTermsVLSAnnotationParserRuleCall_1_1_0()); - pushFollow(FOLLOW_31); + pushFollow(FOLLOW_32); lv_terms_2_0=ruleVLSAnnotation(); state._fsp--; @@ -2663,7 +2663,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSTffTerm" - // InternalVampireLanguage.g:1039:1: ruleVLSTffTerm returns [EObject current=null] : (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration ) ; + // InternalVampireLanguage.g:1039:1: ruleVLSTffTerm returns [EObject current=null] : (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration | this_VLSCommentTerm_2= ruleVLSCommentTerm ) ; public final EObject ruleVLSTffTerm() throws RecognitionException { EObject current = null; @@ -2671,16 +2671,18 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { EObject this_VLSDeclaration_1 = null; + EObject this_VLSCommentTerm_2 = null; + enterRule(); try { - // InternalVampireLanguage.g:1045:2: ( (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration ) ) - // InternalVampireLanguage.g:1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration ) + // InternalVampireLanguage.g:1045:2: ( (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration | this_VLSCommentTerm_2= ruleVLSCommentTerm ) ) + // InternalVampireLanguage.g:1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration | this_VLSCommentTerm_2= ruleVLSCommentTerm ) { - // InternalVampireLanguage.g:1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration ) - int alt15=2; + // InternalVampireLanguage.g:1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration | this_VLSCommentTerm_2= ruleVLSCommentTerm ) + int alt15=3; alt15 = dfa15.predict(input); switch (alt15) { case 1 : @@ -2717,6 +2719,24 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { afterParserOrEnumRuleCall(); + } + break; + case 3 : + // InternalVampireLanguage.g:1065:3: this_VLSCommentTerm_2= ruleVLSCommentTerm + { + + newCompositeNode(grammarAccess.getVLSTffTermAccess().getVLSCommentTermParserRuleCall_2()); + + pushFollow(FOLLOW_2); + this_VLSCommentTerm_2=ruleVLSCommentTerm(); + + state._fsp--; + + + current = this_VLSCommentTerm_2; + afterParserOrEnumRuleCall(); + + } break; @@ -2741,8 +2761,103 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR end "ruleVLSTffTerm" + // $ANTLR start "entryRuleVLSCommentTerm" + // InternalVampireLanguage.g:1077:1: entryRuleVLSCommentTerm returns [EObject current=null] : iv_ruleVLSCommentTerm= ruleVLSCommentTerm EOF ; + public final EObject entryRuleVLSCommentTerm() throws RecognitionException { + EObject current = null; + + EObject iv_ruleVLSCommentTerm = null; + + + try { + // InternalVampireLanguage.g:1077:55: (iv_ruleVLSCommentTerm= ruleVLSCommentTerm EOF ) + // InternalVampireLanguage.g:1078:2: iv_ruleVLSCommentTerm= ruleVLSCommentTerm EOF + { + newCompositeNode(grammarAccess.getVLSCommentTermRule()); + pushFollow(FOLLOW_1); + iv_ruleVLSCommentTerm=ruleVLSCommentTerm(); + + state._fsp--; + + current =iv_ruleVLSCommentTerm; + match(input,EOF,FOLLOW_2); + + } + + } + + catch (RecognitionException re) { + recover(input,re); + appendSkippedTokens(); + } + finally { + } + return current; + } + // $ANTLR end "entryRuleVLSCommentTerm" + + + // $ANTLR start "ruleVLSCommentTerm" + // InternalVampireLanguage.g:1084:1: ruleVLSCommentTerm returns [EObject current=null] : ( (lv_comment_0_0= RULE_SINGLE_COMMENT ) ) ; + public final EObject ruleVLSCommentTerm() throws RecognitionException { + EObject current = null; + + Token lv_comment_0_0=null; + + + enterRule(); + + try { + // InternalVampireLanguage.g:1090:2: ( ( (lv_comment_0_0= RULE_SINGLE_COMMENT ) ) ) + // InternalVampireLanguage.g:1091:2: ( (lv_comment_0_0= RULE_SINGLE_COMMENT ) ) + { + // InternalVampireLanguage.g:1091:2: ( (lv_comment_0_0= RULE_SINGLE_COMMENT ) ) + // InternalVampireLanguage.g:1092:3: (lv_comment_0_0= RULE_SINGLE_COMMENT ) + { + // InternalVampireLanguage.g:1092:3: (lv_comment_0_0= RULE_SINGLE_COMMENT ) + // InternalVampireLanguage.g:1093:4: lv_comment_0_0= RULE_SINGLE_COMMENT + { + lv_comment_0_0=(Token)match(input,RULE_SINGLE_COMMENT,FOLLOW_2); + + newLeafNode(lv_comment_0_0, grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0()); + + + if (current==null) { + current = createModelElement(grammarAccess.getVLSCommentTermRule()); + } + setWithLastConsumed( + current, + "comment", + lv_comment_0_0, + "ca.mcgill.ecse.dslreasoner.VampireLanguage.SINGLE_COMMENT"); + + + } + + + } + + + } + + + leaveRule(); + + } + + catch (RecognitionException re) { + recover(input,re); + appendSkippedTokens(); + } + finally { + } + return current; + } + // $ANTLR end "ruleVLSCommentTerm" + + // $ANTLR start "entryRuleVLSDeclaration" - // InternalVampireLanguage.g:1068:1: entryRuleVLSDeclaration returns [EObject current=null] : iv_ruleVLSDeclaration= ruleVLSDeclaration EOF ; + // InternalVampireLanguage.g:1112:1: entryRuleVLSDeclaration returns [EObject current=null] : iv_ruleVLSDeclaration= ruleVLSDeclaration EOF ; public final EObject entryRuleVLSDeclaration() throws RecognitionException { EObject current = null; @@ -2750,8 +2865,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1068:55: (iv_ruleVLSDeclaration= ruleVLSDeclaration EOF ) - // InternalVampireLanguage.g:1069:2: iv_ruleVLSDeclaration= ruleVLSDeclaration EOF + // InternalVampireLanguage.g:1112:55: (iv_ruleVLSDeclaration= ruleVLSDeclaration EOF ) + // InternalVampireLanguage.g:1113:2: iv_ruleVLSDeclaration= ruleVLSDeclaration EOF { newCompositeNode(grammarAccess.getVLSDeclarationRule()); pushFollow(FOLLOW_1); @@ -2778,7 +2893,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSDeclaration" - // InternalVampireLanguage.g:1075:1: ruleVLSDeclaration returns [EObject current=null] : (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) ; + // InternalVampireLanguage.g:1119:1: ruleVLSDeclaration returns [EObject current=null] : (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) ; public final EObject ruleVLSDeclaration() throws RecognitionException { EObject current = null; @@ -2791,10 +2906,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1081:2: ( (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) ) - // InternalVampireLanguage.g:1082:2: (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) + // InternalVampireLanguage.g:1125:2: ( (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) ) + // InternalVampireLanguage.g:1126:2: (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) { - // InternalVampireLanguage.g:1082:2: (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) + // InternalVampireLanguage.g:1126:2: (this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration | this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration ) int alt16=2; int LA16_0 = input.LA(1); @@ -2812,7 +2927,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt16) { case 1 : - // InternalVampireLanguage.g:1083:3: this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1127:3: this_VLSVariableDeclaration_0= ruleVLSVariableDeclaration { newCompositeNode(grammarAccess.getVLSDeclarationAccess().getVLSVariableDeclarationParserRuleCall_0()); @@ -2830,7 +2945,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1092:3: this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration + // InternalVampireLanguage.g:1136:3: this_VLSOtherDeclaration_1= ruleVLSOtherDeclaration { newCompositeNode(grammarAccess.getVLSDeclarationAccess().getVLSOtherDeclarationParserRuleCall_1()); @@ -2870,7 +2985,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSOtherDeclaration" - // InternalVampireLanguage.g:1104:1: entryRuleVLSOtherDeclaration returns [EObject current=null] : iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF ; + // InternalVampireLanguage.g:1148:1: entryRuleVLSOtherDeclaration returns [EObject current=null] : iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF ; public final EObject entryRuleVLSOtherDeclaration() throws RecognitionException { EObject current = null; @@ -2878,8 +2993,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1104:60: (iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF ) - // InternalVampireLanguage.g:1105:2: iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF + // InternalVampireLanguage.g:1148:60: (iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF ) + // InternalVampireLanguage.g:1149:2: iv_ruleVLSOtherDeclaration= ruleVLSOtherDeclaration EOF { newCompositeNode(grammarAccess.getVLSOtherDeclarationRule()); pushFollow(FOLLOW_1); @@ -2906,7 +3021,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSOtherDeclaration" - // InternalVampireLanguage.g:1111:1: ruleVLSOtherDeclaration returns [EObject current=null] : ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ; + // InternalVampireLanguage.g:1155:1: ruleVLSOtherDeclaration returns [EObject current=null] : ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ; public final EObject ruleVLSOtherDeclaration() throws RecognitionException { EObject current = null; @@ -2920,22 +3035,22 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1117:2: ( ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ) - // InternalVampireLanguage.g:1118:2: ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) + // InternalVampireLanguage.g:1161:2: ( ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ) + // InternalVampireLanguage.g:1162:2: ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) { - // InternalVampireLanguage.g:1118:2: ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) - // InternalVampireLanguage.g:1119:3: ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:1162:2: ( ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) + // InternalVampireLanguage.g:1163:3: ( (lv_name_0_0= ruleVLSAtomicConstant ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) { - // InternalVampireLanguage.g:1119:3: ( (lv_name_0_0= ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:1120:4: (lv_name_0_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1163:3: ( (lv_name_0_0= ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:1164:4: (lv_name_0_0= ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:1120:4: (lv_name_0_0= ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:1121:5: lv_name_0_0= ruleVLSAtomicConstant + // InternalVampireLanguage.g:1164:4: (lv_name_0_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1165:5: lv_name_0_0= ruleVLSAtomicConstant { newCompositeNode(grammarAccess.getVLSOtherDeclarationAccess().getNameVLSAtomicConstantParserRuleCall_0_0()); - pushFollow(FOLLOW_32); + pushFollow(FOLLOW_33); lv_name_0_0=ruleVLSAtomicConstant(); state._fsp--; @@ -2957,15 +3072,15 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_1=(Token)match(input,61,FOLLOW_33); + otherlv_1=(Token)match(input,61,FOLLOW_34); newLeafNode(otherlv_1, grammarAccess.getVLSOtherDeclarationAccess().getColonKeyword_1()); - // InternalVampireLanguage.g:1142:3: ( (lv_type_2_0= ruleVLSTypeDef ) ) - // InternalVampireLanguage.g:1143:4: (lv_type_2_0= ruleVLSTypeDef ) + // InternalVampireLanguage.g:1186:3: ( (lv_type_2_0= ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:1187:4: (lv_type_2_0= ruleVLSTypeDef ) { - // InternalVampireLanguage.g:1143:4: (lv_type_2_0= ruleVLSTypeDef ) - // InternalVampireLanguage.g:1144:5: lv_type_2_0= ruleVLSTypeDef + // InternalVampireLanguage.g:1187:4: (lv_type_2_0= ruleVLSTypeDef ) + // InternalVampireLanguage.g:1188:5: lv_type_2_0= ruleVLSTypeDef { newCompositeNode(grammarAccess.getVLSOtherDeclarationAccess().getTypeVLSTypeDefParserRuleCall_2_0()); @@ -3015,7 +3130,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSVariableDeclaration" - // InternalVampireLanguage.g:1165:1: entryRuleVLSVariableDeclaration returns [EObject current=null] : iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF ; + // InternalVampireLanguage.g:1209:1: entryRuleVLSVariableDeclaration returns [EObject current=null] : iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF ; public final EObject entryRuleVLSVariableDeclaration() throws RecognitionException { EObject current = null; @@ -3023,8 +3138,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1165:63: (iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF ) - // InternalVampireLanguage.g:1166:2: iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF + // InternalVampireLanguage.g:1209:63: (iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF ) + // InternalVampireLanguage.g:1210:2: iv_ruleVLSVariableDeclaration= ruleVLSVariableDeclaration EOF { newCompositeNode(grammarAccess.getVLSVariableDeclarationRule()); pushFollow(FOLLOW_1); @@ -3051,7 +3166,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSVariableDeclaration" - // InternalVampireLanguage.g:1172:1: ruleVLSVariableDeclaration returns [EObject current=null] : ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ; + // InternalVampireLanguage.g:1216:1: ruleVLSVariableDeclaration returns [EObject current=null] : ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ; public final EObject ruleVLSVariableDeclaration() throws RecognitionException { EObject current = null; @@ -3065,22 +3180,22 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1178:2: ( ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ) - // InternalVampireLanguage.g:1179:2: ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) + // InternalVampireLanguage.g:1222:2: ( ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) ) + // InternalVampireLanguage.g:1223:2: ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) { - // InternalVampireLanguage.g:1179:2: ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) - // InternalVampireLanguage.g:1180:3: ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:1223:2: ( ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) ) + // InternalVampireLanguage.g:1224:3: ( (lv_name_0_0= ruleVLSVariable ) ) otherlv_1= ':' ( (lv_type_2_0= ruleVLSTypeDef ) ) { - // InternalVampireLanguage.g:1180:3: ( (lv_name_0_0= ruleVLSVariable ) ) - // InternalVampireLanguage.g:1181:4: (lv_name_0_0= ruleVLSVariable ) + // InternalVampireLanguage.g:1224:3: ( (lv_name_0_0= ruleVLSVariable ) ) + // InternalVampireLanguage.g:1225:4: (lv_name_0_0= ruleVLSVariable ) { - // InternalVampireLanguage.g:1181:4: (lv_name_0_0= ruleVLSVariable ) - // InternalVampireLanguage.g:1182:5: lv_name_0_0= ruleVLSVariable + // InternalVampireLanguage.g:1225:4: (lv_name_0_0= ruleVLSVariable ) + // InternalVampireLanguage.g:1226:5: lv_name_0_0= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSVariableDeclarationAccess().getNameVLSVariableParserRuleCall_0_0()); - pushFollow(FOLLOW_32); + pushFollow(FOLLOW_33); lv_name_0_0=ruleVLSVariable(); state._fsp--; @@ -3102,15 +3217,15 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_1=(Token)match(input,61,FOLLOW_33); + otherlv_1=(Token)match(input,61,FOLLOW_34); newLeafNode(otherlv_1, grammarAccess.getVLSVariableDeclarationAccess().getColonKeyword_1()); - // InternalVampireLanguage.g:1203:3: ( (lv_type_2_0= ruleVLSTypeDef ) ) - // InternalVampireLanguage.g:1204:4: (lv_type_2_0= ruleVLSTypeDef ) + // InternalVampireLanguage.g:1247:3: ( (lv_type_2_0= ruleVLSTypeDef ) ) + // InternalVampireLanguage.g:1248:4: (lv_type_2_0= ruleVLSTypeDef ) { - // InternalVampireLanguage.g:1204:4: (lv_type_2_0= ruleVLSTypeDef ) - // InternalVampireLanguage.g:1205:5: lv_type_2_0= ruleVLSTypeDef + // InternalVampireLanguage.g:1248:4: (lv_type_2_0= ruleVLSTypeDef ) + // InternalVampireLanguage.g:1249:5: lv_type_2_0= ruleVLSTypeDef { newCompositeNode(grammarAccess.getVLSVariableDeclarationAccess().getTypeVLSTypeDefParserRuleCall_2_0()); @@ -3160,7 +3275,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSTypeDef" - // InternalVampireLanguage.g:1226:1: entryRuleVLSTypeDef returns [EObject current=null] : iv_ruleVLSTypeDef= ruleVLSTypeDef EOF ; + // InternalVampireLanguage.g:1270:1: entryRuleVLSTypeDef returns [EObject current=null] : iv_ruleVLSTypeDef= ruleVLSTypeDef EOF ; public final EObject entryRuleVLSTypeDef() throws RecognitionException { EObject current = null; @@ -3168,8 +3283,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1226:51: (iv_ruleVLSTypeDef= ruleVLSTypeDef EOF ) - // InternalVampireLanguage.g:1227:2: iv_ruleVLSTypeDef= ruleVLSTypeDef EOF + // InternalVampireLanguage.g:1270:51: (iv_ruleVLSTypeDef= ruleVLSTypeDef EOF ) + // InternalVampireLanguage.g:1271:2: iv_ruleVLSTypeDef= ruleVLSTypeDef EOF { newCompositeNode(grammarAccess.getVLSTypeDefRule()); pushFollow(FOLLOW_1); @@ -3196,7 +3311,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSTypeDef" - // InternalVampireLanguage.g:1233:1: ruleVLSTypeDef returns [EObject current=null] : ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) ; + // InternalVampireLanguage.g:1277:1: ruleVLSTypeDef returns [EObject current=null] : ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) ; public final EObject ruleVLSTypeDef() throws RecognitionException { EObject current = null; @@ -3210,22 +3325,22 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1239:2: ( ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) ) - // InternalVampireLanguage.g:1240:2: ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) + // InternalVampireLanguage.g:1283:2: ( ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) ) + // InternalVampireLanguage.g:1284:2: ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) { - // InternalVampireLanguage.g:1240:2: ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) - // InternalVampireLanguage.g:1241:3: ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? + // InternalVampireLanguage.g:1284:2: ( ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? ) + // InternalVampireLanguage.g:1285:3: ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? { - // InternalVampireLanguage.g:1241:3: ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) - // InternalVampireLanguage.g:1242:4: (lv_typeSig_0_0= ruleVLSUnitaryTerm ) + // InternalVampireLanguage.g:1285:3: ( (lv_typeSig_0_0= ruleVLSUnitaryTerm ) ) + // InternalVampireLanguage.g:1286:4: (lv_typeSig_0_0= ruleVLSUnitaryTerm ) { - // InternalVampireLanguage.g:1242:4: (lv_typeSig_0_0= ruleVLSUnitaryTerm ) - // InternalVampireLanguage.g:1243:5: lv_typeSig_0_0= ruleVLSUnitaryTerm + // InternalVampireLanguage.g:1286:4: (lv_typeSig_0_0= ruleVLSUnitaryTerm ) + // InternalVampireLanguage.g:1287:5: lv_typeSig_0_0= ruleVLSUnitaryTerm { newCompositeNode(grammarAccess.getVLSTypeDefAccess().getTypeSigVLSUnitaryTermParserRuleCall_0_0()); - pushFollow(FOLLOW_34); + pushFollow(FOLLOW_35); lv_typeSig_0_0=ruleVLSUnitaryTerm(); state._fsp--; @@ -3247,7 +3362,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1260:3: (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? + // InternalVampireLanguage.g:1304:3: (otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) )? int alt17=2; int LA17_0 = input.LA(1); @@ -3256,17 +3371,17 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt17) { case 1 : - // InternalVampireLanguage.g:1261:4: otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:1305:4: otherlv_1= '>' ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) { - otherlv_1=(Token)match(input,62,FOLLOW_35); + otherlv_1=(Token)match(input,62,FOLLOW_36); newLeafNode(otherlv_1, grammarAccess.getVLSTypeDefAccess().getGreaterThanSignKeyword_1_0()); - // InternalVampireLanguage.g:1265:4: ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:1266:5: (lv_mapsTo_2_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1309:4: ( (lv_mapsTo_2_0= ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:1310:5: (lv_mapsTo_2_0= ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:1266:5: (lv_mapsTo_2_0= ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:1267:6: lv_mapsTo_2_0= ruleVLSAtomicConstant + // InternalVampireLanguage.g:1310:5: (lv_mapsTo_2_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1311:6: lv_mapsTo_2_0= ruleVLSAtomicConstant { newCompositeNode(grammarAccess.getVLSTypeDefAccess().getMapsToVLSAtomicConstantParserRuleCall_1_1_0()); @@ -3322,7 +3437,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSUnitaryTerm" - // InternalVampireLanguage.g:1289:1: entryRuleVLSUnitaryTerm returns [EObject current=null] : iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF ; + // InternalVampireLanguage.g:1333:1: entryRuleVLSUnitaryTerm returns [EObject current=null] : iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF ; public final EObject entryRuleVLSUnitaryTerm() throws RecognitionException { EObject current = null; @@ -3330,8 +3445,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1289:55: (iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF ) - // InternalVampireLanguage.g:1290:2: iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF + // InternalVampireLanguage.g:1333:55: (iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF ) + // InternalVampireLanguage.g:1334:2: iv_ruleVLSUnitaryTerm= ruleVLSUnitaryTerm EOF { newCompositeNode(grammarAccess.getVLSUnitaryTermRule()); pushFollow(FOLLOW_1); @@ -3358,7 +3473,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSUnitaryTerm" - // InternalVampireLanguage.g:1296:1: ruleVLSUnitaryTerm returns [EObject current=null] : ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) ; + // InternalVampireLanguage.g:1340:1: ruleVLSUnitaryTerm returns [EObject current=null] : ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) ; public final EObject ruleVLSUnitaryTerm() throws RecognitionException { EObject current = null; @@ -3372,22 +3487,22 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1302:2: ( ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) ) - // InternalVampireLanguage.g:1303:2: ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) + // InternalVampireLanguage.g:1346:2: ( ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) ) + // InternalVampireLanguage.g:1347:2: ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) { - // InternalVampireLanguage.g:1303:2: ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) - // InternalVampireLanguage.g:1304:3: ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* + // InternalVampireLanguage.g:1347:2: ( ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* ) + // InternalVampireLanguage.g:1348:3: ( (lv_initType_0_0= ruleVLSAtomic ) ) (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* { - // InternalVampireLanguage.g:1304:3: ( (lv_initType_0_0= ruleVLSAtomic ) ) - // InternalVampireLanguage.g:1305:4: (lv_initType_0_0= ruleVLSAtomic ) + // InternalVampireLanguage.g:1348:3: ( (lv_initType_0_0= ruleVLSAtomic ) ) + // InternalVampireLanguage.g:1349:4: (lv_initType_0_0= ruleVLSAtomic ) { - // InternalVampireLanguage.g:1305:4: (lv_initType_0_0= ruleVLSAtomic ) - // InternalVampireLanguage.g:1306:5: lv_initType_0_0= ruleVLSAtomic + // InternalVampireLanguage.g:1349:4: (lv_initType_0_0= ruleVLSAtomic ) + // InternalVampireLanguage.g:1350:5: lv_initType_0_0= ruleVLSAtomic { newCompositeNode(grammarAccess.getVLSUnitaryTermAccess().getInitTypeVLSAtomicParserRuleCall_0_0()); - pushFollow(FOLLOW_36); + pushFollow(FOLLOW_37); lv_initType_0_0=ruleVLSAtomic(); state._fsp--; @@ -3409,7 +3524,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1323:3: (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* + // InternalVampireLanguage.g:1367:3: (otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) )* loop18: do { int alt18=2; @@ -3422,22 +3537,22 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt18) { case 1 : - // InternalVampireLanguage.g:1324:4: otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:1368:4: otherlv_1= '*' ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) { - otherlv_1=(Token)match(input,63,FOLLOW_35); + otherlv_1=(Token)match(input,63,FOLLOW_36); newLeafNode(otherlv_1, grammarAccess.getVLSUnitaryTermAccess().getAsteriskKeyword_1_0()); - // InternalVampireLanguage.g:1328:4: ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) - // InternalVampireLanguage.g:1329:5: (lv_nextType_2_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1372:4: ( (lv_nextType_2_0= ruleVLSAtomicConstant ) ) + // InternalVampireLanguage.g:1373:5: (lv_nextType_2_0= ruleVLSAtomicConstant ) { - // InternalVampireLanguage.g:1329:5: (lv_nextType_2_0= ruleVLSAtomicConstant ) - // InternalVampireLanguage.g:1330:6: lv_nextType_2_0= ruleVLSAtomicConstant + // InternalVampireLanguage.g:1373:5: (lv_nextType_2_0= ruleVLSAtomicConstant ) + // InternalVampireLanguage.g:1374:6: lv_nextType_2_0= ruleVLSAtomicConstant { newCompositeNode(grammarAccess.getVLSUnitaryTermAccess().getNextTypeVLSAtomicConstantParserRuleCall_1_1_0()); - pushFollow(FOLLOW_36); + pushFollow(FOLLOW_37); lv_nextType_2_0=ruleVLSAtomicConstant(); state._fsp--; @@ -3491,7 +3606,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSTerm" - // InternalVampireLanguage.g:1352:1: entryRuleVLSTerm returns [EObject current=null] : iv_ruleVLSTerm= ruleVLSTerm EOF ; + // InternalVampireLanguage.g:1396:1: entryRuleVLSTerm returns [EObject current=null] : iv_ruleVLSTerm= ruleVLSTerm EOF ; public final EObject entryRuleVLSTerm() throws RecognitionException { EObject current = null; @@ -3499,8 +3614,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1352:48: (iv_ruleVLSTerm= ruleVLSTerm EOF ) - // InternalVampireLanguage.g:1353:2: iv_ruleVLSTerm= ruleVLSTerm EOF + // InternalVampireLanguage.g:1396:48: (iv_ruleVLSTerm= ruleVLSTerm EOF ) + // InternalVampireLanguage.g:1397:2: iv_ruleVLSTerm= ruleVLSTerm EOF { newCompositeNode(grammarAccess.getVLSTermRule()); pushFollow(FOLLOW_1); @@ -3527,7 +3642,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSTerm" - // InternalVampireLanguage.g:1359:1: ruleVLSTerm returns [EObject current=null] : this_VLSBinary_0= ruleVLSBinary ; + // InternalVampireLanguage.g:1403:1: ruleVLSTerm returns [EObject current=null] : this_VLSBinary_0= ruleVLSBinary ; public final EObject ruleVLSTerm() throws RecognitionException { EObject current = null; @@ -3538,8 +3653,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1365:2: (this_VLSBinary_0= ruleVLSBinary ) - // InternalVampireLanguage.g:1366:2: this_VLSBinary_0= ruleVLSBinary + // InternalVampireLanguage.g:1409:2: (this_VLSBinary_0= ruleVLSBinary ) + // InternalVampireLanguage.g:1410:2: this_VLSBinary_0= ruleVLSBinary { newCompositeNode(grammarAccess.getVLSTermAccess().getVLSBinaryParserRuleCall()); @@ -3573,7 +3688,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSBinary" - // InternalVampireLanguage.g:1377:1: entryRuleVLSBinary returns [EObject current=null] : iv_ruleVLSBinary= ruleVLSBinary EOF ; + // InternalVampireLanguage.g:1421:1: entryRuleVLSBinary returns [EObject current=null] : iv_ruleVLSBinary= ruleVLSBinary EOF ; public final EObject entryRuleVLSBinary() throws RecognitionException { EObject current = null; @@ -3581,8 +3696,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1377:50: (iv_ruleVLSBinary= ruleVLSBinary EOF ) - // InternalVampireLanguage.g:1378:2: iv_ruleVLSBinary= ruleVLSBinary EOF + // InternalVampireLanguage.g:1421:50: (iv_ruleVLSBinary= ruleVLSBinary EOF ) + // InternalVampireLanguage.g:1422:2: iv_ruleVLSBinary= ruleVLSBinary EOF { newCompositeNode(grammarAccess.getVLSBinaryRule()); pushFollow(FOLLOW_1); @@ -3609,7 +3724,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSBinary" - // InternalVampireLanguage.g:1384:1: ruleVLSBinary returns [EObject current=null] : (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) ; + // InternalVampireLanguage.g:1428:1: ruleVLSBinary returns [EObject current=null] : (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) ; public final EObject ruleVLSBinary() throws RecognitionException { EObject current = null; @@ -3634,16 +3749,16 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1390:2: ( (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) ) - // InternalVampireLanguage.g:1391:2: (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) + // InternalVampireLanguage.g:1434:2: ( (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) ) + // InternalVampireLanguage.g:1435:2: (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) { - // InternalVampireLanguage.g:1391:2: (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) - // InternalVampireLanguage.g:1392:3: this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? + // InternalVampireLanguage.g:1435:2: (this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? ) + // InternalVampireLanguage.g:1436:3: this_VLSUnitaryFormula_0= ruleVLSUnitaryFormula ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? { newCompositeNode(grammarAccess.getVLSBinaryAccess().getVLSUnitaryFormulaParserRuleCall_0()); - pushFollow(FOLLOW_37); + pushFollow(FOLLOW_38); this_VLSUnitaryFormula_0=ruleVLSUnitaryFormula(); state._fsp--; @@ -3652,7 +3767,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { current = this_VLSUnitaryFormula_0; afterParserOrEnumRuleCall(); - // InternalVampireLanguage.g:1400:3: ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? + // InternalVampireLanguage.g:1444:3: ( ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) | ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ | ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ )? int alt22=4; switch ( input.LA(1) ) { case 64: @@ -3679,12 +3794,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt22) { case 1 : - // InternalVampireLanguage.g:1401:4: ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1445:4: ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) { - // InternalVampireLanguage.g:1401:4: ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) - // InternalVampireLanguage.g:1402:5: ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1445:4: ( ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1446:5: ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1402:5: ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) + // InternalVampireLanguage.g:1446:5: ( ( () otherlv_2= '<=>' ) | ( () otherlv_4= '=>' ) | ( () otherlv_6= '<=' ) | ( () otherlv_8= '<~>' ) | ( () otherlv_10= '~|' ) | ( () otherlv_12= '~&' ) ) int alt19=6; switch ( input.LA(1) ) { case 64: @@ -3726,13 +3841,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt19) { case 1 : - // InternalVampireLanguage.g:1403:6: ( () otherlv_2= '<=>' ) + // InternalVampireLanguage.g:1447:6: ( () otherlv_2= '<=>' ) { - // InternalVampireLanguage.g:1403:6: ( () otherlv_2= '<=>' ) - // InternalVampireLanguage.g:1404:7: () otherlv_2= '<=>' + // InternalVampireLanguage.g:1447:6: ( () otherlv_2= '<=>' ) + // InternalVampireLanguage.g:1448:7: () otherlv_2= '<=>' { - // InternalVampireLanguage.g:1404:7: () - // InternalVampireLanguage.g:1405:8: + // InternalVampireLanguage.g:1448:7: () + // InternalVampireLanguage.g:1449:8: { current = forceCreateModelElementAndSet( @@ -3753,13 +3868,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1417:6: ( () otherlv_4= '=>' ) + // InternalVampireLanguage.g:1461:6: ( () otherlv_4= '=>' ) { - // InternalVampireLanguage.g:1417:6: ( () otherlv_4= '=>' ) - // InternalVampireLanguage.g:1418:7: () otherlv_4= '=>' + // InternalVampireLanguage.g:1461:6: ( () otherlv_4= '=>' ) + // InternalVampireLanguage.g:1462:7: () otherlv_4= '=>' { - // InternalVampireLanguage.g:1418:7: () - // InternalVampireLanguage.g:1419:8: + // InternalVampireLanguage.g:1462:7: () + // InternalVampireLanguage.g:1463:8: { current = forceCreateModelElementAndSet( @@ -3780,13 +3895,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:1431:6: ( () otherlv_6= '<=' ) + // InternalVampireLanguage.g:1475:6: ( () otherlv_6= '<=' ) { - // InternalVampireLanguage.g:1431:6: ( () otherlv_6= '<=' ) - // InternalVampireLanguage.g:1432:7: () otherlv_6= '<=' + // InternalVampireLanguage.g:1475:6: ( () otherlv_6= '<=' ) + // InternalVampireLanguage.g:1476:7: () otherlv_6= '<=' { - // InternalVampireLanguage.g:1432:7: () - // InternalVampireLanguage.g:1433:8: + // InternalVampireLanguage.g:1476:7: () + // InternalVampireLanguage.g:1477:8: { current = forceCreateModelElementAndSet( @@ -3807,13 +3922,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:1445:6: ( () otherlv_8= '<~>' ) + // InternalVampireLanguage.g:1489:6: ( () otherlv_8= '<~>' ) { - // InternalVampireLanguage.g:1445:6: ( () otherlv_8= '<~>' ) - // InternalVampireLanguage.g:1446:7: () otherlv_8= '<~>' + // InternalVampireLanguage.g:1489:6: ( () otherlv_8= '<~>' ) + // InternalVampireLanguage.g:1490:7: () otherlv_8= '<~>' { - // InternalVampireLanguage.g:1446:7: () - // InternalVampireLanguage.g:1447:8: + // InternalVampireLanguage.g:1490:7: () + // InternalVampireLanguage.g:1491:8: { current = forceCreateModelElementAndSet( @@ -3834,13 +3949,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 5 : - // InternalVampireLanguage.g:1459:6: ( () otherlv_10= '~|' ) + // InternalVampireLanguage.g:1503:6: ( () otherlv_10= '~|' ) { - // InternalVampireLanguage.g:1459:6: ( () otherlv_10= '~|' ) - // InternalVampireLanguage.g:1460:7: () otherlv_10= '~|' + // InternalVampireLanguage.g:1503:6: ( () otherlv_10= '~|' ) + // InternalVampireLanguage.g:1504:7: () otherlv_10= '~|' { - // InternalVampireLanguage.g:1460:7: () - // InternalVampireLanguage.g:1461:8: + // InternalVampireLanguage.g:1504:7: () + // InternalVampireLanguage.g:1505:8: { current = forceCreateModelElementAndSet( @@ -3861,13 +3976,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 6 : - // InternalVampireLanguage.g:1473:6: ( () otherlv_12= '~&' ) + // InternalVampireLanguage.g:1517:6: ( () otherlv_12= '~&' ) { - // InternalVampireLanguage.g:1473:6: ( () otherlv_12= '~&' ) - // InternalVampireLanguage.g:1474:7: () otherlv_12= '~&' + // InternalVampireLanguage.g:1517:6: ( () otherlv_12= '~&' ) + // InternalVampireLanguage.g:1518:7: () otherlv_12= '~&' { - // InternalVampireLanguage.g:1474:7: () - // InternalVampireLanguage.g:1475:8: + // InternalVampireLanguage.g:1518:7: () + // InternalVampireLanguage.g:1519:8: { current = forceCreateModelElementAndSet( @@ -3890,11 +4005,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1487:5: ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1488:6: (lv_right_13_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1531:5: ( (lv_right_13_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1532:6: (lv_right_13_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1488:6: (lv_right_13_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1489:7: lv_right_13_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:1532:6: (lv_right_13_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1533:7: lv_right_13_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_0_1_0()); @@ -3928,9 +4043,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1508:4: ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ + // InternalVampireLanguage.g:1552:4: ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ { - // InternalVampireLanguage.g:1508:4: ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ + // InternalVampireLanguage.g:1552:4: ( () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) )+ int cnt20=0; loop20: do { @@ -3944,10 +4059,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt20) { case 1 : - // InternalVampireLanguage.g:1509:5: () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1553:5: () otherlv_15= '&' ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1509:5: () - // InternalVampireLanguage.g:1510:6: + // InternalVampireLanguage.g:1553:5: () + // InternalVampireLanguage.g:1554:6: { current = forceCreateModelElementAndSet( @@ -3961,16 +4076,16 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newLeafNode(otherlv_15, grammarAccess.getVLSBinaryAccess().getAmpersandKeyword_1_1_1()); - // InternalVampireLanguage.g:1520:5: ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1521:6: (lv_right_16_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1564:5: ( (lv_right_16_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1565:6: (lv_right_16_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1521:6: (lv_right_16_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1522:7: lv_right_16_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:1565:6: (lv_right_16_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1566:7: lv_right_16_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_1_2_0()); - pushFollow(FOLLOW_38); + pushFollow(FOLLOW_39); lv_right_16_0=ruleVLSUnitaryFormula(); state._fsp--; @@ -4009,9 +4124,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:1541:4: ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ + // InternalVampireLanguage.g:1585:4: ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ { - // InternalVampireLanguage.g:1541:4: ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ + // InternalVampireLanguage.g:1585:4: ( () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) )+ int cnt21=0; loop21: do { @@ -4025,10 +4140,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt21) { case 1 : - // InternalVampireLanguage.g:1542:5: () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1586:5: () otherlv_18= '|' ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1542:5: () - // InternalVampireLanguage.g:1543:6: + // InternalVampireLanguage.g:1586:5: () + // InternalVampireLanguage.g:1587:6: { current = forceCreateModelElementAndSet( @@ -4042,16 +4157,16 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newLeafNode(otherlv_18, grammarAccess.getVLSBinaryAccess().getVerticalLineKeyword_1_2_1()); - // InternalVampireLanguage.g:1553:5: ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1554:6: (lv_right_19_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1597:5: ( (lv_right_19_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1598:6: (lv_right_19_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1554:6: (lv_right_19_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1555:7: lv_right_19_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:1598:6: (lv_right_19_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1599:7: lv_right_19_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSBinaryAccess().getRightVLSUnitaryFormulaParserRuleCall_1_2_2_0()); - pushFollow(FOLLOW_39); + pushFollow(FOLLOW_40); lv_right_19_0=ruleVLSUnitaryFormula(); state._fsp--; @@ -4115,7 +4230,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSUnitaryFormula" - // InternalVampireLanguage.g:1578:1: entryRuleVLSUnitaryFormula returns [EObject current=null] : iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF ; + // InternalVampireLanguage.g:1622:1: entryRuleVLSUnitaryFormula returns [EObject current=null] : iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF ; public final EObject entryRuleVLSUnitaryFormula() throws RecognitionException { EObject current = null; @@ -4123,8 +4238,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1578:58: (iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF ) - // InternalVampireLanguage.g:1579:2: iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF + // InternalVampireLanguage.g:1622:58: (iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF ) + // InternalVampireLanguage.g:1623:2: iv_ruleVLSUnitaryFormula= ruleVLSUnitaryFormula EOF { newCompositeNode(grammarAccess.getVLSUnitaryFormulaRule()); pushFollow(FOLLOW_1); @@ -4151,7 +4266,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSUnitaryFormula" - // InternalVampireLanguage.g:1585:1: ruleVLSUnitaryFormula returns [EObject current=null] : (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) ; + // InternalVampireLanguage.g:1629:1: ruleVLSUnitaryFormula returns [EObject current=null] : (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) ; public final EObject ruleVLSUnitaryFormula() throws RecognitionException { EObject current = null; @@ -4172,10 +4287,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1591:2: ( (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) ) - // InternalVampireLanguage.g:1592:2: (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) + // InternalVampireLanguage.g:1635:2: ( (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) ) + // InternalVampireLanguage.g:1636:2: (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) { - // InternalVampireLanguage.g:1592:2: (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) + // InternalVampireLanguage.g:1636:2: (this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier | this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier | this_VLSUnaryNegation_2= ruleVLSUnaryNegation | this_VLSUnaryInfix_3= ruleVLSUnaryInfix | (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) ) int alt23=5; switch ( input.LA(1) ) { case 72: @@ -4236,7 +4351,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt23) { case 1 : - // InternalVampireLanguage.g:1593:3: this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier + // InternalVampireLanguage.g:1637:3: this_VLSUniversalQuantifier_0= ruleVLSUniversalQuantifier { newCompositeNode(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUniversalQuantifierParserRuleCall_0()); @@ -4254,7 +4369,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1602:3: this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier + // InternalVampireLanguage.g:1646:3: this_VLSExistentialQuantifier_1= ruleVLSExistentialQuantifier { newCompositeNode(grammarAccess.getVLSUnitaryFormulaAccess().getVLSExistentialQuantifierParserRuleCall_1()); @@ -4272,7 +4387,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:1611:3: this_VLSUnaryNegation_2= ruleVLSUnaryNegation + // InternalVampireLanguage.g:1655:3: this_VLSUnaryNegation_2= ruleVLSUnaryNegation { newCompositeNode(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUnaryNegationParserRuleCall_2()); @@ -4290,7 +4405,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:1620:3: this_VLSUnaryInfix_3= ruleVLSUnaryInfix + // InternalVampireLanguage.g:1664:3: this_VLSUnaryInfix_3= ruleVLSUnaryInfix { newCompositeNode(grammarAccess.getVLSUnitaryFormulaAccess().getVLSUnaryInfixParserRuleCall_3()); @@ -4308,10 +4423,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 5 : - // InternalVampireLanguage.g:1629:3: (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) + // InternalVampireLanguage.g:1673:3: (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) { - // InternalVampireLanguage.g:1629:3: (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) - // InternalVampireLanguage.g:1630:4: otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' + // InternalVampireLanguage.g:1673:3: (otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' ) + // InternalVampireLanguage.g:1674:4: otherlv_4= '(' this_VLSTerm_5= ruleVLSTerm otherlv_6= ')' { otherlv_4=(Token)match(input,38,FOLLOW_20); @@ -4362,7 +4477,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSUniversalQuantifier" - // InternalVampireLanguage.g:1651:1: entryRuleVLSUniversalQuantifier returns [EObject current=null] : iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF ; + // InternalVampireLanguage.g:1695:1: entryRuleVLSUniversalQuantifier returns [EObject current=null] : iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF ; public final EObject entryRuleVLSUniversalQuantifier() throws RecognitionException { EObject current = null; @@ -4370,8 +4485,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1651:63: (iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF ) - // InternalVampireLanguage.g:1652:2: iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF + // InternalVampireLanguage.g:1695:63: (iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF ) + // InternalVampireLanguage.g:1696:2: iv_ruleVLSUniversalQuantifier= ruleVLSUniversalQuantifier EOF { newCompositeNode(grammarAccess.getVLSUniversalQuantifierRule()); pushFollow(FOLLOW_1); @@ -4398,7 +4513,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSUniversalQuantifier" - // InternalVampireLanguage.g:1658:1: ruleVLSUniversalQuantifier returns [EObject current=null] : ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ; + // InternalVampireLanguage.g:1702:1: ruleVLSUniversalQuantifier returns [EObject current=null] : ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ; public final EObject ruleVLSUniversalQuantifier() throws RecognitionException { EObject current = null; @@ -4422,14 +4537,14 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1664:2: ( ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ) - // InternalVampireLanguage.g:1665:2: ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1708:2: ( ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ) + // InternalVampireLanguage.g:1709:2: ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) { - // InternalVampireLanguage.g:1665:2: ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) - // InternalVampireLanguage.g:1666:3: () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1709:2: ( () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1710:3: () (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1666:3: () - // InternalVampireLanguage.g:1667:4: + // InternalVampireLanguage.g:1710:3: () + // InternalVampireLanguage.g:1711:4: { current = forceCreateModelElement( @@ -4439,24 +4554,24 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1673:3: (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) - // InternalVampireLanguage.g:1674:4: otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' + // InternalVampireLanguage.g:1717:3: (otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) + // InternalVampireLanguage.g:1718:4: otherlv_1= '!' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' { otherlv_1=(Token)match(input,72,FOLLOW_11); newLeafNode(otherlv_1, grammarAccess.getVLSUniversalQuantifierAccess().getExclamationMarkKeyword_1_0()); - otherlv_2=(Token)match(input,32,FOLLOW_40); + otherlv_2=(Token)match(input,32,FOLLOW_41); newLeafNode(otherlv_2, grammarAccess.getVLSUniversalQuantifierAccess().getLeftSquareBracketKeyword_1_1()); - // InternalVampireLanguage.g:1682:4: ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) - // InternalVampireLanguage.g:1683:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1726:4: ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1727:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) { - // InternalVampireLanguage.g:1683:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) - // InternalVampireLanguage.g:1684:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1727:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1728:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1684:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1728:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) int alt24=2; int LA24_0 = input.LA(1); @@ -4484,12 +4599,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt24) { case 1 : - // InternalVampireLanguage.g:1685:7: lv_variables_3_1= ruleVLSVariable + // InternalVampireLanguage.g:1729:7: lv_variables_3_1= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_2_0_0()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_3_1=ruleVLSVariable(); state._fsp--; @@ -4509,12 +4624,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1701:7: lv_variables_3_2= ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1745:7: lv_variables_3_2= ruleVLSVariableDeclaration { newCompositeNode(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_2_0_1()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_3_2=ruleVLSVariableDeclaration(); state._fsp--; @@ -4542,7 +4657,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1719:4: (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* + // InternalVampireLanguage.g:1763:4: (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* loop26: do { int alt26=2; @@ -4555,19 +4670,19 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt26) { case 1 : - // InternalVampireLanguage.g:1720:5: otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1764:5: otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) { - otherlv_4=(Token)match(input,39,FOLLOW_40); + otherlv_4=(Token)match(input,39,FOLLOW_41); newLeafNode(otherlv_4, grammarAccess.getVLSUniversalQuantifierAccess().getCommaKeyword_1_3_0()); - // InternalVampireLanguage.g:1724:5: ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) - // InternalVampireLanguage.g:1725:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1768:5: ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1769:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) { - // InternalVampireLanguage.g:1725:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) - // InternalVampireLanguage.g:1726:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1769:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1770:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1726:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1770:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) int alt25=2; int LA25_0 = input.LA(1); @@ -4595,12 +4710,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt25) { case 1 : - // InternalVampireLanguage.g:1727:8: lv_variables_5_1= ruleVLSVariable + // InternalVampireLanguage.g:1771:8: lv_variables_5_1= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_3_1_0_0()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_5_1=ruleVLSVariable(); state._fsp--; @@ -4620,12 +4735,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1743:8: lv_variables_5_2= ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1787:8: lv_variables_5_2= ruleVLSVariableDeclaration { newCompositeNode(grammarAccess.getVLSUniversalQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_3_1_0_1()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_5_2=ruleVLSVariableDeclaration(); state._fsp--; @@ -4662,7 +4777,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } } while (true); - otherlv_6=(Token)match(input,33,FOLLOW_32); + otherlv_6=(Token)match(input,33,FOLLOW_33); newLeafNode(otherlv_6, grammarAccess.getVLSUniversalQuantifierAccess().getRightSquareBracketKeyword_1_4()); @@ -4673,11 +4788,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1771:3: ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1772:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1815:3: ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1816:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1772:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1773:5: lv_operand_8_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:1816:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1817:5: lv_operand_8_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSUniversalQuantifierAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); @@ -4727,7 +4842,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSExistentialQuantifier" - // InternalVampireLanguage.g:1794:1: entryRuleVLSExistentialQuantifier returns [EObject current=null] : iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF ; + // InternalVampireLanguage.g:1838:1: entryRuleVLSExistentialQuantifier returns [EObject current=null] : iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF ; public final EObject entryRuleVLSExistentialQuantifier() throws RecognitionException { EObject current = null; @@ -4735,8 +4850,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1794:65: (iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF ) - // InternalVampireLanguage.g:1795:2: iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF + // InternalVampireLanguage.g:1838:65: (iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF ) + // InternalVampireLanguage.g:1839:2: iv_ruleVLSExistentialQuantifier= ruleVLSExistentialQuantifier EOF { newCompositeNode(grammarAccess.getVLSExistentialQuantifierRule()); pushFollow(FOLLOW_1); @@ -4763,7 +4878,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSExistentialQuantifier" - // InternalVampireLanguage.g:1801:1: ruleVLSExistentialQuantifier returns [EObject current=null] : ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ; + // InternalVampireLanguage.g:1845:1: ruleVLSExistentialQuantifier returns [EObject current=null] : ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ; public final EObject ruleVLSExistentialQuantifier() throws RecognitionException { EObject current = null; @@ -4787,14 +4902,14 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1807:2: ( ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ) - // InternalVampireLanguage.g:1808:2: ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1851:2: ( ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) ) + // InternalVampireLanguage.g:1852:2: ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) { - // InternalVampireLanguage.g:1808:2: ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) - // InternalVampireLanguage.g:1809:3: () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1852:2: ( () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1853:3: () (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1809:3: () - // InternalVampireLanguage.g:1810:4: + // InternalVampireLanguage.g:1853:3: () + // InternalVampireLanguage.g:1854:4: { current = forceCreateModelElement( @@ -4804,24 +4919,24 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1816:3: (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) - // InternalVampireLanguage.g:1817:4: otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' + // InternalVampireLanguage.g:1860:3: (otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' ) + // InternalVampireLanguage.g:1861:4: otherlv_1= '?' otherlv_2= '[' ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* otherlv_6= ']' otherlv_7= ':' { otherlv_1=(Token)match(input,73,FOLLOW_11); newLeafNode(otherlv_1, grammarAccess.getVLSExistentialQuantifierAccess().getQuestionMarkKeyword_1_0()); - otherlv_2=(Token)match(input,32,FOLLOW_40); + otherlv_2=(Token)match(input,32,FOLLOW_41); newLeafNode(otherlv_2, grammarAccess.getVLSExistentialQuantifierAccess().getLeftSquareBracketKeyword_1_1()); - // InternalVampireLanguage.g:1825:4: ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) - // InternalVampireLanguage.g:1826:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1869:4: ( ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1870:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) { - // InternalVampireLanguage.g:1826:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) - // InternalVampireLanguage.g:1827:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1870:5: ( (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1871:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1827:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1871:6: (lv_variables_3_1= ruleVLSVariable | lv_variables_3_2= ruleVLSVariableDeclaration ) int alt27=2; int LA27_0 = input.LA(1); @@ -4849,12 +4964,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt27) { case 1 : - // InternalVampireLanguage.g:1828:7: lv_variables_3_1= ruleVLSVariable + // InternalVampireLanguage.g:1872:7: lv_variables_3_1= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_2_0_0()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_3_1=ruleVLSVariable(); state._fsp--; @@ -4874,12 +4989,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1844:7: lv_variables_3_2= ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1888:7: lv_variables_3_2= ruleVLSVariableDeclaration { newCompositeNode(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_2_0_1()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_3_2=ruleVLSVariableDeclaration(); state._fsp--; @@ -4907,7 +5022,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1862:4: (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* + // InternalVampireLanguage.g:1906:4: (otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) )* loop29: do { int alt29=2; @@ -4920,19 +5035,19 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt29) { case 1 : - // InternalVampireLanguage.g:1863:5: otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1907:5: otherlv_4= ',' ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) { - otherlv_4=(Token)match(input,39,FOLLOW_40); + otherlv_4=(Token)match(input,39,FOLLOW_41); newLeafNode(otherlv_4, grammarAccess.getVLSExistentialQuantifierAccess().getCommaKeyword_1_3_0()); - // InternalVampireLanguage.g:1867:5: ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) - // InternalVampireLanguage.g:1868:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1911:5: ( ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) ) + // InternalVampireLanguage.g:1912:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) { - // InternalVampireLanguage.g:1868:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) - // InternalVampireLanguage.g:1869:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1912:6: ( (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) ) + // InternalVampireLanguage.g:1913:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) { - // InternalVampireLanguage.g:1869:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) + // InternalVampireLanguage.g:1913:7: (lv_variables_5_1= ruleVLSVariable | lv_variables_5_2= ruleVLSVariableDeclaration ) int alt28=2; int LA28_0 = input.LA(1); @@ -4960,12 +5075,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt28) { case 1 : - // InternalVampireLanguage.g:1870:8: lv_variables_5_1= ruleVLSVariable + // InternalVampireLanguage.g:1914:8: lv_variables_5_1= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableParserRuleCall_1_3_1_0_0()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_5_1=ruleVLSVariable(); state._fsp--; @@ -4985,12 +5100,12 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:1886:8: lv_variables_5_2= ruleVLSVariableDeclaration + // InternalVampireLanguage.g:1930:8: lv_variables_5_2= ruleVLSVariableDeclaration { newCompositeNode(grammarAccess.getVLSExistentialQuantifierAccess().getVariablesVLSVariableDeclarationParserRuleCall_1_3_1_0_1()); - pushFollow(FOLLOW_41); + pushFollow(FOLLOW_42); lv_variables_5_2=ruleVLSVariableDeclaration(); state._fsp--; @@ -5027,7 +5142,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } } while (true); - otherlv_6=(Token)match(input,33,FOLLOW_32); + otherlv_6=(Token)match(input,33,FOLLOW_33); newLeafNode(otherlv_6, grammarAccess.getVLSExistentialQuantifierAccess().getRightSquareBracketKeyword_1_4()); @@ -5038,11 +5153,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:1914:3: ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1915:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1958:3: ( (lv_operand_8_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1959:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1915:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1916:5: lv_operand_8_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:1959:4: (lv_operand_8_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:1960:5: lv_operand_8_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSExistentialQuantifierAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); @@ -5092,7 +5207,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSUnaryNegation" - // InternalVampireLanguage.g:1937:1: entryRuleVLSUnaryNegation returns [EObject current=null] : iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF ; + // InternalVampireLanguage.g:1981:1: entryRuleVLSUnaryNegation returns [EObject current=null] : iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF ; public final EObject entryRuleVLSUnaryNegation() throws RecognitionException { EObject current = null; @@ -5100,8 +5215,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1937:57: (iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF ) - // InternalVampireLanguage.g:1938:2: iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF + // InternalVampireLanguage.g:1981:57: (iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF ) + // InternalVampireLanguage.g:1982:2: iv_ruleVLSUnaryNegation= ruleVLSUnaryNegation EOF { newCompositeNode(grammarAccess.getVLSUnaryNegationRule()); pushFollow(FOLLOW_1); @@ -5128,7 +5243,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSUnaryNegation" - // InternalVampireLanguage.g:1944:1: ruleVLSUnaryNegation returns [EObject current=null] : ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) ; + // InternalVampireLanguage.g:1988:1: ruleVLSUnaryNegation returns [EObject current=null] : ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) ; public final EObject ruleVLSUnaryNegation() throws RecognitionException { EObject current = null; @@ -5140,14 +5255,14 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1950:2: ( ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) ) - // InternalVampireLanguage.g:1951:2: ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1994:2: ( ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) ) + // InternalVampireLanguage.g:1995:2: ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) { - // InternalVampireLanguage.g:1951:2: ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) - // InternalVampireLanguage.g:1952:3: () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:1995:2: ( () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) ) + // InternalVampireLanguage.g:1996:3: () otherlv_1= '~' ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) { - // InternalVampireLanguage.g:1952:3: () - // InternalVampireLanguage.g:1953:4: + // InternalVampireLanguage.g:1996:3: () + // InternalVampireLanguage.g:1997:4: { current = forceCreateModelElement( @@ -5161,11 +5276,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { newLeafNode(otherlv_1, grammarAccess.getVLSUnaryNegationAccess().getTildeKeyword_1()); - // InternalVampireLanguage.g:1963:3: ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) - // InternalVampireLanguage.g:1964:4: (lv_operand_2_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:2007:3: ( (lv_operand_2_0= ruleVLSUnitaryFormula ) ) + // InternalVampireLanguage.g:2008:4: (lv_operand_2_0= ruleVLSUnitaryFormula ) { - // InternalVampireLanguage.g:1964:4: (lv_operand_2_0= ruleVLSUnitaryFormula ) - // InternalVampireLanguage.g:1965:5: lv_operand_2_0= ruleVLSUnitaryFormula + // InternalVampireLanguage.g:2008:4: (lv_operand_2_0= ruleVLSUnitaryFormula ) + // InternalVampireLanguage.g:2009:5: lv_operand_2_0= ruleVLSUnitaryFormula { newCompositeNode(grammarAccess.getVLSUnaryNegationAccess().getOperandVLSUnitaryFormulaParserRuleCall_2_0()); @@ -5215,7 +5330,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSUnaryInfix" - // InternalVampireLanguage.g:1986:1: entryRuleVLSUnaryInfix returns [EObject current=null] : iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF ; + // InternalVampireLanguage.g:2030:1: entryRuleVLSUnaryInfix returns [EObject current=null] : iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF ; public final EObject entryRuleVLSUnaryInfix() throws RecognitionException { EObject current = null; @@ -5223,8 +5338,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:1986:54: (iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF ) - // InternalVampireLanguage.g:1987:2: iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF + // InternalVampireLanguage.g:2030:54: (iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF ) + // InternalVampireLanguage.g:2031:2: iv_ruleVLSUnaryInfix= ruleVLSUnaryInfix EOF { newCompositeNode(grammarAccess.getVLSUnaryInfixRule()); pushFollow(FOLLOW_1); @@ -5251,7 +5366,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSUnaryInfix" - // InternalVampireLanguage.g:1993:1: ruleVLSUnaryInfix returns [EObject current=null] : (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) ; + // InternalVampireLanguage.g:2037:1: ruleVLSUnaryInfix returns [EObject current=null] : (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) ; public final EObject ruleVLSUnaryInfix() throws RecognitionException { EObject current = null; @@ -5267,16 +5382,16 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:1999:2: ( (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) ) - // InternalVampireLanguage.g:2000:2: (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) + // InternalVampireLanguage.g:2043:2: ( (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) ) + // InternalVampireLanguage.g:2044:2: (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) { - // InternalVampireLanguage.g:2000:2: (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) - // InternalVampireLanguage.g:2001:3: this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? + // InternalVampireLanguage.g:2044:2: (this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? ) + // InternalVampireLanguage.g:2045:3: this_VLSAtomic_0= ruleVLSAtomic ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? { newCompositeNode(grammarAccess.getVLSUnaryInfixAccess().getVLSAtomicParserRuleCall_0()); - pushFollow(FOLLOW_42); + pushFollow(FOLLOW_43); this_VLSAtomic_0=ruleVLSAtomic(); state._fsp--; @@ -5285,7 +5400,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { current = this_VLSAtomic_0; afterParserOrEnumRuleCall(); - // InternalVampireLanguage.g:2009:3: ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? + // InternalVampireLanguage.g:2053:3: ( ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) )? int alt31=2; int LA31_0 = input.LA(1); @@ -5294,9 +5409,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt31) { case 1 : - // InternalVampireLanguage.g:2010:4: ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) + // InternalVampireLanguage.g:2054:4: ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) ( (lv_right_7_0= ruleVLSAtomic ) ) { - // InternalVampireLanguage.g:2010:4: ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) + // InternalVampireLanguage.g:2054:4: ( ( () otherlv_2= '!=' ) | ( () otherlv_4= '=' ) | ( () otherlv_6= ':=' ) ) int alt30=3; switch ( input.LA(1) ) { case 75: @@ -5323,13 +5438,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt30) { case 1 : - // InternalVampireLanguage.g:2011:5: ( () otherlv_2= '!=' ) + // InternalVampireLanguage.g:2055:5: ( () otherlv_2= '!=' ) { - // InternalVampireLanguage.g:2011:5: ( () otherlv_2= '!=' ) - // InternalVampireLanguage.g:2012:6: () otherlv_2= '!=' + // InternalVampireLanguage.g:2055:5: ( () otherlv_2= '!=' ) + // InternalVampireLanguage.g:2056:6: () otherlv_2= '!=' { - // InternalVampireLanguage.g:2012:6: () - // InternalVampireLanguage.g:2013:7: + // InternalVampireLanguage.g:2056:6: () + // InternalVampireLanguage.g:2057:7: { current = forceCreateModelElementAndSet( @@ -5339,7 +5454,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_2=(Token)match(input,75,FOLLOW_33); + otherlv_2=(Token)match(input,75,FOLLOW_34); newLeafNode(otherlv_2, grammarAccess.getVLSUnaryInfixAccess().getExclamationMarkEqualsSignKeyword_1_0_0_1()); @@ -5350,13 +5465,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2025:5: ( () otherlv_4= '=' ) + // InternalVampireLanguage.g:2069:5: ( () otherlv_4= '=' ) { - // InternalVampireLanguage.g:2025:5: ( () otherlv_4= '=' ) - // InternalVampireLanguage.g:2026:6: () otherlv_4= '=' + // InternalVampireLanguage.g:2069:5: ( () otherlv_4= '=' ) + // InternalVampireLanguage.g:2070:6: () otherlv_4= '=' { - // InternalVampireLanguage.g:2026:6: () - // InternalVampireLanguage.g:2027:7: + // InternalVampireLanguage.g:2070:6: () + // InternalVampireLanguage.g:2071:7: { current = forceCreateModelElementAndSet( @@ -5366,7 +5481,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_4=(Token)match(input,76,FOLLOW_33); + otherlv_4=(Token)match(input,76,FOLLOW_34); newLeafNode(otherlv_4, grammarAccess.getVLSUnaryInfixAccess().getEqualsSignKeyword_1_0_1_1()); @@ -5377,13 +5492,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2039:5: ( () otherlv_6= ':=' ) + // InternalVampireLanguage.g:2083:5: ( () otherlv_6= ':=' ) { - // InternalVampireLanguage.g:2039:5: ( () otherlv_6= ':=' ) - // InternalVampireLanguage.g:2040:6: () otherlv_6= ':=' + // InternalVampireLanguage.g:2083:5: ( () otherlv_6= ':=' ) + // InternalVampireLanguage.g:2084:6: () otherlv_6= ':=' { - // InternalVampireLanguage.g:2040:6: () - // InternalVampireLanguage.g:2041:7: + // InternalVampireLanguage.g:2084:6: () + // InternalVampireLanguage.g:2085:7: { current = forceCreateModelElementAndSet( @@ -5393,7 +5508,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_6=(Token)match(input,77,FOLLOW_33); + otherlv_6=(Token)match(input,77,FOLLOW_34); newLeafNode(otherlv_6, grammarAccess.getVLSUnaryInfixAccess().getColonEqualsSignKeyword_1_0_2_1()); @@ -5406,11 +5521,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2053:4: ( (lv_right_7_0= ruleVLSAtomic ) ) - // InternalVampireLanguage.g:2054:5: (lv_right_7_0= ruleVLSAtomic ) + // InternalVampireLanguage.g:2097:4: ( (lv_right_7_0= ruleVLSAtomic ) ) + // InternalVampireLanguage.g:2098:5: (lv_right_7_0= ruleVLSAtomic ) { - // InternalVampireLanguage.g:2054:5: (lv_right_7_0= ruleVLSAtomic ) - // InternalVampireLanguage.g:2055:6: lv_right_7_0= ruleVLSAtomic + // InternalVampireLanguage.g:2098:5: (lv_right_7_0= ruleVLSAtomic ) + // InternalVampireLanguage.g:2099:6: lv_right_7_0= ruleVLSAtomic { newCompositeNode(grammarAccess.getVLSUnaryInfixAccess().getRightVLSAtomicParserRuleCall_1_1_0()); @@ -5466,7 +5581,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSAtomic" - // InternalVampireLanguage.g:2077:1: entryRuleVLSAtomic returns [EObject current=null] : iv_ruleVLSAtomic= ruleVLSAtomic EOF ; + // InternalVampireLanguage.g:2121:1: entryRuleVLSAtomic returns [EObject current=null] : iv_ruleVLSAtomic= ruleVLSAtomic EOF ; public final EObject entryRuleVLSAtomic() throws RecognitionException { EObject current = null; @@ -5474,8 +5589,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2077:50: (iv_ruleVLSAtomic= ruleVLSAtomic EOF ) - // InternalVampireLanguage.g:2078:2: iv_ruleVLSAtomic= ruleVLSAtomic EOF + // InternalVampireLanguage.g:2121:50: (iv_ruleVLSAtomic= ruleVLSAtomic EOF ) + // InternalVampireLanguage.g:2122:2: iv_ruleVLSAtomic= ruleVLSAtomic EOF { newCompositeNode(grammarAccess.getVLSAtomicRule()); pushFollow(FOLLOW_1); @@ -5502,7 +5617,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSAtomic" - // InternalVampireLanguage.g:2084:1: ruleVLSAtomic returns [EObject current=null] : (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) ; + // InternalVampireLanguage.g:2128:1: ruleVLSAtomic returns [EObject current=null] : (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) ; public final EObject ruleVLSAtomic() throws RecognitionException { EObject current = null; @@ -5519,15 +5634,15 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2090:2: ( (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) ) - // InternalVampireLanguage.g:2091:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:2134:2: ( (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) ) + // InternalVampireLanguage.g:2135:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) { - // InternalVampireLanguage.g:2091:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:2135:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm ) int alt32=4; alt32 = dfa32.predict(input); switch (alt32) { case 1 : - // InternalVampireLanguage.g:2092:3: this_VLSAtomicConstant_0= ruleVLSAtomicConstant + // InternalVampireLanguage.g:2136:3: this_VLSAtomicConstant_0= ruleVLSAtomicConstant { newCompositeNode(grammarAccess.getVLSAtomicAccess().getVLSAtomicConstantParserRuleCall_0()); @@ -5545,7 +5660,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2101:3: this_VLSAtomicFunction_1= ruleVLSAtomicFunction + // InternalVampireLanguage.g:2145:3: this_VLSAtomicFunction_1= ruleVLSAtomicFunction { newCompositeNode(grammarAccess.getVLSAtomicAccess().getVLSAtomicFunctionParserRuleCall_1()); @@ -5563,7 +5678,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2110:3: this_VLSVariable_2= ruleVLSVariable + // InternalVampireLanguage.g:2154:3: this_VLSVariable_2= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSAtomicAccess().getVLSVariableParserRuleCall_2()); @@ -5581,7 +5696,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:2119:3: this_VLSDefinedTerm_3= ruleVLSDefinedTerm + // InternalVampireLanguage.g:2163:3: this_VLSDefinedTerm_3= ruleVLSDefinedTerm { newCompositeNode(grammarAccess.getVLSAtomicAccess().getVLSDefinedTermParserRuleCall_3()); @@ -5621,7 +5736,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSAtomicConstant" - // InternalVampireLanguage.g:2131:1: entryRuleVLSAtomicConstant returns [EObject current=null] : iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF ; + // InternalVampireLanguage.g:2175:1: entryRuleVLSAtomicConstant returns [EObject current=null] : iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF ; public final EObject entryRuleVLSAtomicConstant() throws RecognitionException { EObject current = null; @@ -5629,8 +5744,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2131:58: (iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF ) - // InternalVampireLanguage.g:2132:2: iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF + // InternalVampireLanguage.g:2175:58: (iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF ) + // InternalVampireLanguage.g:2176:2: iv_ruleVLSAtomicConstant= ruleVLSAtomicConstant EOF { newCompositeNode(grammarAccess.getVLSAtomicConstantRule()); pushFollow(FOLLOW_1); @@ -5657,7 +5772,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSAtomicConstant" - // InternalVampireLanguage.g:2138:1: ruleVLSAtomicConstant returns [EObject current=null] : ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) ; + // InternalVampireLanguage.g:2182:1: ruleVLSAtomicConstant returns [EObject current=null] : ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) ; public final EObject ruleVLSAtomicConstant() throws RecognitionException { EObject current = null; @@ -5674,10 +5789,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2144:2: ( ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) ) - // InternalVampireLanguage.g:2145:2: ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) + // InternalVampireLanguage.g:2188:2: ( ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) ) + // InternalVampireLanguage.g:2189:2: ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) { - // InternalVampireLanguage.g:2145:2: ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) + // InternalVampireLanguage.g:2189:2: ( ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) | ( () otherlv_3= '$true' ) | ( () otherlv_5= '$false' ) ) int alt34=3; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5722,13 +5837,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt34) { case 1 : - // InternalVampireLanguage.g:2146:3: ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) + // InternalVampireLanguage.g:2190:3: ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) { - // InternalVampireLanguage.g:2146:3: ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) - // InternalVampireLanguage.g:2147:4: () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) + // InternalVampireLanguage.g:2190:3: ( () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) ) + // InternalVampireLanguage.g:2191:4: () ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) { - // InternalVampireLanguage.g:2147:4: () - // InternalVampireLanguage.g:2148:5: + // InternalVampireLanguage.g:2191:4: () + // InternalVampireLanguage.g:2192:5: { current = forceCreateModelElement( @@ -5738,13 +5853,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2154:4: ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) - // InternalVampireLanguage.g:2155:5: ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) + // InternalVampireLanguage.g:2198:4: ( ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) ) + // InternalVampireLanguage.g:2199:5: ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) { - // InternalVampireLanguage.g:2155:5: ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) - // InternalVampireLanguage.g:2156:6: (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) + // InternalVampireLanguage.g:2199:5: ( (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) ) + // InternalVampireLanguage.g:2200:6: (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) { - // InternalVampireLanguage.g:2156:6: (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) + // InternalVampireLanguage.g:2200:6: (lv_name_1_1= RULE_LOWER_WORD_ID | lv_name_1_2= RULE_SINGLE_QUOTE | lv_name_1_3= RULE_DOLLAR_ID | lv_name_1_4= RULE_DOUBLE_DOLLAR_ID | lv_name_1_5= ruleVLSRole ) int alt33=5; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -5795,7 +5910,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt33) { case 1 : - // InternalVampireLanguage.g:2157:7: lv_name_1_1= RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:2201:7: lv_name_1_1= RULE_LOWER_WORD_ID { lv_name_1_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_2); @@ -5815,7 +5930,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2172:7: lv_name_1_2= RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:2216:7: lv_name_1_2= RULE_SINGLE_QUOTE { lv_name_1_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_2); @@ -5835,7 +5950,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2187:7: lv_name_1_3= RULE_DOLLAR_ID + // InternalVampireLanguage.g:2231:7: lv_name_1_3= RULE_DOLLAR_ID { lv_name_1_3=(Token)match(input,RULE_DOLLAR_ID,FOLLOW_2); @@ -5855,7 +5970,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:2202:7: lv_name_1_4= RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:2246:7: lv_name_1_4= RULE_DOUBLE_DOLLAR_ID { lv_name_1_4=(Token)match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_2); @@ -5875,7 +5990,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 5 : - // InternalVampireLanguage.g:2217:7: lv_name_1_5= ruleVLSRole + // InternalVampireLanguage.g:2261:7: lv_name_1_5= ruleVLSRole { newCompositeNode(grammarAccess.getVLSAtomicConstantAccess().getNameVLSRoleParserRuleCall_0_1_0_4()); @@ -5915,13 +6030,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2237:3: ( () otherlv_3= '$true' ) + // InternalVampireLanguage.g:2281:3: ( () otherlv_3= '$true' ) { - // InternalVampireLanguage.g:2237:3: ( () otherlv_3= '$true' ) - // InternalVampireLanguage.g:2238:4: () otherlv_3= '$true' + // InternalVampireLanguage.g:2281:3: ( () otherlv_3= '$true' ) + // InternalVampireLanguage.g:2282:4: () otherlv_3= '$true' { - // InternalVampireLanguage.g:2238:4: () - // InternalVampireLanguage.g:2239:5: + // InternalVampireLanguage.g:2282:4: () + // InternalVampireLanguage.g:2283:5: { current = forceCreateModelElement( @@ -5942,13 +6057,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2251:3: ( () otherlv_5= '$false' ) + // InternalVampireLanguage.g:2295:3: ( () otherlv_5= '$false' ) { - // InternalVampireLanguage.g:2251:3: ( () otherlv_5= '$false' ) - // InternalVampireLanguage.g:2252:4: () otherlv_5= '$false' + // InternalVampireLanguage.g:2295:3: ( () otherlv_5= '$false' ) + // InternalVampireLanguage.g:2296:4: () otherlv_5= '$false' { - // InternalVampireLanguage.g:2252:4: () - // InternalVampireLanguage.g:2253:5: + // InternalVampireLanguage.g:2296:4: () + // InternalVampireLanguage.g:2297:5: { current = forceCreateModelElement( @@ -5991,7 +6106,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSAtomicFunction" - // InternalVampireLanguage.g:2268:1: entryRuleVLSAtomicFunction returns [EObject current=null] : iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF ; + // InternalVampireLanguage.g:2312:1: entryRuleVLSAtomicFunction returns [EObject current=null] : iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF ; public final EObject entryRuleVLSAtomicFunction() throws RecognitionException { EObject current = null; @@ -5999,8 +6114,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2268:58: (iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF ) - // InternalVampireLanguage.g:2269:2: iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF + // InternalVampireLanguage.g:2312:58: (iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF ) + // InternalVampireLanguage.g:2313:2: iv_ruleVLSAtomicFunction= ruleVLSAtomicFunction EOF { newCompositeNode(grammarAccess.getVLSAtomicFunctionRule()); pushFollow(FOLLOW_1); @@ -6027,7 +6142,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSAtomicFunction" - // InternalVampireLanguage.g:2275:1: ruleVLSAtomicFunction returns [EObject current=null] : ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) ; + // InternalVampireLanguage.g:2319:1: ruleVLSAtomicFunction returns [EObject current=null] : ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) ; public final EObject ruleVLSAtomicFunction() throws RecognitionException { EObject current = null; @@ -6057,10 +6172,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2281:2: ( ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) ) - // InternalVampireLanguage.g:2282:2: ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) + // InternalVampireLanguage.g:2325:2: ( ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) ) + // InternalVampireLanguage.g:2326:2: ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) { - // InternalVampireLanguage.g:2282:2: ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) + // InternalVampireLanguage.g:2326:2: ( ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) | ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) ) int alt37=2; int LA37_0 = input.LA(1); @@ -6078,13 +6193,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt37) { case 1 : - // InternalVampireLanguage.g:2283:3: ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) + // InternalVampireLanguage.g:2327:3: ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) { - // InternalVampireLanguage.g:2283:3: ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) - // InternalVampireLanguage.g:2284:4: () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) + // InternalVampireLanguage.g:2327:3: ( () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) ) + // InternalVampireLanguage.g:2328:4: () ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) { - // InternalVampireLanguage.g:2284:4: () - // InternalVampireLanguage.g:2285:5: + // InternalVampireLanguage.g:2328:4: () + // InternalVampireLanguage.g:2329:5: { current = forceCreateModelElement( @@ -6094,13 +6209,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2291:4: ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) - // InternalVampireLanguage.g:2292:5: ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) + // InternalVampireLanguage.g:2335:4: ( ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) ) + // InternalVampireLanguage.g:2336:5: ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) { - // InternalVampireLanguage.g:2292:5: ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) - // InternalVampireLanguage.g:2293:6: (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) + // InternalVampireLanguage.g:2336:5: ( (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) ) + // InternalVampireLanguage.g:2337:6: (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) { - // InternalVampireLanguage.g:2293:6: (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) + // InternalVampireLanguage.g:2337:6: (lv_constant_1_1= RULE_LOWER_WORD_ID | lv_constant_1_2= RULE_SINGLE_QUOTE | lv_constant_1_3= RULE_DOLLAR_ID | lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID | lv_constant_1_5= ruleVLSRole ) int alt35=5; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -6151,7 +6266,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt35) { case 1 : - // InternalVampireLanguage.g:2294:7: lv_constant_1_1= RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:2338:7: lv_constant_1_1= RULE_LOWER_WORD_ID { lv_constant_1_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_16); @@ -6171,7 +6286,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2309:7: lv_constant_1_2= RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:2353:7: lv_constant_1_2= RULE_SINGLE_QUOTE { lv_constant_1_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_16); @@ -6191,7 +6306,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2324:7: lv_constant_1_3= RULE_DOLLAR_ID + // InternalVampireLanguage.g:2368:7: lv_constant_1_3= RULE_DOLLAR_ID { lv_constant_1_3=(Token)match(input,RULE_DOLLAR_ID,FOLLOW_16); @@ -6211,7 +6326,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:2339:7: lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:2383:7: lv_constant_1_4= RULE_DOUBLE_DOLLAR_ID { lv_constant_1_4=(Token)match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_16); @@ -6231,7 +6346,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 5 : - // InternalVampireLanguage.g:2354:7: lv_constant_1_5= ruleVLSRole + // InternalVampireLanguage.g:2398:7: lv_constant_1_5= ruleVLSRole { newCompositeNode(grammarAccess.getVLSAtomicFunctionAccess().getConstantVLSRoleParserRuleCall_0_1_0_4()); @@ -6264,18 +6379,18 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2372:4: (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) - // InternalVampireLanguage.g:2373:5: otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' + // InternalVampireLanguage.g:2416:4: (otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' ) + // InternalVampireLanguage.g:2417:5: otherlv_2= '(' ( (lv_terms_3_0= ruleVLSFofTerm ) ) (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* otherlv_6= ')' { - otherlv_2=(Token)match(input,38,FOLLOW_33); + otherlv_2=(Token)match(input,38,FOLLOW_34); newLeafNode(otherlv_2, grammarAccess.getVLSAtomicFunctionAccess().getLeftParenthesisKeyword_0_2_0()); - // InternalVampireLanguage.g:2377:5: ( (lv_terms_3_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2378:6: (lv_terms_3_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2421:5: ( (lv_terms_3_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2422:6: (lv_terms_3_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2378:6: (lv_terms_3_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2379:7: lv_terms_3_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2422:6: (lv_terms_3_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2423:7: lv_terms_3_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_0_2_1_0()); @@ -6302,7 +6417,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2396:5: (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* + // InternalVampireLanguage.g:2440:5: (otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) )* loop36: do { int alt36=2; @@ -6315,17 +6430,17 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt36) { case 1 : - // InternalVampireLanguage.g:2397:6: otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2441:6: otherlv_4= ',' ( (lv_terms_5_0= ruleVLSFofTerm ) ) { - otherlv_4=(Token)match(input,39,FOLLOW_33); + otherlv_4=(Token)match(input,39,FOLLOW_34); newLeafNode(otherlv_4, grammarAccess.getVLSAtomicFunctionAccess().getCommaKeyword_0_2_2_0()); - // InternalVampireLanguage.g:2401:6: ( (lv_terms_5_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2402:7: (lv_terms_5_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2445:6: ( (lv_terms_5_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2446:7: (lv_terms_5_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2402:7: (lv_terms_5_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2403:8: lv_terms_5_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2446:7: (lv_terms_5_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2447:8: lv_terms_5_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_0_2_2_1_0()); @@ -6375,13 +6490,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2428:3: ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) + // InternalVampireLanguage.g:2472:3: ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) { - // InternalVampireLanguage.g:2428:3: ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) - // InternalVampireLanguage.g:2429:4: () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' + // InternalVampireLanguage.g:2472:3: ( () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' ) + // InternalVampireLanguage.g:2473:4: () ( (lv_name_8_0= '$less' ) ) otherlv_9= '(' ( (lv_terms_10_0= ruleVLSFofTerm ) ) otherlv_11= ',' ( (lv_terms_12_0= ruleVLSFofTerm ) ) otherlv_13= ')' { - // InternalVampireLanguage.g:2429:4: () - // InternalVampireLanguage.g:2430:5: + // InternalVampireLanguage.g:2473:4: () + // InternalVampireLanguage.g:2474:5: { current = forceCreateModelElement( @@ -6391,11 +6506,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2436:4: ( (lv_name_8_0= '$less' ) ) - // InternalVampireLanguage.g:2437:5: (lv_name_8_0= '$less' ) + // InternalVampireLanguage.g:2480:4: ( (lv_name_8_0= '$less' ) ) + // InternalVampireLanguage.g:2481:5: (lv_name_8_0= '$less' ) { - // InternalVampireLanguage.g:2437:5: (lv_name_8_0= '$less' ) - // InternalVampireLanguage.g:2438:6: lv_name_8_0= '$less' + // InternalVampireLanguage.g:2481:5: (lv_name_8_0= '$less' ) + // InternalVampireLanguage.g:2482:6: lv_name_8_0= '$less' { lv_name_8_0=(Token)match(input,80,FOLLOW_16); @@ -6413,15 +6528,15 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_9=(Token)match(input,38,FOLLOW_33); + otherlv_9=(Token)match(input,38,FOLLOW_34); newLeafNode(otherlv_9, grammarAccess.getVLSAtomicFunctionAccess().getLeftParenthesisKeyword_1_2()); - // InternalVampireLanguage.g:2454:4: ( (lv_terms_10_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2455:5: (lv_terms_10_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2498:4: ( (lv_terms_10_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2499:5: (lv_terms_10_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2455:5: (lv_terms_10_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2456:6: lv_terms_10_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2499:5: (lv_terms_10_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2500:6: lv_terms_10_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_1_3_0()); @@ -6448,15 +6563,15 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - otherlv_11=(Token)match(input,39,FOLLOW_33); + otherlv_11=(Token)match(input,39,FOLLOW_34); newLeafNode(otherlv_11, grammarAccess.getVLSAtomicFunctionAccess().getCommaKeyword_1_4()); - // InternalVampireLanguage.g:2477:4: ( (lv_terms_12_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2478:5: (lv_terms_12_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2521:4: ( (lv_terms_12_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2522:5: (lv_terms_12_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2478:5: (lv_terms_12_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2479:6: lv_terms_12_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2522:5: (lv_terms_12_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2523:6: lv_terms_12_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSAtomicFunctionAccess().getTermsVLSFofTermParserRuleCall_1_5_0()); @@ -6516,7 +6631,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSVariable" - // InternalVampireLanguage.g:2505:1: entryRuleVLSVariable returns [EObject current=null] : iv_ruleVLSVariable= ruleVLSVariable EOF ; + // InternalVampireLanguage.g:2549:1: entryRuleVLSVariable returns [EObject current=null] : iv_ruleVLSVariable= ruleVLSVariable EOF ; public final EObject entryRuleVLSVariable() throws RecognitionException { EObject current = null; @@ -6524,8 +6639,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2505:52: (iv_ruleVLSVariable= ruleVLSVariable EOF ) - // InternalVampireLanguage.g:2506:2: iv_ruleVLSVariable= ruleVLSVariable EOF + // InternalVampireLanguage.g:2549:52: (iv_ruleVLSVariable= ruleVLSVariable EOF ) + // InternalVampireLanguage.g:2550:2: iv_ruleVLSVariable= ruleVLSVariable EOF { newCompositeNode(grammarAccess.getVLSVariableRule()); pushFollow(FOLLOW_1); @@ -6552,7 +6667,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSVariable" - // InternalVampireLanguage.g:2512:1: ruleVLSVariable returns [EObject current=null] : ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) ; + // InternalVampireLanguage.g:2556:1: ruleVLSVariable returns [EObject current=null] : ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) ; public final EObject ruleVLSVariable() throws RecognitionException { EObject current = null; @@ -6562,14 +6677,14 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2518:2: ( ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) ) - // InternalVampireLanguage.g:2519:2: ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) + // InternalVampireLanguage.g:2562:2: ( ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) ) + // InternalVampireLanguage.g:2563:2: ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) { - // InternalVampireLanguage.g:2519:2: ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) - // InternalVampireLanguage.g:2520:3: (lv_name_0_0= RULE_UPPER_WORD_ID ) + // InternalVampireLanguage.g:2563:2: ( (lv_name_0_0= RULE_UPPER_WORD_ID ) ) + // InternalVampireLanguage.g:2564:3: (lv_name_0_0= RULE_UPPER_WORD_ID ) { - // InternalVampireLanguage.g:2520:3: (lv_name_0_0= RULE_UPPER_WORD_ID ) - // InternalVampireLanguage.g:2521:4: lv_name_0_0= RULE_UPPER_WORD_ID + // InternalVampireLanguage.g:2564:3: (lv_name_0_0= RULE_UPPER_WORD_ID ) + // InternalVampireLanguage.g:2565:4: lv_name_0_0= RULE_UPPER_WORD_ID { lv_name_0_0=(Token)match(input,RULE_UPPER_WORD_ID,FOLLOW_2); @@ -6611,7 +6726,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSFofTerm" - // InternalVampireLanguage.g:2540:1: entryRuleVLSFofTerm returns [EObject current=null] : iv_ruleVLSFofTerm= ruleVLSFofTerm EOF ; + // InternalVampireLanguage.g:2584:1: entryRuleVLSFofTerm returns [EObject current=null] : iv_ruleVLSFofTerm= ruleVLSFofTerm EOF ; public final EObject entryRuleVLSFofTerm() throws RecognitionException { EObject current = null; @@ -6619,8 +6734,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2540:51: (iv_ruleVLSFofTerm= ruleVLSFofTerm EOF ) - // InternalVampireLanguage.g:2541:2: iv_ruleVLSFofTerm= ruleVLSFofTerm EOF + // InternalVampireLanguage.g:2584:51: (iv_ruleVLSFofTerm= ruleVLSFofTerm EOF ) + // InternalVampireLanguage.g:2585:2: iv_ruleVLSFofTerm= ruleVLSFofTerm EOF { newCompositeNode(grammarAccess.getVLSFofTermRule()); pushFollow(FOLLOW_1); @@ -6647,7 +6762,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSFofTerm" - // InternalVampireLanguage.g:2547:1: ruleVLSFofTerm returns [EObject current=null] : (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) ; + // InternalVampireLanguage.g:2591:1: ruleVLSFofTerm returns [EObject current=null] : (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) ; public final EObject ruleVLSFofTerm() throws RecognitionException { EObject current = null; @@ -6662,10 +6777,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2553:2: ( (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) ) - // InternalVampireLanguage.g:2554:2: (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:2597:2: ( (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) ) + // InternalVampireLanguage.g:2598:2: (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) { - // InternalVampireLanguage.g:2554:2: (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) + // InternalVampireLanguage.g:2598:2: (this_VLSVariable_0= ruleVLSVariable | this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm | this_VLSDefinedTerm_2= ruleVLSDefinedTerm ) int alt38=3; switch ( input.LA(1) ) { case RULE_UPPER_WORD_ID: @@ -6696,7 +6811,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt38) { case 1 : - // InternalVampireLanguage.g:2555:3: this_VLSVariable_0= ruleVLSVariable + // InternalVampireLanguage.g:2599:3: this_VLSVariable_0= ruleVLSVariable { newCompositeNode(grammarAccess.getVLSFofTermAccess().getVLSVariableParserRuleCall_0()); @@ -6714,7 +6829,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2564:3: this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm + // InternalVampireLanguage.g:2608:3: this_VLSFunctionAsTerm_1= ruleVLSFunctionAsTerm { newCompositeNode(grammarAccess.getVLSFofTermAccess().getVLSFunctionAsTermParserRuleCall_1()); @@ -6732,7 +6847,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2573:3: this_VLSDefinedTerm_2= ruleVLSDefinedTerm + // InternalVampireLanguage.g:2617:3: this_VLSDefinedTerm_2= ruleVLSDefinedTerm { newCompositeNode(grammarAccess.getVLSFofTermAccess().getVLSDefinedTermParserRuleCall_2()); @@ -6772,7 +6887,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSFunctionAsTerm" - // InternalVampireLanguage.g:2585:1: entryRuleVLSFunctionAsTerm returns [EObject current=null] : iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF ; + // InternalVampireLanguage.g:2629:1: entryRuleVLSFunctionAsTerm returns [EObject current=null] : iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF ; public final EObject entryRuleVLSFunctionAsTerm() throws RecognitionException { EObject current = null; @@ -6780,8 +6895,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2585:58: (iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF ) - // InternalVampireLanguage.g:2586:2: iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF + // InternalVampireLanguage.g:2629:58: (iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF ) + // InternalVampireLanguage.g:2630:2: iv_ruleVLSFunctionAsTerm= ruleVLSFunctionAsTerm EOF { newCompositeNode(grammarAccess.getVLSFunctionAsTermRule()); pushFollow(FOLLOW_1); @@ -6808,7 +6923,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSFunctionAsTerm" - // InternalVampireLanguage.g:2592:1: ruleVLSFunctionAsTerm returns [EObject current=null] : ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) ; + // InternalVampireLanguage.g:2636:1: ruleVLSFunctionAsTerm returns [EObject current=null] : ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) ; public final EObject ruleVLSFunctionAsTerm() throws RecognitionException { EObject current = null; @@ -6828,19 +6943,19 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2598:2: ( ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) ) - // InternalVampireLanguage.g:2599:2: ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) + // InternalVampireLanguage.g:2642:2: ( ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) ) + // InternalVampireLanguage.g:2643:2: ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) { - // InternalVampireLanguage.g:2599:2: ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) - // InternalVampireLanguage.g:2600:3: ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? + // InternalVampireLanguage.g:2643:2: ( ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? ) + // InternalVampireLanguage.g:2644:3: ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? { - // InternalVampireLanguage.g:2600:3: ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) - // InternalVampireLanguage.g:2601:4: ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) + // InternalVampireLanguage.g:2644:3: ( ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) ) + // InternalVampireLanguage.g:2645:4: ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) { - // InternalVampireLanguage.g:2601:4: ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) - // InternalVampireLanguage.g:2602:5: (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:2645:4: ( (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) ) + // InternalVampireLanguage.g:2646:5: (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) { - // InternalVampireLanguage.g:2602:5: (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) + // InternalVampireLanguage.g:2646:5: (lv_functor_0_1= RULE_LOWER_WORD_ID | lv_functor_0_2= RULE_SINGLE_QUOTE | lv_functor_0_3= RULE_DOLLAR_ID | lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID ) int alt39=4; switch ( input.LA(1) ) { case RULE_LOWER_WORD_ID: @@ -6872,9 +6987,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt39) { case 1 : - // InternalVampireLanguage.g:2603:6: lv_functor_0_1= RULE_LOWER_WORD_ID + // InternalVampireLanguage.g:2647:6: lv_functor_0_1= RULE_LOWER_WORD_ID { - lv_functor_0_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_43); + lv_functor_0_1=(Token)match(input,RULE_LOWER_WORD_ID,FOLLOW_44); newLeafNode(lv_functor_0_1, grammarAccess.getVLSFunctionAsTermAccess().getFunctorLOWER_WORD_IDTerminalRuleCall_0_0_0()); @@ -6892,9 +7007,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2618:6: lv_functor_0_2= RULE_SINGLE_QUOTE + // InternalVampireLanguage.g:2662:6: lv_functor_0_2= RULE_SINGLE_QUOTE { - lv_functor_0_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_43); + lv_functor_0_2=(Token)match(input,RULE_SINGLE_QUOTE,FOLLOW_44); newLeafNode(lv_functor_0_2, grammarAccess.getVLSFunctionAsTermAccess().getFunctorSINGLE_QUOTETerminalRuleCall_0_0_1()); @@ -6912,9 +7027,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 3 : - // InternalVampireLanguage.g:2633:6: lv_functor_0_3= RULE_DOLLAR_ID + // InternalVampireLanguage.g:2677:6: lv_functor_0_3= RULE_DOLLAR_ID { - lv_functor_0_3=(Token)match(input,RULE_DOLLAR_ID,FOLLOW_43); + lv_functor_0_3=(Token)match(input,RULE_DOLLAR_ID,FOLLOW_44); newLeafNode(lv_functor_0_3, grammarAccess.getVLSFunctionAsTermAccess().getFunctorDOLLAR_IDTerminalRuleCall_0_0_2()); @@ -6932,9 +7047,9 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 4 : - // InternalVampireLanguage.g:2648:6: lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID + // InternalVampireLanguage.g:2692:6: lv_functor_0_4= RULE_DOUBLE_DOLLAR_ID { - lv_functor_0_4=(Token)match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_43); + lv_functor_0_4=(Token)match(input,RULE_DOUBLE_DOLLAR_ID,FOLLOW_44); newLeafNode(lv_functor_0_4, grammarAccess.getVLSFunctionAsTermAccess().getFunctorDOUBLE_DOLLAR_IDTerminalRuleCall_0_0_3()); @@ -6960,7 +7075,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2665:3: (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? + // InternalVampireLanguage.g:2709:3: (otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' )? int alt41=2; int LA41_0 = input.LA(1); @@ -6969,17 +7084,17 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt41) { case 1 : - // InternalVampireLanguage.g:2666:4: otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' + // InternalVampireLanguage.g:2710:4: otherlv_1= '(' ( (lv_terms_2_0= ruleVLSFofTerm ) ) (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* otherlv_5= ')' { - otherlv_1=(Token)match(input,38,FOLLOW_33); + otherlv_1=(Token)match(input,38,FOLLOW_34); newLeafNode(otherlv_1, grammarAccess.getVLSFunctionAsTermAccess().getLeftParenthesisKeyword_1_0()); - // InternalVampireLanguage.g:2670:4: ( (lv_terms_2_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2671:5: (lv_terms_2_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2714:4: ( (lv_terms_2_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2715:5: (lv_terms_2_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2671:5: (lv_terms_2_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2672:6: lv_terms_2_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2715:5: (lv_terms_2_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2716:6: lv_terms_2_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSFunctionAsTermAccess().getTermsVLSFofTermParserRuleCall_1_1_0()); @@ -7006,7 +7121,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2689:4: (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* + // InternalVampireLanguage.g:2733:4: (otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) )* loop40: do { int alt40=2; @@ -7019,17 +7134,17 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { switch (alt40) { case 1 : - // InternalVampireLanguage.g:2690:5: otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2734:5: otherlv_3= ',' ( (lv_terms_4_0= ruleVLSFofTerm ) ) { - otherlv_3=(Token)match(input,39,FOLLOW_33); + otherlv_3=(Token)match(input,39,FOLLOW_34); newLeafNode(otherlv_3, grammarAccess.getVLSFunctionAsTermAccess().getCommaKeyword_1_2_0()); - // InternalVampireLanguage.g:2694:5: ( (lv_terms_4_0= ruleVLSFofTerm ) ) - // InternalVampireLanguage.g:2695:6: (lv_terms_4_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2738:5: ( (lv_terms_4_0= ruleVLSFofTerm ) ) + // InternalVampireLanguage.g:2739:6: (lv_terms_4_0= ruleVLSFofTerm ) { - // InternalVampireLanguage.g:2695:6: (lv_terms_4_0= ruleVLSFofTerm ) - // InternalVampireLanguage.g:2696:7: lv_terms_4_0= ruleVLSFofTerm + // InternalVampireLanguage.g:2739:6: (lv_terms_4_0= ruleVLSFofTerm ) + // InternalVampireLanguage.g:2740:7: lv_terms_4_0= ruleVLSFofTerm { newCompositeNode(grammarAccess.getVLSFunctionAsTermAccess().getTermsVLSFofTermParserRuleCall_1_2_1_0()); @@ -7098,7 +7213,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "entryRuleVLSDefinedTerm" - // InternalVampireLanguage.g:2723:1: entryRuleVLSDefinedTerm returns [EObject current=null] : iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF ; + // InternalVampireLanguage.g:2767:1: entryRuleVLSDefinedTerm returns [EObject current=null] : iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF ; public final EObject entryRuleVLSDefinedTerm() throws RecognitionException { EObject current = null; @@ -7106,8 +7221,8 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { try { - // InternalVampireLanguage.g:2723:55: (iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF ) - // InternalVampireLanguage.g:2724:2: iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF + // InternalVampireLanguage.g:2767:55: (iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF ) + // InternalVampireLanguage.g:2768:2: iv_ruleVLSDefinedTerm= ruleVLSDefinedTerm EOF { newCompositeNode(grammarAccess.getVLSDefinedTermRule()); pushFollow(FOLLOW_1); @@ -7134,7 +7249,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { // $ANTLR start "ruleVLSDefinedTerm" - // InternalVampireLanguage.g:2730:1: ruleVLSDefinedTerm returns [EObject current=null] : ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) ; + // InternalVampireLanguage.g:2774:1: ruleVLSDefinedTerm returns [EObject current=null] : ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) ; public final EObject ruleVLSDefinedTerm() throws RecognitionException { EObject current = null; @@ -7145,10 +7260,10 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { enterRule(); try { - // InternalVampireLanguage.g:2736:2: ( ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) ) - // InternalVampireLanguage.g:2737:2: ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) + // InternalVampireLanguage.g:2780:2: ( ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) ) + // InternalVampireLanguage.g:2781:2: ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) { - // InternalVampireLanguage.g:2737:2: ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) + // InternalVampireLanguage.g:2781:2: ( ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) | ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) ) int alt42=2; int LA42_0 = input.LA(1); @@ -7166,13 +7281,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } switch (alt42) { case 1 : - // InternalVampireLanguage.g:2738:3: ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) + // InternalVampireLanguage.g:2782:3: ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) { - // InternalVampireLanguage.g:2738:3: ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) - // InternalVampireLanguage.g:2739:4: () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) + // InternalVampireLanguage.g:2782:3: ( () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) ) + // InternalVampireLanguage.g:2783:4: () ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) { - // InternalVampireLanguage.g:2739:4: () - // InternalVampireLanguage.g:2740:5: + // InternalVampireLanguage.g:2783:4: () + // InternalVampireLanguage.g:2784:5: { current = forceCreateModelElement( @@ -7182,11 +7297,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2746:4: ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) - // InternalVampireLanguage.g:2747:5: (lv_value_1_0= RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:2790:4: ( (lv_value_1_0= RULE_SIGNED_LITERAL ) ) + // InternalVampireLanguage.g:2791:5: (lv_value_1_0= RULE_SIGNED_LITERAL ) { - // InternalVampireLanguage.g:2747:5: (lv_value_1_0= RULE_SIGNED_LITERAL ) - // InternalVampireLanguage.g:2748:6: lv_value_1_0= RULE_SIGNED_LITERAL + // InternalVampireLanguage.g:2791:5: (lv_value_1_0= RULE_SIGNED_LITERAL ) + // InternalVampireLanguage.g:2792:6: lv_value_1_0= RULE_SIGNED_LITERAL { lv_value_1_0=(Token)match(input,RULE_SIGNED_LITERAL,FOLLOW_2); @@ -7215,13 +7330,13 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } break; case 2 : - // InternalVampireLanguage.g:2766:3: ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) + // InternalVampireLanguage.g:2810:3: ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) { - // InternalVampireLanguage.g:2766:3: ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) - // InternalVampireLanguage.g:2767:4: () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) + // InternalVampireLanguage.g:2810:3: ( () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) ) + // InternalVampireLanguage.g:2811:4: () ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) { - // InternalVampireLanguage.g:2767:4: () - // InternalVampireLanguage.g:2768:5: + // InternalVampireLanguage.g:2811:4: () + // InternalVampireLanguage.g:2812:5: { current = forceCreateModelElement( @@ -7231,11 +7346,11 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { } - // InternalVampireLanguage.g:2774:4: ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) - // InternalVampireLanguage.g:2775:5: (lv_value_3_0= RULE_DOUBLE_QUOTE ) + // InternalVampireLanguage.g:2818:4: ( (lv_value_3_0= RULE_DOUBLE_QUOTE ) ) + // InternalVampireLanguage.g:2819:5: (lv_value_3_0= RULE_DOUBLE_QUOTE ) { - // InternalVampireLanguage.g:2775:5: (lv_value_3_0= RULE_DOUBLE_QUOTE ) - // InternalVampireLanguage.g:2776:6: lv_value_3_0= RULE_DOUBLE_QUOTE + // InternalVampireLanguage.g:2819:5: (lv_value_3_0= RULE_DOUBLE_QUOTE ) + // InternalVampireLanguage.g:2820:6: lv_value_3_0= RULE_DOUBLE_QUOTE { lv_value_3_0=(Token)match(input,RULE_DOUBLE_QUOTE,FOLLOW_2); @@ -7289,37 +7404,38 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { protected DFA15 dfa15 = new DFA15(this); protected DFA32 dfa32 = new DFA32(this); - static final String dfa_1s = "\31\uffff"; - static final String dfa_2s = "\2\uffff\26\1\1\uffff"; - static final String dfa_3s = "\1\6\1\uffff\23\46\3\47\1\uffff"; - static final String dfa_4s = "\1\120\1\uffff\26\115\1\uffff"; - static final String dfa_5s = "\1\uffff\1\1\26\uffff\1\2"; - static final String dfa_6s = "\31\uffff}>"; + static final String dfa_1s = "\32\uffff"; + static final String dfa_2s = "\2\uffff\26\1\2\uffff"; + static final String dfa_3s = "\1\4\1\uffff\23\46\3\47\2\uffff"; + static final String dfa_4s = "\1\120\1\uffff\26\115\2\uffff"; + static final String dfa_5s = "\1\uffff\1\1\26\uffff\1\3\1\2"; + static final String dfa_6s = "\32\uffff}>"; static final String[] dfa_7s = { - "\1\2\1\1\1\3\1\4\1\5\1\27\1\1\31\uffff\1\1\7\uffff\1\6\1\7\1\10\1\11\1\12\1\13\1\14\1\15\1\16\1\17\1\20\1\21\1\22\1\23\1\24\13\uffff\3\1\3\uffff\1\25\1\26\1\1", + "\1\30\1\uffff\1\2\1\1\1\3\1\4\1\5\1\27\1\1\31\uffff\1\1\7\uffff\1\6\1\7\1\10\1\11\1\12\1\13\1\14\1\15\1\16\1\17\1\20\1\21\1\22\1\23\1\24\13\uffff\3\1\3\uffff\1\25\1\26\1\1", + "", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\3\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", + "\2\1\24\uffff\1\31\2\uffff\10\1\3\uffff\3\1", "", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\3\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", - "\2\1\24\uffff\1\30\2\uffff\10\1\3\uffff\3\1", "" }; @@ -7345,7 +7461,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { this.transition = dfa_7; } public String getDescription() { - return "1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration )"; + return "1046:2: (this_VLSTerm_0= ruleVLSTerm | this_VLSDeclaration_1= ruleVLSDeclaration | this_VLSCommentTerm_2= ruleVLSCommentTerm )"; } } static final String dfa_8s = "\30\uffff"; @@ -7403,7 +7519,7 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { this.transition = dfa_14; } public String getDescription() { - return "2091:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm )"; + return "2135:2: (this_VLSAtomicConstant_0= ruleVLSAtomicConstant | this_VLSAtomicFunction_1= ruleVLSAtomicFunction | this_VLSVariable_2= ruleVLSVariable | this_VLSDefinedTerm_3= ruleVLSDefinedTerm )"; } } @@ -7433,23 +7549,24 @@ public class InternalVampireLanguageParser extends AbstractInternalAntlrParser { public static final BitSet FOLLOW_23 = new BitSet(new long[]{0x0000010000000000L}); public static final BitSet FOLLOW_24 = new BitSet(new long[]{0x0000020000000000L}); public static final BitSet FOLLOW_25 = new BitSet(new long[]{0x0000380000000040L}); - public static final BitSet FOLLOW_26 = new BitSet(new long[]{0x0000000000000200L}); - public static final BitSet FOLLOW_27 = new BitSet(new long[]{0x1FFFC04200000142L}); - public static final BitSet FOLLOW_28 = new BitSet(new long[]{0x0000004200000002L}); - public static final BitSet FOLLOW_29 = new BitSet(new long[]{0x1FFFC0C300000140L}); - public static final BitSet FOLLOW_30 = new BitSet(new long[]{0x0000000200000002L}); - public static final BitSet FOLLOW_31 = new BitSet(new long[]{0x0000008000000002L}); - public static final BitSet FOLLOW_32 = new BitSet(new long[]{0x2000000000000000L}); - public static final BitSet FOLLOW_33 = new BitSet(new long[]{0x1FFFC00000001FC0L,0x000000000001C000L}); - public static final BitSet FOLLOW_34 = new BitSet(new long[]{0x4000000000000002L}); - public static final BitSet FOLLOW_35 = new BitSet(new long[]{0x1FFFC00000000740L,0x000000000000C000L}); - public static final BitSet FOLLOW_36 = new BitSet(new long[]{0x8000000000000002L}); - public static final BitSet FOLLOW_37 = new BitSet(new long[]{0x0000000000000002L,0x00000000000000FFL}); - public static final BitSet FOLLOW_38 = new BitSet(new long[]{0x0000000000000002L,0x0000000000000040L}); - public static final BitSet FOLLOW_39 = new BitSet(new long[]{0x0000000000000002L,0x0000000000000080L}); - public static final BitSet FOLLOW_40 = new BitSet(new long[]{0x0000000000000800L}); - public static final BitSet FOLLOW_41 = new BitSet(new long[]{0x0000008200000000L}); - public static final BitSet FOLLOW_42 = new BitSet(new long[]{0x0000000000000002L,0x0000000000003800L}); - public static final BitSet FOLLOW_43 = new BitSet(new long[]{0x0000004000000002L}); + public static final BitSet FOLLOW_26 = new BitSet(new long[]{0x1FFFC04000001FD0L,0x000000000001C700L}); + public static final BitSet FOLLOW_27 = new BitSet(new long[]{0x0000000000000200L}); + public static final BitSet FOLLOW_28 = new BitSet(new long[]{0x1FFFC04200000142L}); + public static final BitSet FOLLOW_29 = new BitSet(new long[]{0x0000004200000002L}); + public static final BitSet FOLLOW_30 = new BitSet(new long[]{0x1FFFC0C300000140L}); + public static final BitSet FOLLOW_31 = new BitSet(new long[]{0x0000000200000002L}); + public static final BitSet FOLLOW_32 = new BitSet(new long[]{0x0000008000000002L}); + public static final BitSet FOLLOW_33 = new BitSet(new long[]{0x2000000000000000L}); + public static final BitSet FOLLOW_34 = new BitSet(new long[]{0x1FFFC00000001FC0L,0x000000000001C000L}); + public static final BitSet FOLLOW_35 = new BitSet(new long[]{0x4000000000000002L}); + public static final BitSet FOLLOW_36 = new BitSet(new long[]{0x1FFFC00000000740L,0x000000000000C000L}); + public static final BitSet FOLLOW_37 = new BitSet(new long[]{0x8000000000000002L}); + public static final BitSet FOLLOW_38 = new BitSet(new long[]{0x0000000000000002L,0x00000000000000FFL}); + public static final BitSet FOLLOW_39 = new BitSet(new long[]{0x0000000000000002L,0x0000000000000040L}); + public static final BitSet FOLLOW_40 = new BitSet(new long[]{0x0000000000000002L,0x0000000000000080L}); + public static final BitSet FOLLOW_41 = new BitSet(new long[]{0x0000000000000800L}); + public static final BitSet FOLLOW_42 = new BitSet(new long[]{0x0000008200000000L}); + public static final BitSet FOLLOW_43 = new BitSet(new long[]{0x0000000000000002L,0x0000000000003800L}); + public static final BitSet FOLLOW_44 = new BitSet(new long[]{0x0000004000000002L}); } \ No newline at end of file diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/serializer/VampireLanguageSemanticSequencer.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/serializer/VampireLanguageSemanticSequencer.java index 67be7b9a..884180e1 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/serializer/VampireLanguageSemanticSequencer.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/serializer/VampireLanguageSemanticSequencer.java @@ -28,6 +28,7 @@ import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOr; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOtherDeclaration; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSRevImplies; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSSatisfiable; +import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTffFormula; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTrue; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTrying; @@ -145,6 +146,9 @@ public class VampireLanguageSemanticSequencer extends AbstractDelegatingSemantic case VampireLanguagePackage.VLS_SATISFIABLE: sequence_VLSConfirmations(context, (VLSSatisfiable) semanticObject); return; + case VampireLanguagePackage.VLS_TERM: + sequence_VLSCommentTerm(context, (VLSTerm) semanticObject); + return; case VampireLanguagePackage.VLS_TFF_FORMULA: sequence_VLSTffFormula(context, (VLSTffFormula) semanticObject); return; @@ -619,6 +623,25 @@ public class VampireLanguageSemanticSequencer extends AbstractDelegatingSemantic } + /** + * Contexts: + * VLSTffTerm returns VLSTerm + * VLSCommentTerm returns VLSTerm + * + * Constraint: + * comment=SINGLE_COMMENT + */ + protected void sequence_VLSCommentTerm(ISerializationContext context, VLSTerm semanticObject) { + if (errorAcceptor != null) { + if (transientValues.isValueTransient(semanticObject, VampireLanguagePackage.Literals.VLS_TERM__COMMENT) == ValueTransient.YES) + errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, VampireLanguagePackage.Literals.VLS_TERM__COMMENT)); + } + SequenceFeeder feeder = createSequencerFeeder(context, semanticObject); + feeder.accept(grammarAccess.getVLSCommentTermAccess().getCommentSINGLE_COMMENTTerminalRuleCall_0(), semanticObject.getComment()); + feeder.finish(); + } + + /** * Contexts: * VLSComment returns VLSComment @@ -782,8 +805,8 @@ public class VampireLanguageSemanticSequencer extends AbstractDelegatingSemantic * Constraint: * ( * (variables+=VLSVariable | variables+=VLSVariableDeclaration) - * variables+=VLSVariableDeclaration? - * (variables+=VLSVariable? variables+=VLSVariableDeclaration?)* + * variables+=VLSVariable? + * (variables+=VLSVariableDeclaration? variables+=VLSVariable?)* * operand=VLSUnitaryFormula * ) */ @@ -1024,8 +1047,8 @@ public class VampireLanguageSemanticSequencer extends AbstractDelegatingSemantic * Constraint: * ( * (variables+=VLSVariable | variables+=VLSVariableDeclaration) - * variables+=VLSVariable? - * (variables+=VLSVariableDeclaration? variables+=VLSVariable?)* + * variables+=VLSVariableDeclaration? + * (variables+=VLSVariable? variables+=VLSVariableDeclaration?)* * operand=VLSUnitaryFormula * ) */ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/services/VampireLanguageGrammarAccess.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/services/VampireLanguageGrammarAccess.java index c84261e9..2548f383 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/services/VampireLanguageGrammarAccess.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/services/VampireLanguageGrammarAccess.java @@ -700,15 +700,16 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { private final Alternatives cAlternatives = (Alternatives)rule.eContents().get(1); private final RuleCall cVLSTermParserRuleCall_0 = (RuleCall)cAlternatives.eContents().get(0); private final RuleCall cVLSDeclarationParserRuleCall_1 = (RuleCall)cAlternatives.eContents().get(1); + private final RuleCall cVLSCommentTermParserRuleCall_2 = (RuleCall)cAlternatives.eContents().get(2); //////////////////////////////////// //// VLS Terms //////////////////////////////////// //VLSTffTerm: - // VLSTerm | VLSDeclaration; + // VLSTerm | VLSDeclaration | VLSCommentTerm; @Override public ParserRule getRule() { return rule; } - //VLSTerm | VLSDeclaration + //VLSTerm | VLSDeclaration | VLSCommentTerm public Alternatives getAlternatives() { return cAlternatives; } //VLSTerm @@ -716,6 +717,24 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { //VLSDeclaration public RuleCall getVLSDeclarationParserRuleCall_1() { return cVLSDeclarationParserRuleCall_1; } + + //VLSCommentTerm + public RuleCall getVLSCommentTermParserRuleCall_2() { return cVLSCommentTermParserRuleCall_2; } + } + public class VLSCommentTermElements extends AbstractParserRuleElementFinder { + private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "ca.mcgill.ecse.dslreasoner.VampireLanguage.VLSCommentTerm"); + private final Assignment cCommentAssignment = (Assignment)rule.eContents().get(1); + private final RuleCall cCommentSINGLE_COMMENTTerminalRuleCall_0 = (RuleCall)cCommentAssignment.eContents().get(0); + + //VLSCommentTerm VLSTerm: + // comment=SINGLE_COMMENT; + @Override public ParserRule getRule() { return rule; } + + //comment=SINGLE_COMMENT + public Assignment getCommentAssignment() { return cCommentAssignment; } + + //SINGLE_COMMENT + public RuleCall getCommentSINGLE_COMMENTTerminalRuleCall_0() { return cCommentSINGLE_COMMENTTerminalRuleCall_0; } } public class VLSDeclarationElements extends AbstractParserRuleElementFinder { private final ParserRule rule = (ParserRule) GrammarUtil.findRuleForName(getGrammar(), "ca.mcgill.ecse.dslreasoner.VampireLanguage.VLSDeclaration"); @@ -1791,6 +1810,7 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { private final VLSAnnotationElements pVLSAnnotation; private final VLSAnnotationTermsElements pVLSAnnotationTerms; private final VLSTffTermElements pVLSTffTerm; + private final VLSCommentTermElements pVLSCommentTerm; private final VLSDeclarationElements pVLSDeclaration; private final VLSOtherDeclarationElements pVLSOtherDeclaration; private final VLSVariableDeclarationElements pVLSVariableDeclaration; @@ -1844,6 +1864,7 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { this.pVLSAnnotation = new VLSAnnotationElements(); this.pVLSAnnotationTerms = new VLSAnnotationTermsElements(); this.pVLSTffTerm = new VLSTffTermElements(); + this.pVLSCommentTerm = new VLSCommentTermElements(); this.pVLSDeclaration = new VLSDeclarationElements(); this.pVLSOtherDeclaration = new VLSOtherDeclarationElements(); this.pVLSVariableDeclaration = new VLSVariableDeclarationElements(); @@ -2182,7 +2203,7 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { //// VLS Terms //////////////////////////////////// //VLSTffTerm: - // VLSTerm | VLSDeclaration; + // VLSTerm | VLSDeclaration | VLSCommentTerm; public VLSTffTermElements getVLSTffTermAccess() { return pVLSTffTerm; } @@ -2191,6 +2212,16 @@ public class VampireLanguageGrammarAccess extends AbstractGrammarElementFinder { return getVLSTffTermAccess().getRule(); } + //VLSCommentTerm VLSTerm: + // comment=SINGLE_COMMENT; + public VLSCommentTermElements getVLSCommentTermAccess() { + return pVLSCommentTerm; + } + + public ParserRule getVLSCommentTermRule() { + return getVLSCommentTermAccess().getRule(); + } + /////////////////// ////TFF Specific // VLSDeclaration: diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTerm.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTerm.java index d1f20508..83941c8b 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTerm.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VLSTerm.java @@ -9,6 +9,12 @@ package ca.mcgill.ecse.dslreasoner.vampireLanguage; * A representation of the model object 'VLS Term'. * * + *

    + * The following features are supported: + *

    + *
      + *
    • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm#getComment Comment}
    • + *
    * * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSTerm() * @model @@ -16,4 +22,30 @@ package ca.mcgill.ecse.dslreasoner.vampireLanguage; */ public interface VLSTerm extends VLSTffTerm { + /** + * Returns the value of the 'Comment' attribute. + * + *

    + * If the meaning of the 'Comment' attribute isn't clear, + * there really should be more of a description here... + *

    + * + * @return the value of the 'Comment' attribute. + * @see #setComment(String) + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage#getVLSTerm_Comment() + * @model + * @generated + */ + String getComment(); + + /** + * Sets the value of the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm#getComment Comment}' attribute. + * + * + * @param value the new value of the 'Comment' attribute. + * @see #getComment() + * @generated + */ + void setComment(String value); + } // VLSTerm diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguageFactory.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguageFactory.java index 171bb39e..a137054e 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguageFactory.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguageFactory.java @@ -86,6 +86,15 @@ public interface VampireLanguageFactory extends EFactory */ VLSTffTerm createVLSTffTerm(); + /** + * Returns a new object of class 'VLS Term'. + * + * + * @return a new object of class 'VLS Term'. + * @generated + */ + VLSTerm createVLSTerm(); + /** * Returns a new object of class 'VLS Declaration'. * @@ -122,15 +131,6 @@ public interface VampireLanguageFactory extends EFactory */ VLSTypeDef createVLSTypeDef(); - /** - * Returns a new object of class 'VLS Term'. - * - * - * @return a new object of class 'VLS Term'. - * @generated - */ - VLSTerm createVLSTerm(); - /** * Returns a new object of class 'VLS Variable'. * diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguagePackage.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguagePackage.java index 7c917251..43327c64 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguagePackage.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/VampireLanguagePackage.java @@ -334,6 +334,34 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_TFF_TERM_FEATURE_COUNT = 0; + /** + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl VLS Term}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSTerm() + * @generated + */ + int VLS_TERM = 7; + + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_TERM__COMMENT = VLS_TFF_TERM_FEATURE_COUNT + 0; + + /** + * The number of structural features of the 'VLS Term' class. + * + * + * @generated + * @ordered + */ + int VLS_TERM_FEATURE_COUNT = VLS_TFF_TERM_FEATURE_COUNT + 1; + /** * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSDeclarationImpl VLS Declaration}' class. * @@ -342,7 +370,7 @@ public interface VampireLanguagePackage extends EPackage * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSDeclaration() * @generated */ - int VLS_DECLARATION = 7; + int VLS_DECLARATION = 8; /** * The feature id for the 'Type' containment reference. @@ -370,7 +398,7 @@ public interface VampireLanguagePackage extends EPackage * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSOtherDeclaration() * @generated */ - int VLS_OTHER_DECLARATION = 8; + int VLS_OTHER_DECLARATION = 9; /** * The feature id for the 'Type' containment reference. @@ -407,7 +435,7 @@ public interface VampireLanguagePackage extends EPackage * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSVariableDeclaration() * @generated */ - int VLS_VARIABLE_DECLARATION = 9; + int VLS_VARIABLE_DECLARATION = 10; /** * The feature id for the 'Type' containment reference. @@ -444,7 +472,7 @@ public interface VampireLanguagePackage extends EPackage * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSTypeDef() * @generated */ - int VLS_TYPE_DEF = 10; + int VLS_TYPE_DEF = 11; /** * The feature id for the 'Type Sig' containment reference. @@ -492,33 +520,23 @@ public interface VampireLanguagePackage extends EPackage int VLS_TYPE_DEF_FEATURE_COUNT = 4; /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl VLS Term}' class. + * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSVariableImpl VLS Variable}' class. * * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSTerm() + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSVariableImpl + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSVariable() * @generated */ - int VLS_TERM = 11; + int VLS_VARIABLE = 12; /** - * The number of structural features of the 'VLS Term' class. + * The feature id for the 'Comment' attribute. * * * @generated * @ordered */ - int VLS_TERM_FEATURE_COUNT = VLS_TFF_TERM_FEATURE_COUNT + 0; - - /** - * The meta object id for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSVariableImpl VLS Variable}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSVariableImpl - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSVariable() - * @generated - */ - int VLS_VARIABLE = 12; + int VLS_VARIABLE__COMMENT = VLS_TERM__COMMENT; /** * The feature id for the 'Name' attribute. @@ -548,6 +566,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_FUNCTION_AS_TERM = 13; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_FUNCTION_AS_TERM__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Functor' attribute. * @@ -585,6 +612,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_DEFINED_TERM = 14; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_DEFINED_TERM__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Value' attribute. * @@ -698,6 +734,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_EQUIVALENT = 19; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_EQUIVALENT__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -735,6 +780,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_IMPLIES = 20; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_IMPLIES__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -772,6 +826,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_REV_IMPLIES = 21; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_REV_IMPLIES__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -809,6 +872,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_XNOR = 22; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_XNOR__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -846,6 +918,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_NOR = 23; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_NOR__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -883,6 +964,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_NAND = 24; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_NAND__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -920,6 +1010,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_AND = 25; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_AND__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -957,6 +1056,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_OR = 26; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_OR__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -994,6 +1102,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_UNIVERSAL_QUANTIFIER = 27; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_UNIVERSAL_QUANTIFIER__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Variables' containment reference list. * @@ -1031,6 +1148,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_EXISTENTIAL_QUANTIFIER = 28; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_EXISTENTIAL_QUANTIFIER__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Variables' containment reference list. * @@ -1068,6 +1194,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_UNARY_NEGATION = 29; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_UNARY_NEGATION__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Operand' containment reference. * @@ -1096,6 +1231,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_INEQUALITY = 30; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_INEQUALITY__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -1133,6 +1277,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_EQUALITY = 31; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_EQUALITY__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -1170,6 +1323,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_ASSIGNMENT = 32; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_ASSIGNMENT__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Left' containment reference. * @@ -1207,6 +1369,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_CONSTANT = 33; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_CONSTANT__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Name' attribute. * @@ -1235,6 +1406,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_TRUE = 34; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_TRUE__COMMENT = VLS_TERM__COMMENT; + /** * The number of structural features of the 'VLS True' class. * @@ -1254,6 +1434,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_FALSE = 35; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_FALSE__COMMENT = VLS_TERM__COMMENT; + /** * The number of structural features of the 'VLS False' class. * @@ -1273,6 +1462,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_FUNCTION = 36; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_FUNCTION__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Constant' attribute. * @@ -1310,6 +1508,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_LESS = 37; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_LESS__COMMENT = VLS_TERM__COMMENT; + /** * The feature id for the 'Name' attribute. * @@ -1347,6 +1554,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_INT = 38; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_INT__COMMENT = VLS_DEFINED_TERM__COMMENT; + /** * The feature id for the 'Value' attribute. * @@ -1375,6 +1591,15 @@ public interface VampireLanguagePackage extends EPackage */ int VLS_DOUBLE_QUOTE = 39; + /** + * The feature id for the 'Comment' attribute. + * + * + * @generated + * @ordered + */ + int VLS_DOUBLE_QUOTE__COMMENT = VLS_DEFINED_TERM__COMMENT; + /** * The feature id for the 'Value' attribute. * @@ -1640,6 +1865,27 @@ public interface VampireLanguagePackage extends EPackage */ EClass getVLSTffTerm(); + /** + * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm VLS Term}'. + * + * + * @return the meta object for class 'VLS Term'. + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm + * @generated + */ + EClass getVLSTerm(); + + /** + * Returns the meta object for the attribute '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm#getComment Comment}'. + * + * + * @return the meta object for the attribute 'Comment'. + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm#getComment() + * @see #getVLSTerm() + * @generated + */ + EAttribute getVLSTerm_Comment(); + /** * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSDeclaration VLS Declaration}'. * @@ -1757,16 +2003,6 @@ public interface VampireLanguagePackage extends EPackage */ EReference getVLSTypeDef_NextType(); - /** - * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm VLS Term}'. - * - * - * @return the meta object for class 'VLS Term'. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm - * @generated - */ - EClass getVLSTerm(); - /** * Returns the meta object for class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSVariable VLS Variable}'. * @@ -2675,6 +2911,24 @@ public interface VampireLanguagePackage extends EPackage */ EClass VLS_TFF_TERM = eINSTANCE.getVLSTffTerm(); + /** + * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl VLS Term}' class. + * + * + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSTerm() + * @generated + */ + EClass VLS_TERM = eINSTANCE.getVLSTerm(); + + /** + * The meta object literal for the 'Comment' attribute feature. + * + * + * @generated + */ + EAttribute VLS_TERM__COMMENT = eINSTANCE.getVLSTerm_Comment(); + /** * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSDeclarationImpl VLS Declaration}' class. * @@ -2771,16 +3025,6 @@ public interface VampireLanguagePackage extends EPackage */ EReference VLS_TYPE_DEF__NEXT_TYPE = eINSTANCE.getVLSTypeDef_NextType(); - /** - * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl VLS Term}' class. - * - * - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VampireLanguagePackageImpl#getVLSTerm() - * @generated - */ - EClass VLS_TERM = eINSTANCE.getVLSTerm(); - /** * The meta object literal for the '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSVariableImpl VLS Variable}' class. * diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTermImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTermImpl.java index c56d7ecd..9f1fa64f 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTermImpl.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VLSTermImpl.java @@ -6,17 +6,47 @@ package ca.mcgill.ecse.dslreasoner.vampireLanguage.impl; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm; import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage; +import org.eclipse.emf.common.notify.Notification; + import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.impl.ENotificationImpl; + /** * * An implementation of the model object 'VLS Term'. * + *

    + * The following features are implemented: + *

    + *
      + *
    • {@link ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl#getComment Comment}
    • + *
    * * @generated */ public class VLSTermImpl extends VLSTffTermImpl implements VLSTerm { + /** + * The default value of the '{@link #getComment() Comment}' attribute. + * + * + * @see #getComment() + * @generated + * @ordered + */ + protected static final String COMMENT_EDEFAULT = null; + + /** + * The cached value of the '{@link #getComment() Comment}' attribute. + * + * + * @see #getComment() + * @generated + * @ordered + */ + protected String comment = COMMENT_EDEFAULT; + /** * * @@ -38,4 +68,110 @@ public class VLSTermImpl extends VLSTffTermImpl implements VLSTerm return VampireLanguagePackage.Literals.VLS_TERM; } + /** + * + * + * @generated + */ + public String getComment() + { + return comment; + } + + /** + * + * + * @generated + */ + public void setComment(String newComment) + { + String oldComment = comment; + comment = newComment; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, VampireLanguagePackage.VLS_TERM__COMMENT, oldComment, comment)); + } + + /** + * + * + * @generated + */ + @Override + public Object eGet(int featureID, boolean resolve, boolean coreType) + { + switch (featureID) + { + case VampireLanguagePackage.VLS_TERM__COMMENT: + return getComment(); + } + return super.eGet(featureID, resolve, coreType); + } + + /** + * + * + * @generated + */ + @Override + public void eSet(int featureID, Object newValue) + { + switch (featureID) + { + case VampireLanguagePackage.VLS_TERM__COMMENT: + setComment((String)newValue); + return; + } + super.eSet(featureID, newValue); + } + + /** + * + * + * @generated + */ + @Override + public void eUnset(int featureID) + { + switch (featureID) + { + case VampireLanguagePackage.VLS_TERM__COMMENT: + setComment(COMMENT_EDEFAULT); + return; + } + super.eUnset(featureID); + } + + /** + * + * + * @generated + */ + @Override + public boolean eIsSet(int featureID) + { + switch (featureID) + { + case VampireLanguagePackage.VLS_TERM__COMMENT: + return COMMENT_EDEFAULT == null ? comment != null : !COMMENT_EDEFAULT.equals(comment); + } + return super.eIsSet(featureID); + } + + /** + * + * + * @generated + */ + @Override + public String toString() + { + if (eIsProxy()) return super.toString(); + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (comment: "); + result.append(comment); + result.append(')'); + return result.toString(); + } + } //VLSTermImpl diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguageFactoryImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguageFactoryImpl.java index 0e25a4cc..c87155c9 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguageFactoryImpl.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguageFactoryImpl.java @@ -72,11 +72,11 @@ public class VampireLanguageFactoryImpl extends EFactoryImpl implements VampireL case VampireLanguagePackage.VLS_TFF_FORMULA: return createVLSTffFormula(); case VampireLanguagePackage.VLS_ANNOTATION: return createVLSAnnotation(); case VampireLanguagePackage.VLS_TFF_TERM: return createVLSTffTerm(); + case VampireLanguagePackage.VLS_TERM: return createVLSTerm(); case VampireLanguagePackage.VLS_DECLARATION: return createVLSDeclaration(); case VampireLanguagePackage.VLS_OTHER_DECLARATION: return createVLSOtherDeclaration(); case VampireLanguagePackage.VLS_VARIABLE_DECLARATION: return createVLSVariableDeclaration(); case VampireLanguagePackage.VLS_TYPE_DEF: return createVLSTypeDef(); - case VampireLanguagePackage.VLS_TERM: return createVLSTerm(); case VampireLanguagePackage.VLS_VARIABLE: return createVLSVariable(); case VampireLanguagePackage.VLS_FUNCTION_AS_TERM: return createVLSFunctionAsTerm(); case VampireLanguagePackage.VLS_DEFINED_TERM: return createVLSDefinedTerm(); @@ -187,6 +187,17 @@ public class VampireLanguageFactoryImpl extends EFactoryImpl implements VampireL return vlsTffTerm; } + /** + * + * + * @generated + */ + public VLSTerm createVLSTerm() + { + VLSTermImpl vlsTerm = new VLSTermImpl(); + return vlsTerm; + } + /** * * @@ -231,17 +242,6 @@ public class VampireLanguageFactoryImpl extends EFactoryImpl implements VampireL return vlsTypeDef; } - /** - * - * - * @generated - */ - public VLSTerm createVLSTerm() - { - VLSTermImpl vlsTerm = new VLSTermImpl(); - return vlsTerm; - } - /** * * diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguagePackageImpl.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguagePackageImpl.java index 676b2786..eae57e97 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguagePackageImpl.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/impl/VampireLanguagePackageImpl.java @@ -115,35 +115,35 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL * * @generated */ - private EClass vlsDeclarationEClass = null; + private EClass vlsTermEClass = null; /** * * * @generated */ - private EClass vlsOtherDeclarationEClass = null; + private EClass vlsDeclarationEClass = null; /** * * * @generated */ - private EClass vlsVariableDeclarationEClass = null; + private EClass vlsOtherDeclarationEClass = null; /** * * * @generated */ - private EClass vlsTypeDefEClass = null; + private EClass vlsVariableDeclarationEClass = null; /** * * * @generated */ - private EClass vlsTermEClass = null; + private EClass vlsTypeDefEClass = null; /** * @@ -634,6 +634,26 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL return vlsTffTermEClass; } + /** + * + * + * @generated + */ + public EClass getVLSTerm() + { + return vlsTermEClass; + } + + /** + * + * + * @generated + */ + public EAttribute getVLSTerm_Comment() + { + return (EAttribute)vlsTermEClass.getEStructuralFeatures().get(0); + } + /** * * @@ -744,16 +764,6 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL return (EReference)vlsTypeDefEClass.getEStructuralFeatures().get(3); } - /** - * - * - * @generated - */ - public EClass getVLSTerm() - { - return vlsTermEClass; - } - /** * * @@ -1464,6 +1474,9 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL vlsTffTermEClass = createEClass(VLS_TFF_TERM); + vlsTermEClass = createEClass(VLS_TERM); + createEAttribute(vlsTermEClass, VLS_TERM__COMMENT); + vlsDeclarationEClass = createEClass(VLS_DECLARATION); createEReference(vlsDeclarationEClass, VLS_DECLARATION__TYPE); @@ -1479,8 +1492,6 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL createEReference(vlsTypeDefEClass, VLS_TYPE_DEF__INIT_TYPE); createEReference(vlsTypeDefEClass, VLS_TYPE_DEF__NEXT_TYPE); - vlsTermEClass = createEClass(VLS_TERM); - vlsVariableEClass = createEClass(VLS_VARIABLE); createEAttribute(vlsVariableEClass, VLS_VARIABLE__NAME); @@ -1604,10 +1615,10 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL // Set bounds for type parameters // Add supertypes to classes + vlsTermEClass.getESuperTypes().add(this.getVLSTffTerm()); vlsDeclarationEClass.getESuperTypes().add(this.getVLSTffTerm()); vlsOtherDeclarationEClass.getESuperTypes().add(this.getVLSDeclaration()); vlsVariableDeclarationEClass.getESuperTypes().add(this.getVLSDeclaration()); - vlsTermEClass.getESuperTypes().add(this.getVLSTffTerm()); vlsVariableEClass.getESuperTypes().add(this.getVLSTerm()); vlsFunctionAsTermEClass.getESuperTypes().add(this.getVLSTerm()); vlsDefinedTermEClass.getESuperTypes().add(this.getVLSTerm()); @@ -1668,6 +1679,9 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL initEClass(vlsTffTermEClass, VLSTffTerm.class, "VLSTffTerm", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEClass(vlsTermEClass, VLSTerm.class, "VLSTerm", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEAttribute(getVLSTerm_Comment(), ecorePackage.getEString(), "comment", null, 0, 1, VLSTerm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEClass(vlsDeclarationEClass, VLSDeclaration.class, "VLSDeclaration", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getVLSDeclaration_Type(), this.getVLSTypeDef(), null, "type", null, 0, 1, VLSDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -1683,8 +1697,6 @@ public class VampireLanguagePackageImpl extends EPackageImpl implements VampireL initEReference(getVLSTypeDef_InitType(), this.getVLSTerm(), null, "initType", null, 0, 1, VLSTypeDef.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getVLSTypeDef_NextType(), this.getVLSTerm(), null, "nextType", null, 0, 1, VLSTypeDef.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEClass(vlsTermEClass, VLSTerm.class, "VLSTerm", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEClass(vlsVariableEClass, VLSVariable.class, "VLSVariable", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEAttribute(getVLSVariable_Name(), ecorePackage.getEString(), "name", null, 0, 1, VLSVariable.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageAdapterFactory.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageAdapterFactory.java index 92b5a89d..9156e24f 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageAdapterFactory.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageAdapterFactory.java @@ -111,6 +111,11 @@ public class VampireLanguageAdapterFactory extends AdapterFactoryImpl return createVLSTffTermAdapter(); } @Override + public Adapter caseVLSTerm(VLSTerm object) + { + return createVLSTermAdapter(); + } + @Override public Adapter caseVLSDeclaration(VLSDeclaration object) { return createVLSDeclarationAdapter(); @@ -131,11 +136,6 @@ public class VampireLanguageAdapterFactory extends AdapterFactoryImpl return createVLSTypeDefAdapter(); } @Override - public Adapter caseVLSTerm(VLSTerm object) - { - return createVLSTermAdapter(); - } - @Override public Adapter caseVLSVariable(VLSVariable object) { return createVLSVariableAdapter(); @@ -403,76 +403,76 @@ public class VampireLanguageAdapterFactory extends AdapterFactoryImpl } /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSDeclaration VLS Declaration}'. + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm VLS Term}'. * * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSDeclaration + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm * @generated */ - public Adapter createVLSDeclarationAdapter() + public Adapter createVLSTermAdapter() { return null; } /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOtherDeclaration VLS Other Declaration}'. + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSDeclaration VLS Declaration}'. * * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOtherDeclaration + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSDeclaration * @generated */ - public Adapter createVLSOtherDeclarationAdapter() + public Adapter createVLSDeclarationAdapter() { return null; } /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSVariableDeclaration VLS Variable Declaration}'. + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOtherDeclaration VLS Other Declaration}'. * * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSVariableDeclaration + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSOtherDeclaration * @generated */ - public Adapter createVLSVariableDeclarationAdapter() + public Adapter createVLSOtherDeclarationAdapter() { return null; } /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTypeDef VLS Type Def}'. + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSVariableDeclaration VLS Variable Declaration}'. * * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTypeDef + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSVariableDeclaration * @generated */ - public Adapter createVLSTypeDefAdapter() + public Adapter createVLSVariableDeclarationAdapter() { return null; } /** - * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm VLS Term}'. + * Creates a new adapter for an object of class '{@link ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTypeDef VLS Type Def}'. * * This default implementation returns null so that we can easily ignore cases; * it's useful to ignore a case when inheritance will catch all the cases anyway. * * @return the new adapter. - * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTerm + * @see ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSTypeDef * @generated */ - public Adapter createVLSTermAdapter() + public Adapter createVLSTypeDefAdapter() { return null; } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageSwitch.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageSwitch.java index 193ac81b..e8c0fde1 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageSwitch.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src-gen/ca/mcgill/ecse/dslreasoner/vampireLanguage/util/VampireLanguageSwitch.java @@ -122,6 +122,14 @@ public class VampireLanguageSwitch extends Switch if (result == null) result = defaultCase(theEObject); return result; } + case VampireLanguagePackage.VLS_TERM: + { + VLSTerm vlsTerm = (VLSTerm)theEObject; + T result = caseVLSTerm(vlsTerm); + if (result == null) result = caseVLSTffTerm(vlsTerm); + if (result == null) result = defaultCase(theEObject); + return result; + } case VampireLanguagePackage.VLS_DECLARATION: { VLSDeclaration vlsDeclaration = (VLSDeclaration)theEObject; @@ -155,14 +163,6 @@ public class VampireLanguageSwitch extends Switch if (result == null) result = defaultCase(theEObject); return result; } - case VampireLanguagePackage.VLS_TERM: - { - VLSTerm vlsTerm = (VLSTerm)theEObject; - T result = caseVLSTerm(vlsTerm); - if (result == null) result = caseVLSTffTerm(vlsTerm); - if (result == null) result = defaultCase(theEObject); - return result; - } case VampireLanguagePackage.VLS_VARIABLE: { VLSVariable vlsVariable = (VLSVariable)theEObject; @@ -530,81 +530,81 @@ public class VampireLanguageSwitch extends Switch } /** - * Returns the result of interpreting the object as an instance of 'VLS Declaration'. + * Returns the result of interpreting the object as an instance of 'VLS Term'. * * This implementation returns null; * returning a non-null result will terminate the switch. * * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'VLS Declaration'. + * @return the result of interpreting the object as an instance of 'VLS Term'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseVLSDeclaration(VLSDeclaration object) + public T caseVLSTerm(VLSTerm object) { return null; } /** - * Returns the result of interpreting the object as an instance of 'VLS Other Declaration'. + * Returns the result of interpreting the object as an instance of 'VLS Declaration'. * * This implementation returns null; * returning a non-null result will terminate the switch. * * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'VLS Other Declaration'. + * @return the result of interpreting the object as an instance of 'VLS Declaration'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseVLSOtherDeclaration(VLSOtherDeclaration object) + public T caseVLSDeclaration(VLSDeclaration object) { return null; } /** - * Returns the result of interpreting the object as an instance of 'VLS Variable Declaration'. + * Returns the result of interpreting the object as an instance of 'VLS Other Declaration'. * * This implementation returns null; * returning a non-null result will terminate the switch. * * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'VLS Variable Declaration'. + * @return the result of interpreting the object as an instance of 'VLS Other Declaration'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseVLSVariableDeclaration(VLSVariableDeclaration object) + public T caseVLSOtherDeclaration(VLSOtherDeclaration object) { return null; } /** - * Returns the result of interpreting the object as an instance of 'VLS Type Def'. + * Returns the result of interpreting the object as an instance of 'VLS Variable Declaration'. * * This implementation returns null; * returning a non-null result will terminate the switch. * * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'VLS Type Def'. + * @return the result of interpreting the object as an instance of 'VLS Variable Declaration'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseVLSTypeDef(VLSTypeDef object) + public T caseVLSVariableDeclaration(VLSVariableDeclaration object) { return null; } /** - * Returns the result of interpreting the object as an instance of 'VLS Term'. + * Returns the result of interpreting the object as an instance of 'VLS Type Def'. * * This implementation returns null; * returning a non-null result will terminate the switch. * * @param object the target of the switch. - * @return the result of interpreting the object as an instance of 'VLS Term'. + * @return the result of interpreting the object as an instance of 'VLS Type Def'. * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseVLSTerm(VLSTerm object) + public T caseVLSTypeDef(VLSTypeDef object) { return null; } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtext b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtext index cd640556..71655a32 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtext +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/src/ca/mcgill/ecse/dslreasoner/VampireLanguage.xtext @@ -208,7 +208,12 @@ VLSAnnotationTerms returns VLSAnnotation: ////////////////////////////////// VLSTffTerm: VLSTerm | - VLSDeclaration + VLSDeclaration | + VLSCommentTerm +; + +VLSCommentTerm returns VLSTerm: + comment = SINGLE_COMMENT ; ///////////////// diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index a60c74b4..07d0db76 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index 63c46199..221a8681 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index b3a43b5a..f24c9c20 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index f3d705a1..0d110422 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index 9e2e4cb2..aebb5604 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 0ace8e93..f4911143 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend index 0ec4d0da..3b5cec0a 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.xtend @@ -9,6 +9,8 @@ import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.Vampire2LogicMapper import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.VampireHandler import ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder.VampireModelInterpretation import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireLanguagePackage +import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel +import ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSFiniteModelImpl import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasonerException @@ -16,7 +18,6 @@ import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicSolverConfiguration import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult import hu.bme.mit.inf.dslreasoner.workspace.ReasonerWorkspace -import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel class VampireSolver extends LogicReasoner { @@ -82,10 +83,12 @@ class VampireSolver extends LogicReasoner { // Start: Vampire -> Logic mapping val backTransformationStart = System.currentTimeMillis // Backwards Mapper - val logicResult = backwardMapper.transformOutput(problem,vampireConfig.solutionScope.numberOfRequiredSolution,vampSol,forwardTrace,transformationTime) + val logicResult = backwardMapper.transformOutput(problem,vampireConfig.solutionScope.numberOfRequiredSolution,vampSol,forwardTrace,solvingTime) val backTransformationTime = System.currentTimeMillis - backTransformationStart // Finish: Vampire -> Logic Mapping + +// print(vampSol.generatedModel.tfformulas.size) return logicResult //currently only a ModelResult } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.xtend index a0084204..489bf423 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.xtend @@ -21,7 +21,9 @@ class Vampire2LogicMapper { } def transformStatistics(MonitoredVampireSolution solution, long transformationTime) { - return createStatistics + return createStatistics => [ + it.transformationTime = solution.solverTime as int + ] // createStatistics => [ // it.transformationTime = transformationTime as int // for(solutionIndex : 0.. warnings // List debugs -// long kodkodTime + long solverTime // val List> aswers val VampireModel generatedModel // val boolean finishedBeforeTimeout @@ -43,8 +43,8 @@ class VampireHandler { val VAMPDIR = "..\\..\\Solvers\\Vampire-Solver\\ca.mcgill.ecse.dslreasoner.vampire.reasoner\\lib\\" val VAMPNAME = "vampire.exe" val TEMPNAME = "TEMP.tptp" - val OPTION = " --mode casc_sat " - val SOLNNAME = "solution.tptp" + val OPTION = " --mode casc_sat -t 300 " + val SOLNNAME = "_solution" + configuration.typeScopes.maxNewElements + ".tptp" val PATH = "C:/cygwin64/bin" val wsURI = workspace.workspaceURI @@ -57,9 +57,11 @@ class VampireHandler { // 2. run command and save to // need to have cygwin downloaded + var startTime = System.currentTimeMillis val p = Runtime.runtime.exec(CMD + vampLoc + OPTION + tempLoc + " > " + solnLoc, newArrayList("Path=" + PATH)) // 2.1 determine time left p.waitFor + val solverTime = System.currentTimeMillis - startTime // 2.2 store output into local variable val BufferedReader reader = new BufferedReader(new InputStreamReader(p.getInputStream())); @@ -80,7 +82,7 @@ class VampireHandler { // println((root.get(0) as VampireModel ).comments) - return new MonitoredVampireSolution(root.get(0) as VampireModel) + return new MonitoredVampireSolution(solverTime, root.get(0) as VampireModel) /* * //Prepare diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireModelInterpretation.xtend b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireModelInterpretation.xtend index 9eb47f41..063dcf2a 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireModelInterpretation.xtend +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireModelInterpretation.xtend @@ -33,6 +33,7 @@ import java.util.Map import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.* import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.RelationDefinition import java.util.concurrent.TimeUnit +import ca.mcgill.ecse.dslreasoner.vampireLanguage.impl.VLSTermImpl class VampireModelInterpretation implements LogicModelInterpretation { protected val extension LogiclanguageFactory factory = LogiclanguageFactory.eINSTANCE @@ -79,10 +80,10 @@ class VampireModelInterpretation implements LogicModelInterpretation { // println() // println(trace.type2Predicate) // Fill keys of map - println(trace.type2Predicate.keySet) +// println(trace.type2Predicate.keySet) val allTypeDecls = trace.type2Predicate.keySet.filter[class == TypeDeclarationImpl] val allTypeFunctions = trace.predicate2Type - println(trace.type2Predicate.keySet.filter[class == TypeDefinitionImpl]) +// println(trace.type2Predicate.keySet.filter[class == TypeDefinitionImpl]) for (type : allTypeDecls) { type2DefinedElement.put(type as TypeDeclaration, newArrayList) @@ -97,7 +98,7 @@ class VampireModelInterpretation implements LogicModelInterpretation { for (formula : typeFormulas) { // get associated type val associatedTypeName = (formula as VLSTffFormula).name.substring(10) - print(associatedTypeName) +// print(associatedTypeName) val associatedFunctions = allTypeFunctions.keySet.filter[constant == associatedTypeName] if (associatedFunctions.length > 0) { val associatedFunction = associatedFunctions.get(0) as VLSFunction @@ -132,7 +133,7 @@ class VampireModelInterpretation implements LogicModelInterpretation { } - printMap() +// printMap() // 3. get relations // Fill keys of map @@ -153,6 +154,7 @@ class VampireModelInterpretation implements LogicModelInterpretation { val relFormulas = model.tfformulas.filter[name.length > 12 && name.substring(0, 12) == "predicate_r_"] for (formula : relFormulas) { +// println(formula) // get associated type val associatedRelName = (formula as VLSTffFormula).name.substring(10) @@ -169,7 +171,7 @@ class VampireModelInterpretation implements LogicModelInterpretation { end = false val List instances = newArrayList while (!end) { - if (andFormulaTerm.class == VLSAndImpl) { + if (andFormulaTerm.class != null && andFormulaTerm.class == VLSAndImpl) { val andFormula = andFormulaTerm as VLSAnd val andRight = andFormula.right addRelIfNotNeg(andRight, instances) @@ -202,6 +204,7 @@ class VampireModelInterpretation implements LogicModelInterpretation { } println() + println("--------END ELEMENTS MAP----------") } def printMap2() { @@ -226,7 +229,8 @@ class VampireModelInterpretation implements LogicModelInterpretation { } def private addRelIfNotNeg(VLSTerm term, List list) { - if (term.class != VLSUnaryNegationImpl) { +// println("xxx " + term.class) + if (term.class != VLSUnaryNegationImpl && term.class != VLSTermImpl) { val nodeName1 = ((term as VLSFunction).terms.get(0) as VLSFunctionAsTerm).functor val nodeName2 = ((term as VLSFunction).terms.get(1) as VLSFunctionAsTerm).functor val strArr = newArrayList(nodeName1, nodeName2) @@ -247,9 +251,9 @@ class VampireModelInterpretation implements LogicModelInterpretation { } def private dispatch getElementsDispatch(TypeDefinition declaration) { - println("~~" + declaration) - println(declaration.elements) - println() +// println("~~" + declaration) +// println(declaration.elements) +// println() return declaration.elements } @@ -258,18 +262,18 @@ class VampireModelInterpretation implements LogicModelInterpretation { } override getInterpretation(RelationDeclaration relation, Object[] parameterSubstitution) { - print("-- " + relation.name) +// print("-- " + relation.name) val node1 = (parameterSubstitution.get(0) as DefinedElement).name val node2 = (parameterSubstitution.get(1) as DefinedElement).name val realRelations = relation.lookup(relDec2Inst) for (real : realRelations) { if (real.contains(node1) && real.contains(node2)) { - println(" true") +// println(" true") TimeUnit.MILLISECONDS.sleep(10) return true } } - println(" false") +// println(" false") TimeUnit.MILLISECONDS.sleep(10) return false } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index 972af7b4..600187ca 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 071db3ce..9517185f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java index a7780e97..1241dcb2 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/VampireSolver.java @@ -79,7 +79,7 @@ public class VampireSolver extends LogicReasoner { long _currentTimeMillis_1 = System.currentTimeMillis(); final long solvingTime = (_currentTimeMillis_1 - solverStart); final long backTransformationStart = System.currentTimeMillis(); - final ModelResult logicResult = this.backwardMapper.transformOutput(problem, vampireConfig.solutionScope.numberOfRequiredSolution, vampSol, forwardTrace, transformationTime); + final ModelResult logicResult = this.backwardMapper.transformOutput(problem, vampireConfig.solutionScope.numberOfRequiredSolution, vampSol, forwardTrace, solvingTime); long _currentTimeMillis_2 = System.currentTimeMillis(); final long backTransformationTime = (_currentTimeMillis_2 - backTransformationStart); return logicResult; diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 8ce1beed..3ebc907b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 31cc2f43..ebe7bb60 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 552bcd6c..c9ae6c62 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 680bcfe1..ec8fae35 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 9cc64d7c..5e770b94 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index f7259e75..1d3cd01c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 0083e90f..72067608 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index 116b2d15..a9228720 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index 081757ca..3697ed87 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 3471f95b..c489bf07 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 1c707ca6..8fe89f37 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index d8e3808c..b327631b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.java index 29a2ecea..4fbf7291 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/Vampire2LogicMapper.java @@ -31,6 +31,11 @@ public class Vampire2LogicMapper { } public Statistics transformStatistics(final MonitoredVampireSolution solution, final long transformationTime) { - return this.resultFactory.createStatistics(); + Statistics _createStatistics = this.resultFactory.createStatistics(); + final Procedure1 _function = (Statistics it) -> { + long _solverTime = solution.getSolverTime(); + it.setTransformationTime(((int) _solverTime)); + }; + return ObjectExtensions.operator_doubleArrow(_createStatistics, _function); } } diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java index 4764ae28..0c8b0013 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/VampireHandler.java @@ -24,8 +24,8 @@ public class VampireHandler { final String VAMPDIR = "..\\..\\Solvers\\Vampire-Solver\\ca.mcgill.ecse.dslreasoner.vampire.reasoner\\lib\\"; final String VAMPNAME = "vampire.exe"; final String TEMPNAME = "TEMP.tptp"; - final String OPTION = " --mode casc_sat "; - final String SOLNNAME = "solution.tptp"; + final String OPTION = " --mode casc_sat -t 300 "; + final String SOLNNAME = (("_solution" + Integer.valueOf(configuration.typeScopes.maxNewElements)) + ".tptp"); final String PATH = "C:/cygwin64/bin"; final URI wsURI = workspace.getWorkspaceURI(); final String tempLoc = (wsURI + TEMPNAME); @@ -33,8 +33,11 @@ public class VampireHandler { final String solnLoc = (_plus + " "); final String vampLoc = (VAMPDIR + VAMPNAME); String tempURI = workspace.writeModel(problem, TEMPNAME).toFileString(); + long startTime = System.currentTimeMillis(); final Process p = Runtime.getRuntime().exec((((((CMD + vampLoc) + OPTION) + tempLoc) + " > ") + solnLoc), ((String[])Conversions.unwrapArray(CollectionLiterals.newArrayList(("Path=" + PATH)), String.class))); p.waitFor(); + long _currentTimeMillis = System.currentTimeMillis(); + final long solverTime = (_currentTimeMillis - startTime); InputStream _inputStream = p.getInputStream(); InputStreamReader _inputStreamReader = new InputStreamReader(_inputStream); final BufferedReader reader = new BufferedReader(_inputStreamReader); @@ -46,7 +49,7 @@ public class VampireHandler { workspace.getFile(TEMPNAME).delete(); final EList root = workspace.readModel(VampireModel.class, SOLNNAME).eResource().getContents(); EObject _get = root.get(0); - return new MonitoredVampireSolution(((VampireModel) _get)); + return new MonitoredVampireSolution(solverTime, ((VampireModel) _get)); } catch (Throwable _e) { throw Exceptions.sneakyThrow(_e); } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF index 0b81cb7f..bca8e840 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF @@ -26,7 +26,8 @@ Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", org.eclipse.xtext.xbase.lib;bundle-version="2.12.0", - hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0" + hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph;bundle-version="1.0.0" Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.standalone.test Bundle-ActivationPolicy: lazy diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore index 0e800e4a..f0bab228 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/metamodels/yakindu.ecore @@ -19,7 +19,9 @@ eType="#//Vertex" eOpposite="#//Vertex/outgoingTransitions"/> - + + + @@ -30,4 +32,9 @@ + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql index ea8184de..ec9db980 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/queries/ca/mcgill/ecse/dslreasoner/standalone/test/yakindu/queries/yakinduPatterns.vql @@ -1,6 +1,6 @@ package ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries -import epackage "YakinduMetamodel" +import epackage "hu.bme.mit.inf.yakindumm" ///////// // Entry diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF index 2ea274a4..9e50006e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF @@ -1,11 +1,21 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 -Bundle-Name: Test +Bundle-Name: %pluginName Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.test;singleton:=true Bundle-Version: 1.0.0.qualifier -Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries +Bundle-ClassPath: . +Bundle-Vendor: %providerName +Bundle-Localization: plugin +Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries, + yakindumm, + yakindumm.impl, + yakindumm.util, + yakindumm.yakindumm, + yakindumm.yakindumm.impl, + yakindumm.yakindumm.util Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.emf.ecore, + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport, org.eclipse.viatra.query.runtime.rete, org.eclipse.viatra.query.runtime.localsearch, com.google.guava, @@ -32,6 +42,7 @@ Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, org.eclipse.collections;bundle-version="9.2.0", hu.bme.mit.inf.dslreasoner.application.FAMTest;bundle-version="1.0.0", ca.mcgill.ecse.dslreasoner.standalone.test;bundle-version="1.0.0" -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.vampire.test +Bundle-ActivationPolicy: lazy +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/Yakindu.xmi b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/Yakindu.xmi deleted file mode 100644 index 49b1f89d..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/Yakindu.xmi +++ /dev/null @@ -1,4 +0,0 @@ - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/Yakindu.xmi b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/Yakindu.xmi new file mode 100644 index 00000000..49b1f89d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/Yakindu.xmi @@ -0,0 +1,4 @@ + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/yakindu.ecore b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/yakindu.ecore deleted file mode 100644 index 0c944db8..00000000 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/initialModels/yakindu/yakindu.ecore +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem index 226150e8..f86a2f3c 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem @@ -1,5 +1,5 @@ - + @@ -496,22 +496,6 @@ - - - - - - - - - - - - - - - - @@ -572,197 +556,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -787,10 +580,4 @@ - - - - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.properties b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.properties new file mode 100644 index 00000000..6021c31d --- /dev/null +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.properties @@ -0,0 +1,4 @@ +# + +pluginName = Test +providerName = www.example.org diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml index b0735f37..6a9aee5e 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/plugin.xml @@ -1,10 +1,15 @@ + + + + + + + + - - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend index 70ded02d..35b76350 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.xtend @@ -50,7 +50,7 @@ class EcoreTest { it.documentationLevel = DocumentationLevel::FULL ] - solution = reasoner.solve(logicProblem, vampireConfig, workspace, "ECO") + solution = reasoner.solve(logicProblem, vampireConfig, workspace) println("Problem solved") 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 5143641b..a7da818c 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 @@ -2,12 +2,13 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration +import functionalarchitecture.FAMTerminator import functionalarchitecture.Function import functionalarchitecture.FunctionalArchitectureModel import functionalarchitecture.FunctionalInterface import functionalarchitecture.FunctionalOutput import functionalarchitecture.FunctionalarchitecturePackage -import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns +//import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel @@ -22,7 +23,6 @@ import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace import java.util.HashMap import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl -import functionalarchitecture.FAMTerminator class FAMTest { def static void main(String[] args) { @@ -47,15 +47,15 @@ class FAMTest { // Load DSL val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) val partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi") - val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) -// val queries = null +// val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) + val queries = null println("DSL loaded") val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) var problem = modelGenerationProblem.output problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output - problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output +// problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output workspace.writeModel(problem, "Fam.logicproblem") println("Problem created") @@ -94,14 +94,15 @@ class FAMTest { it.typeScopes.minNewElements = 8//24 it.typeScopes.maxNewElements = 10//25 - if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin +// if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin // if(typeMapMax.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax it.contCycleLevel = 5 it.uniquenessDuplicates = false ] var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace) - + + println("Problem solved") // visualisation, see var interpretations = reasoner.getInterpretations(solution as ModelResult) // interpretations.get(0) as VampireModelInterpretation diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend index fb1bdb59..057bcf12 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/src/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.xtend @@ -1,25 +1,27 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.yakinduPackage +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration +import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel +import functionalarchitecture.FunctionalarchitecturePackage import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel -import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult +import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace -import java.util.HashMap +import java.io.PrintWriter import org.eclipse.emf.ecore.resource.Resource import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl -import ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.* - class YakinduTest { def static void main(String[] args) { val Ecore2Logic ecore2Logic = new Ecore2Logic + val Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic) val Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic) val InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic @@ -35,76 +37,166 @@ class YakinduTest { println("Input and output workspaces are created") - val metamodel = GeneralTest.loadMetamodel(yakinduPackage.eINSTANCE) - val partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/yakinduinstance.xmi") -// val queries = GeneralTest.loadQueries(metamodel, yakinduPatterns.instance) - val queries = null - +// val metamodel = GeneralTest.loadMetamodel(YakindummPackage.eINSTANCE) + val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) +// val partialModel = GeneralTest.loadPartialModel(inputs, "yakindu/Yakindu.xmi") + val partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi") +// val queries = GeneralTest.loadQueries(metamodel, YakinduPatterns.instance) + val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) +// val queries = null println("DSL loaded") - val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) - var problem = modelGenerationProblem.output - problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output + var MAX = 150 + var START = 10 + var INC = 20 + var REPS = 1 + + val EXACT = -1 + if (EXACT!= -1) { + MAX = EXACT + START = EXACT + INC = 1 + REPS = 5 + } + + var writer = new PrintWriter(workspace.workspaceURI + "//yakinduStats.csv") + writer.append("size,") + for (var x = 0; x < REPS; x++) { + writer.append("t" + x + ",") + } + writer.append("avg\n") + var totalTime = 0.0 + var totFound = 0.0 + var modelFound = true + var LogicResult solution = null + for (var i = START; i <= MAX; i += INC) { + val num = (i - START) / INC + print("Generation " + num + ": SIZE=" + i + " Attempt: ") + writer.append(i + ",") + totalTime = 0.0 + totFound = 0.0 + modelFound = true + for (var j = 0; j < REPS; j++) { + + print(j) + + val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) + var problem = modelGenerationProblem.output + problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output // problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output - workspace.writeModel(problem, "Yakindu.logicproblem") - - println("Problem created") - - // Start Time - var startTime = System.currentTimeMillis - - var VampireSolver reasoner - // * - reasoner = new VampireSolver - - // ///////////////////////////////////////////////////// - // Minimum Scope - val classMapMin = new HashMap - classMapMin.put(Region, 1) - classMapMin.put(Transition, 2) - classMapMin.put(CompositeElement, 3) - val typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.trace) - - // Maximum Scope - val classMapMax = new HashMap - classMapMax.put(Region, 5) - classMapMax.put(Transition, 2) - classMapMax.put(Synchronization, 4) - val typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.trace) - - // Define Config File - val vampireConfig = new VampireSolverConfiguration => [ - // add configuration things, in config file first - it.documentationLevel = DocumentationLevel::FULL - - it.typeScopes.minNewElements = 20 - it.typeScopes.maxNewElements = 30 - if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin - if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax - it.contCycleLevel = 5 - it.uniquenessDuplicates = false - ] - - var LogicResult solution = reasoner.solve(problem, vampireConfig, workspace, "YAK") - - /*/ - * - * reasoner = new AlloySolver - * val alloyConfig = new AlloySolverConfiguration => [ - * it.typeScopes.maxNewElements = 7 - * it.typeScopes.minNewElements = 3 - * it.solutionScope.numberOfRequiredSolution = 1 - * it.typeScopes.maxNewIntegers = 0 - * it.documentationLevel = DocumentationLevel::NORMAL - * ] - * solution = reasoner.solve(problem, alloyConfig, workspace) - //*/ - // ///////////////////////////////////////////////////// - var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 - var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 - - println("Problem solved") - println("Time was: " + totalTimeMin + ":" + totalTimeSec) + workspace.writeModel(problem, "Yakindu.logicproblem") + +// println("Problem created") +// Start Time + var startTime = System.currentTimeMillis + + var VampireSolver reasoner + // * + reasoner = new VampireSolver + + // ///////////////////////////////////////////////////// + // Minimum Scope +// val classMapMin = new HashMap +// classMapMin.put(Region, 1) +// classMapMin.put(Transition, 2) +// classMapMin.put(CompositeElement, 3) +// val typeMapMin = GeneralTest.getTypeMap(classMapMin, metamodel, ecore2Logic, modelGenerationProblem.trace) + // Maximum Scope +// val classMapMax = new HashMap +// classMapMax.put(Region, 5) +// classMapMax.put(Transition, 2) +// classMapMax.put(Synchronization, 4) +// val typeMapMax = GeneralTest.getTypeMap(classMapMax, metamodel, ecore2Logic, modelGenerationProblem.trace) + // Define Config File + val size = i + val inc = INC + val vampireConfig = new VampireSolverConfiguration => [ + // add configuration things, in config file first + it.documentationLevel = DocumentationLevel::FULL + + it.typeScopes.minNewElements = size - inc + it.typeScopes.maxNewElements = size +// if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin +// if(typeMapMin.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax + it.contCycleLevel = 5 + it.uniquenessDuplicates = false + ] + + solution = reasoner.solve(problem, vampireConfig, workspace) +// print((solution as ModelResult).representation.get(0)) + val soln = ((solution as ModelResult).representation.get(0) as VampireModel) +// println(soln.confirmations) +// println((solution as ModelResult).representation) +// modelFound = !soln.confirmations.filter [ +// class == VLSFiniteModelImpl +// ].isEmpty +// +// if (modelFound) { + val time = solution.statistics.transformationTime / 1000.0 + writer.append(time + ",") + print("(" + time + ")..") + totalTime += time + totFound += 1 +// } else { +// writer.append("MNF" + ",") +//// print("MNF") +// } + // println("Problem solved") + // visualisation, see +// var interpretations = reasoner.getInterpretations(solution as ModelResult) + /* interpretations.get(0) as VampireModelInterpretation + * println(ecore2Logic.IsAttributeValue(modelGenerationProblem.trace, ) + * Literal(modelGenerationProblem.trace, ecore2Logic.allLiteralsInScope(modelGenerationProblem.trace).get(0) ) + * ) + * println((ecore2Logic.allAttributesInScope(modelGenerationProblem.trace)).get(0).EAttributeType) + print(interpretations.class)*/ +// for (interpretation : interpretations) { +// val model = logic2Ecore.transformInterpretation(interpretation, modelGenerationProblem.trace) +// workspace.writeModel(model, "model.xmi") + /* val representation = im2pi.transform(modelGenerationProblem, model.eAllContents.toList, false)//solution.representation.get(0) // TODO: fix for multiple represenations + * if (representation instanceof PartialInterpretation) { + * val vis1 = new PartialInterpretation2Gml + * val gml = vis1.transform(representation) + * workspace.writeText("model.gml", gml) + + * val vis2 = new GraphvizVisualiser + * val dot = vis2.visualiseConcretization(representation) + * dot.writeToFile(workspace, "model.png") + * } else { + * println("ERROR") + * } + look here: hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor*/ +// } + /*/ + * + * reasoner = new AlloySolver + * val alloyConfig = new AlloySolverConfiguration => [ + * it.typeScopes.maxNewElements = 7 + * it.typeScopes.minNewElements = 3 + * it.solutionScope.numberOfRequiredSolution = 1 + * it.typeScopes.maxNewIntegers = 0 + * it.documentationLevel = DocumentationLevel::NORMAL + * ] + * solution = reasoner.solve(problem, alloyConfig, workspace) + //*/ + // ///////////////////////////////////////////////////// +// var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 +// var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 +// println("Problem solved") +// println("Time was: " + totalTimeMin + ":" + totalTimeSec) + } + println() + var avg = 0.0 + if (totFound == 0) { + avg = -1 + } else { + avg = totalTime / totFound + } + writer.append(avg.toString) + writer.append("\n") + } + writer.close + } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index a30b7cfc..4880c751 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index a818eb7e..8ad6dfed 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index b913bd4b..164e6c2f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index 4a9e17e1..46cad7ee 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 3dcefc79..eeb7c77a 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java index 01503783..7019f162 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/EcoreTest.java @@ -1,9 +1,68 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; +import ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.filesystemPackage; +import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; +import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.LogicReasoner; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; +import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; +import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; +import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; +import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.ObjectExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; + @SuppressWarnings("all") public class EcoreTest { public static void main(final String[] args) { - throw new Error("Unresolved compilation problems:" - + "\nInvalid number of arguments. The method solve(LogicProblem, LogicSolverConfiguration, ReasonerWorkspace) is not applicable for the arguments (LogicProblem,VampireSolverConfiguration,FileSystemWorkspace,String)"); + try { + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/FEcoreTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(filesystemPackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "fs/filesystemInstance.xmi"); + final Object queries = null; + InputOutput.println("DSL loaded"); + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + final TracedOutput modelExtensionProblem = instanceModel2Logic.transform(modelGenerationProblem, partialModel); + final LogicProblem logicProblem = modelGenerationProblem.getOutput(); + InputOutput.println("Problem created"); + LogicResult solution = null; + LogicReasoner reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + solution = reasoner.solve(logicProblem, vampireConfig, workspace); + InputOutput.println("Problem solved"); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index 26252d6c..8cd08fd8 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -8,7 +8,6 @@ import functionalarchitecture.Function; import functionalarchitecture.FunctionalArchitectureModel; import functionalarchitecture.FunctionalOutput; import functionalarchitecture.FunctionalarchitecturePackage; -import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; @@ -22,8 +21,6 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult; import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2LogicConfiguration; -import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation; import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; @@ -63,14 +60,12 @@ public class FAMTest { InputOutput.println("Input and output workspaces are created"); final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); final EList partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi"); - final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); + final Object queries = null; InputOutput.println("DSL loaded"); Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); LogicProblem problem = modelGenerationProblem.getOutput(); problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); - Viatra2LogicConfiguration _viatra2LogicConfiguration = new Viatra2LogicConfiguration(); - problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, _viatra2LogicConfiguration).getOutput(); workspace.writeModel(problem, "Fam.logicproblem"); InputOutput.println("Problem created"); long startTime = System.currentTimeMillis(); @@ -91,16 +86,12 @@ public class FAMTest { it.documentationLevel = DocumentationLevel.FULL; it.typeScopes.minNewElements = 8; it.typeScopes.maxNewElements = 10; - int _size = typeMapMin.size(); - boolean _notEquals = (_size != 0); - if (_notEquals) { - it.typeScopes.minNewElementsByType = typeMapMin; - } it.contCycleLevel = 5; it.uniquenessDuplicates = false; }; final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); + InputOutput.println("Problem solved"); List interpretations = reasoner.getInterpretations(((ModelResult) solution)); InputOutput.>print(interpretations.getClass()); for (final LogicModelInterpretation interpretation : interpretations) { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java index f8502439..616868a6 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/YakinduTest.java @@ -1,10 +1,152 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; +import ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns; +import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; +import ca.mcgill.ecse.dslreasoner.vampireLanguage.VampireModel; +import functionalarchitecture.FunctionalarchitecturePackage; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration; +import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic_Trace; +import hu.bme.mit.inf.dslreasoner.ecore2logic.EcoreMetamodelDescriptor; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel; +import hu.bme.mit.inf.dslreasoner.logic.model.builder.TracedOutput; +import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicProblem; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult; +import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult; +import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore; +import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic; +import hu.bme.mit.inf.dslreasoner.viatra2logic.ViatraQuerySetDescriptor; +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic; +import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; +import java.io.PrintWriter; +import java.util.Map; +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; +import org.eclipse.xtend2.lib.StringConcatenation; +import org.eclipse.xtext.xbase.lib.Exceptions; +import org.eclipse.xtext.xbase.lib.InputOutput; +import org.eclipse.xtext.xbase.lib.ObjectExtensions; +import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; + @SuppressWarnings("all") public class YakinduTest { public static void main(final String[] args) { - throw new Error("Unresolved compilation problems:" - + "\nThe method or field yakinduPackage is undefined" - + "\neINSTANCE cannot be resolved"); + try { + final Ecore2Logic ecore2Logic = new Ecore2Logic(); + final Logic2Ecore logic2Ecore = new Logic2Ecore(ecore2Logic); + final Viatra2Logic viatra2Logic = new Viatra2Logic(ecore2Logic); + final InstanceModel2Logic instanceModel2Logic = new InstanceModel2Logic(); + StringConcatenation _builder = new StringConcatenation(); + _builder.append("initialModels/"); + final FileSystemWorkspace inputs = new FileSystemWorkspace(_builder.toString(), ""); + StringConcatenation _builder_1 = new StringConcatenation(); + _builder_1.append("output/YakinduTest/"); + final FileSystemWorkspace workspace = new FileSystemWorkspace(_builder_1.toString(), ""); + workspace.initAndClear(); + final Resource.Factory.Registry reg = Resource.Factory.Registry.INSTANCE; + final Map map = reg.getExtensionToFactoryMap(); + XMIResourceFactoryImpl _xMIResourceFactoryImpl = new XMIResourceFactoryImpl(); + map.put("logicproblem", _xMIResourceFactoryImpl); + InputOutput.println("Input and output workspaces are created"); + final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); + final EList partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi"); + final ViatraQuerySetDescriptor queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance()); + InputOutput.println("DSL loaded"); + int MAX = 150; + int START = 10; + int INC = 20; + int REPS = 1; + final int EXACT = (-1); + if ((EXACT != (-1))) { + MAX = EXACT; + START = EXACT; + INC = 1; + REPS = 5; + } + URI _workspaceURI = workspace.getWorkspaceURI(); + String _plus = (_workspaceURI + "//yakinduStats.csv"); + PrintWriter writer = new PrintWriter(_plus); + writer.append("size,"); + for (int x = 0; (x < REPS); x++) { + writer.append((("t" + Integer.valueOf(x)) + ",")); + } + writer.append("avg\n"); + double totalTime = 0.0; + double totFound = 0.0; + boolean modelFound = true; + LogicResult solution = null; + { + int i = START; + boolean _while = (i <= MAX); + while (_while) { + { + final int num = ((i - START) / INC); + InputOutput.print((((("Generation " + Integer.valueOf(num)) + ": SIZE=") + Integer.valueOf(i)) + " Attempt: ")); + String _plus_1 = (Integer.valueOf(i) + ","); + writer.append(_plus_1); + totalTime = 0.0; + totFound = 0.0; + modelFound = true; + for (int j = 0; (j < REPS); j++) { + { + InputOutput.print(Integer.valueOf(j)); + Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); + final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); + LogicProblem problem = modelGenerationProblem.getOutput(); + problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); + workspace.writeModel(problem, "Yakindu.logicproblem"); + long startTime = System.currentTimeMillis(); + VampireSolver reasoner = null; + VampireSolver _vampireSolver = new VampireSolver(); + reasoner = _vampireSolver; + final int size = i; + final int inc = INC; + VampireSolverConfiguration _vampireSolverConfiguration = new VampireSolverConfiguration(); + final Procedure1 _function = (VampireSolverConfiguration it) -> { + it.documentationLevel = DocumentationLevel.FULL; + it.typeScopes.minNewElements = (size - inc); + it.typeScopes.maxNewElements = size; + it.contCycleLevel = 5; + it.uniquenessDuplicates = false; + }; + final VampireSolverConfiguration vampireConfig = ObjectExtensions.operator_doubleArrow(_vampireSolverConfiguration, _function); + solution = reasoner.solve(problem, vampireConfig, workspace); + Object _get = ((ModelResult) solution).getRepresentation().get(0); + final VampireModel soln = ((VampireModel) _get); + int _transformationTime = solution.getStatistics().getTransformationTime(); + final double time = (_transformationTime / 1000.0); + String _plus_2 = (Double.valueOf(time) + ","); + writer.append(_plus_2); + InputOutput.print((("(" + Double.valueOf(time)) + ")..")); + double _talTime = totalTime; + totalTime = (_talTime + time); + double _tFound = totFound; + totFound = (_tFound + 1); + } + } + InputOutput.println(); + double avg = 0.0; + if ((totFound == 0)) { + avg = (-1); + } else { + avg = (totalTime / totFound); + } + writer.append(Double.valueOf(avg).toString()); + writer.append("\n"); + } + int _i = i; + i = (_i + INC); + _while = (i <= MAX); + } + } + writer.close(); + } catch (Throwable _e) { + throw Exceptions.sneakyThrow(_e); + } } } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 4fb4dbc3..e9a1a8db 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 0eacff72..39d9c161 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 2c32163b..effd204e 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 4d27f2788d2f728d4ee2be8861df09da62bf135f Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Mon, 3 Feb 2020 15:20:02 -0500 Subject: VAMPIRE: last commit --- .../.ApplicationConfigurationIdeModule.xtendbin | Bin 1701 -> 1701 bytes .../ide/.ApplicationConfigurationIdeSetup.xtendbin | Bin 2526 -> 2526 bytes .../start-application-umontreal.launch | 37 + .../ModelGenExampleFAM_plugin/META-INF/MANIFEST.MF | 18 +- .../ecore-gen/functionalarchitecture/Function.java | 14 +- .../functionalarchitecture/FunctionalData.java | 33 +- .../functionalarchitecture/FunctionalElement.java | 8 +- .../FunctionalarchitecturePackage.java | 48 +- .../functionalarchitecture/impl/FunctionImpl.java | 15 + .../impl/FunctionalDataImpl.java | 86 +- .../impl/FunctionalElementImpl.java | 21 +- .../impl/FunctionalInterfaceImpl.java | 3 +- .../impl/FunctionalarchitectureFactoryImpl.java | 14 +- .../impl/FunctionalarchitecturePackageImpl.java | 52 +- .../util/FunctionalarchitectureAdapterFactory.java | 14 +- .../util/FunctionalarchitectureSwitch.java | 16 +- .../model/FamMetamodel.ecore | 1 + .../model/FamMetamodel.genmodel | 1 + .../Examples/ModelGenExampleFAM_plugin/plugin.xml | 11 +- .../model/yakindu_simplified.ecore | 5 - .../realistic/metrics/calculations/.CalcC.xtendbin | Bin 0 -> 5158 bytes .../metrics/calculations/.CalcEDA.xtendbin | Bin 0 -> 7314 bytes .../metrics/calculations/.CalcMPC.xtendbin | Bin 0 -> 9662 bytes .../metrics/calculations/.CalcMetric.xtendbin | Bin 0 -> 2555 bytes .../metrics/calculations/.CalcMetric2.xtendbin | Bin 0 -> 2774 bytes .../metrics/calculations/.CalcNA.xtendbin | Bin 0 -> 7937 bytes .../metrics/calculations/.CalcNDA.xtendbin | Bin 0 -> 7017 bytes .../metrics/calculations/.CalcNDC.xtendbin | Bin 0 -> 6481 bytes .../metrics/calculations/.CalcSQRCNT.xtendbin | Bin 0 -> 7453 bytes .../metrics/calculations/.CalcSQRNUM.xtendbin | Bin 0 -> 6922 bytes .../metrics/calculations/.CalcSQRTOT.xtendbin | Bin 0 -> 6549 bytes .../realistic/metrics/calculations/.gitignore | 20 + .../metrics/calculations/CalcSQRMAX.xtend_ | 87 + .../metrics/calculations/CalcSQROSZ2.xtend_ | 69 + .../metrics/examples/.FixModelURIs.xtendbin | Bin 0 -> 4429 bytes .../.MetricsCalculationUsingShapes.xtendbin | Bin 0 -> 10168 bytes .../realistic/metrics/examples/.Util.xtendbin | Bin 0 -> 12474 bytes .../metrics/calculations/.CalcC.java._trace | Bin 0 -> 5637 bytes .../metrics/calculations/.CalcEDA.java._trace | Bin 0 -> 13288 bytes .../metrics/calculations/.CalcMPC.java._trace | Bin 0 -> 24403 bytes .../metrics/calculations/.CalcMetric.java._trace | Bin 0 -> 522 bytes .../metrics/calculations/.CalcMetric2.java._trace | Bin 0 -> 608 bytes .../metrics/calculations/.CalcNA.java._trace | Bin 0 -> 13672 bytes .../metrics/calculations/.CalcNDA.java._trace | Bin 0 -> 10147 bytes .../metrics/calculations/.CalcNDC.java._trace | Bin 0 -> 7235 bytes .../metrics/calculations/.CalcSQRCNT.java._trace | Bin 0 -> 7671 bytes .../metrics/calculations/.CalcSQRNUM.java._trace | Bin 0 -> 15830 bytes .../metrics/calculations/.CalcSQRTOT.java._trace | Bin 0 -> 13017 bytes .../metrics/examples/.FixModelURIs.java._trace | Bin 0 -> 3743 bytes .../.MetricsCalculationUsingShapes.java._trace | Bin 0 -> 19842 bytes .../realistic/metrics/examples/.Util.java._trace | Bin 0 -> 32376 bytes .../META-INF/MANIFEST.MF | 2 +- .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 3759 -> 3759 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../.VampireAnalyzerConfiguration.xtendbin | Bin 3449 -> 3449 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 10104 -> 10104 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 19565 -> 19565 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 5080 -> 5080 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 11807 -> 11807 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 7880 -> 7880 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 10684 -> 10684 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 17151 -> 17151 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 11037 -> 11037 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 3998 -> 3998 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 7743 -> 7743 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../configs/fam.vsconfig | 6 +- .../outputs/fam/debug/errors.txt | 107 +- .../fam/debug/generated3valued.vql_deactivated | 17611 +++++++++++++++++++ .../outputs/fam/debug/generation.logicproblem | 69 +- .../outputs/fam/debug/init.partialmodel | 7 +- .../outputs/fam/log.txt | 2 +- .../outputs/fam/models/1.gml | 3429 ++++ .../outputs/fam/models/1.png | Bin 73113 -> 85126 bytes .../outputs/fam/models/1.xmi | 22 +- .../outputs/fam/models/2.gml | 2506 +++ .../outputs/fam/models/2.png | Bin 75459 -> 83599 bytes .../outputs/fam/models/2.xmi | 21 +- .../outputs/fam/models/3.gml | 2469 +++ .../outputs/fam/models/3.png | Bin 75681 -> 65027 bytes .../outputs/fam/models/3.xmi | 21 +- .../outputs/fam/models/4.gml | 2505 +++ .../outputs/fam/models/4.png | Bin 88715 -> 65007 bytes .../outputs/fam/models/4.xmi | 21 +- .../outputs/fam/models/5.gml | 2505 +++ .../outputs/fam/models/5.png | Bin 88028 -> 64375 bytes .../outputs/fam/models/5.xmi | 22 +- .../outputs/fam/statistics.csv | 6 + .../output/FAMTest/Fam.logicproblem | 62 +- .../ecse/dslreasoner/vampire/icse/FAMTest.xtend | 45 +- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4545 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6626 -> 6381 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 6201 -> 6201 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6625 -> 6625 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 9352 -> 9352 bytes .../ecse/dslreasoner/vampire/icse/FAMTest.java | 14 +- .../vampire/test/.MedicalSystem.xtendbin | Bin 5003 -> 5003 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6581 -> 6581 bytes .../dslreasoner/yakindu/test/.YakinduTest.xtendbin | Bin 8569 -> 8569 bytes 114 files changed, 31767 insertions(+), 258 deletions(-) create mode 100644 Application/hu.bme.mit.inf.dslreasoner.application/start-application-umontreal.launch create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.gitignore create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQRMAX.xtend_ create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQROSZ2.xtend_ create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.xtendbin create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace create mode 100644 Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin index 3f997d1e..f37b0e9a 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeModule.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin index fd411426..209a7b80 100644 Binary files a/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin and b/Application/hu.bme.mit.inf.dslreasoner.application.ide/xtend-gen/hu/bme/mit/inf/dslreasoner/application/ide/.ApplicationConfigurationIdeSetup.xtendbin differ diff --git a/Application/hu.bme.mit.inf.dslreasoner.application/start-application-umontreal.launch b/Application/hu.bme.mit.inf.dslreasoner.application/start-application-umontreal.launch new file mode 100644 index 00000000..abff69ee --- /dev/null +++ b/Application/hu.bme.mit.inf.dslreasoner.application/start-application-umontreal.launch @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/META-INF/MANIFEST.MF b/Domains/Examples/ModelGenExampleFAM_plugin/META-INF/MANIFEST.MF index f1f5d18c..077e646b 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/META-INF/MANIFEST.MF +++ b/Domains/Examples/ModelGenExampleFAM_plugin/META-INF/MANIFEST.MF @@ -7,16 +7,16 @@ Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: functionalarchitecture, - functionalarchitecture.impl, - functionalarchitecture.util, - hu.bme.mit.inf.dslreasoner.domains.transima.fam + functionalarchitecture.impl, + functionalarchitecture.util, + hu.bme.mit.inf.dslreasoner.domains.transima.fam Require-Bundle: ModelGenExampleFAM_plugin, - org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.viatra.query.runtime, - org.apache.log4j;bundle-version="1.2.15", - com.google.guava;bundle-version="15.0.0", - org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport + org.eclipse.viatra.addon.querybasedfeatures.runtime, + org.eclipse.viatra.query.runtime, + org.apache.log4j;bundle-version="1.2.15", + com.google.guava;bundle-version="15.0.0", + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy Automatic-Module-Name: ModelGenExampleFAM_plugin diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/Function.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/Function.java index 5b484066..0a4e6361 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/Function.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/Function.java @@ -51,11 +51,23 @@ public interface Function extends FunctionalElement { * * @return the value of the 'Type' attribute. * @see functionalarchitecture.FunctionType + * @see #setType(FunctionType) * @see functionalarchitecture.FunctionalarchitecturePackage#getFunction_Type() - * @model required="true" transient="true" changeable="false" volatile="true" derived="true" + * @model required="true" transient="true" volatile="true" * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='hu.bme.mit.inf.dslreasoner.domains.transima.fam.type'" * @generated */ FunctionType getType(); + /** + * Sets the value of the '{@link functionalarchitecture.Function#getType Type}' attribute. + * + * + * @param value the new value of the 'Type' attribute. + * @see functionalarchitecture.FunctionType + * @see #getType() + * @generated + */ + void setType(FunctionType value); + } // Function diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalData.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalData.java index 39639f99..23b7b9a0 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalData.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalData.java @@ -15,6 +15,7 @@ import org.eclipse.emf.ecore.EObject; *
      *
    • {@link functionalarchitecture.FunctionalData#getTerminator Terminator}
    • *
    • {@link functionalarchitecture.FunctionalData#getInterface Interface}
    • + *
    • {@link functionalarchitecture.FunctionalData#getValue Value}
    • *
    * * @see functionalarchitecture.FunctionalarchitecturePackage#getFunctionalData() @@ -60,13 +61,13 @@ public interface FunctionalData extends EObject { *

    * * @return the value of the 'Interface' container reference. - * @see #setInterface(FunctionalInterface) + * @see #setInterface(functionalarchitecture.FunctionalInterface) * @see functionalarchitecture.FunctionalarchitecturePackage#getFunctionalData_Interface() * @see functionalarchitecture.FunctionalInterface#getData * @model opposite="data" transient="false" * @generated */ - FunctionalInterface getInterface(); + functionalarchitecture.FunctionalInterface getInterface(); /** * Sets the value of the '{@link functionalarchitecture.FunctionalData#getInterface Interface}' container reference. @@ -76,6 +77,32 @@ public interface FunctionalData extends EObject { * @see #getInterface() * @generated */ - void setInterface(FunctionalInterface value); + void setInterface(functionalarchitecture.FunctionalInterface value); + + /** + * Returns the value of the 'Value' attribute. + * + *

    + * If the meaning of the 'Value' attribute isn't clear, + * there really should be more of a description here... + *

    + * + * @return the value of the 'Value' attribute. + * @see #setValue(int) + * @see functionalarchitecture.FunctionalarchitecturePackage#getFunctionalData_Value() + * @model required="true" + * @generated + */ + int getValue(); + + /** + * Sets the value of the '{@link functionalarchitecture.FunctionalData#getValue Value}' attribute. + * + * + * @param value the new value of the 'Value' attribute. + * @see #getValue() + * @generated + */ + void setValue(int value); } // FunctionalData diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalElement.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalElement.java index f5a2ff19..1fb9b9b8 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalElement.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalElement.java @@ -33,13 +33,13 @@ public interface FunctionalElement extends EObject { *

    * * @return the value of the 'Interface' containment reference. - * @see #setInterface(FunctionalInterface) + * @see #setInterface(functionalarchitecture.FunctionalInterface) * @see functionalarchitecture.FunctionalarchitecturePackage#getFunctionalElement_Interface() * @see functionalarchitecture.FunctionalInterface#getElement * @model opposite="element" containment="true" * @generated */ - FunctionalInterface getInterface(); + functionalarchitecture.FunctionalInterface getInterface(); /** * Sets the value of the '{@link functionalarchitecture.FunctionalElement#getInterface Interface}' containment reference. @@ -49,7 +49,7 @@ public interface FunctionalElement extends EObject { * @see #getInterface() * @generated */ - void setInterface(FunctionalInterface value); + void setInterface(functionalarchitecture.FunctionalInterface value); /** * Returns the value of the 'Model' reference. @@ -62,7 +62,7 @@ public interface FunctionalElement extends EObject { * @return the value of the 'Model' reference. * @see #setModel(FunctionalArchitectureModel) * @see functionalarchitecture.FunctionalarchitecturePackage#getFunctionalElement_Model() - * @model required="true" transient="true" volatile="true" derived="true" + * @model required="true" transient="true" volatile="true" * annotation="org.eclipse.viatra.query.querybasedfeature patternFQN='hu.bme.mit.inf.dslreasoner.domains.transima.fam.model'" * @generated */ diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalarchitecturePackage.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalarchitecturePackage.java index ac0d910e..dee2cc59 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalarchitecturePackage.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/FunctionalarchitecturePackage.java @@ -380,6 +380,15 @@ public interface FunctionalarchitecturePackage extends EPackage { */ int FUNCTIONAL_DATA__INTERFACE = 1; + /** + * The feature id for the 'Value' attribute. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_DATA__VALUE = 2; + /** * The number of structural features of the 'Functional Data' class. * @@ -387,7 +396,7 @@ public interface FunctionalarchitecturePackage extends EPackage { * @generated * @ordered */ - int FUNCTIONAL_DATA_FEATURE_COUNT = 2; + int FUNCTIONAL_DATA_FEATURE_COUNT = 3; /** * The number of operations of the 'Functional Data' class. @@ -426,6 +435,15 @@ public interface FunctionalarchitecturePackage extends EPackage { */ int FUNCTIONAL_INPUT__INTERFACE = FUNCTIONAL_DATA__INTERFACE; + /** + * The feature id for the 'Value' attribute. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_INPUT__VALUE = FUNCTIONAL_DATA__VALUE; + /** * The feature id for the 'Incoming Links' reference list. * @@ -481,6 +499,15 @@ public interface FunctionalarchitecturePackage extends EPackage { */ int FUNCTIONAL_OUTPUT__INTERFACE = FUNCTIONAL_DATA__INTERFACE; + /** + * The feature id for the 'Value' attribute. + * + * + * @generated + * @ordered + */ + int FUNCTIONAL_OUTPUT__VALUE = FUNCTIONAL_DATA__VALUE; + /** * The feature id for the 'Outgoing Links' containment reference list. * @@ -774,6 +801,17 @@ public interface FunctionalarchitecturePackage extends EPackage { */ EReference getFunctionalData_Interface(); + /** + * Returns the meta object for the attribute '{@link functionalarchitecture.FunctionalData#getValue Value}'. + * + * + * @return the meta object for the attribute 'Value'. + * @see functionalarchitecture.FunctionalData#getValue() + * @see #getFunctionalData() + * @generated + */ + EAttribute getFunctionalData_Value(); + /** * Returns the meta object for enum '{@link functionalarchitecture.FunctionType Function Type}'. * @@ -1017,6 +1055,14 @@ public interface FunctionalarchitecturePackage extends EPackage { */ EReference FUNCTIONAL_DATA__INTERFACE = eINSTANCE.getFunctionalData_Interface(); + /** + * The meta object literal for the 'Value' attribute feature. + * + * + * @generated + */ + EAttribute FUNCTIONAL_DATA__VALUE = eINSTANCE.getFunctionalData_Value(); + /** * The meta object literal for the '{@link functionalarchitecture.FunctionType Function Type}' enum. * diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionImpl.java index 46736c8c..2262094e 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionImpl.java @@ -95,6 +95,15 @@ public class FunctionImpl extends FunctionalElementImpl implements Function { return (FunctionType)TYPE__ESETTING_DELEGATE.dynamicGet(this, null, 0, true, false); } + /** + * + * + * @generated + */ + public void setType(FunctionType newType) { + TYPE__ESETTING_DELEGATE.dynamicSet(this, null, 0, newType); + } + /** * * @@ -153,6 +162,9 @@ public class FunctionImpl extends FunctionalElementImpl implements Function { getSubElements().clear(); getSubElements().addAll((Collection)newValue); return; + case FunctionalarchitecturePackage.FUNCTION__TYPE: + setType((FunctionType)newValue); + return; } super.eSet(featureID, newValue); } @@ -168,6 +180,9 @@ public class FunctionImpl extends FunctionalElementImpl implements Function { case FunctionalarchitecturePackage.FUNCTION__SUB_ELEMENTS: getSubElements().clear(); return; + case FunctionalarchitecturePackage.FUNCTION__TYPE: + TYPE__ESETTING_DELEGATE.dynamicUnset(this, null, 0); + return; } super.eUnset(featureID); } diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalDataImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalDataImpl.java index 10937e8d..ecab54af 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalDataImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalDataImpl.java @@ -4,7 +4,6 @@ package functionalarchitecture.impl; import functionalarchitecture.FAMTerminator; import functionalarchitecture.FunctionalData; -import functionalarchitecture.FunctionalInterface; import functionalarchitecture.FunctionalarchitecturePackage; import org.eclipse.emf.common.notify.Notification; @@ -28,6 +27,7 @@ import org.eclipse.emf.ecore.util.EcoreUtil; *
      *
    • {@link functionalarchitecture.impl.FunctionalDataImpl#getTerminator Terminator}
    • *
    • {@link functionalarchitecture.impl.FunctionalDataImpl#getInterface Interface}
    • + *
    • {@link functionalarchitecture.impl.FunctionalDataImpl#getValue Value}
    • *
    * * @generated @@ -43,6 +43,25 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im */ protected FAMTerminator terminator; + /** + * The default value of the '{@link #getValue() Value}' attribute. + * + * + * @see #getValue() + * @generated + * @ordered + */ + protected static final int VALUE_EDEFAULT = 0; + /** + * The cached value of the '{@link #getValue() Value}' attribute. + * + * + * @see #getValue() + * @generated + * @ordered + */ + protected int value = VALUE_EDEFAULT; + /** * * @@ -110,9 +129,9 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im * * @generated */ - public FunctionalInterface getInterface() { + public functionalarchitecture.FunctionalInterface getInterface() { if (eContainerFeatureID() != FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE) return null; - return (FunctionalInterface)eInternalContainer(); + return (functionalarchitecture.FunctionalInterface)eInternalContainer(); } /** @@ -120,7 +139,7 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im * * @generated */ - public NotificationChain basicSetInterface(FunctionalInterface newInterface, NotificationChain msgs) { + public NotificationChain basicSetInterface(functionalarchitecture.FunctionalInterface newInterface, NotificationChain msgs) { msgs = eBasicSetContainer((InternalEObject)newInterface, FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE, msgs); return msgs; } @@ -130,7 +149,7 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im * * @generated */ - public void setInterface(FunctionalInterface newInterface) { + public void setInterface(functionalarchitecture.FunctionalInterface newInterface) { if (newInterface != eInternalContainer() || (eContainerFeatureID() != FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE && newInterface != null)) { if (EcoreUtil.isAncestor(this, newInterface)) throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); @@ -138,7 +157,7 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im if (eInternalContainer() != null) msgs = eBasicRemoveFromContainer(msgs); if (newInterface != null) - msgs = ((InternalEObject)newInterface).eInverseAdd(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA, FunctionalInterface.class, msgs); + msgs = ((InternalEObject)newInterface).eInverseAdd(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA, functionalarchitecture.FunctionalInterface.class, msgs); msgs = basicSetInterface(newInterface, msgs); if (msgs != null) msgs.dispatch(); } @@ -146,6 +165,27 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im eNotify(new ENotificationImpl(this, Notification.SET, FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE, newInterface, newInterface)); } + /** + * + * + * @generated + */ + public int getValue() { + return value; + } + + /** + * + * + * @generated + */ + public void setValue(int newValue) { + int oldValue = value; + value = newValue; + if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, FunctionalarchitecturePackage.FUNCTIONAL_DATA__VALUE, oldValue, value)); + } + /** * * @@ -161,7 +201,7 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: if (eInternalContainer() != null) msgs = eBasicRemoveFromContainer(msgs); - return basicSetInterface((FunctionalInterface)otherEnd, msgs); + return basicSetInterface((functionalarchitecture.FunctionalInterface)otherEnd, msgs); } return super.eInverseAdd(otherEnd, featureID, msgs); } @@ -191,7 +231,7 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { switch (eContainerFeatureID()) { case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: - return eInternalContainer().eInverseRemove(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA, FunctionalInterface.class, msgs); + return eInternalContainer().eInverseRemove(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA, functionalarchitecture.FunctionalInterface.class, msgs); } return super.eBasicRemoveFromContainerFeature(msgs); } @@ -208,6 +248,8 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im return getTerminator(); case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: return getInterface(); + case FunctionalarchitecturePackage.FUNCTIONAL_DATA__VALUE: + return getValue(); } return super.eGet(featureID, resolve, coreType); } @@ -224,7 +266,10 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im setTerminator((FAMTerminator)newValue); return; case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: - setInterface((FunctionalInterface)newValue); + setInterface((functionalarchitecture.FunctionalInterface)newValue); + return; + case FunctionalarchitecturePackage.FUNCTIONAL_DATA__VALUE: + setValue((Integer)newValue); return; } super.eSet(featureID, newValue); @@ -242,7 +287,10 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im setTerminator((FAMTerminator)null); return; case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: - setInterface((FunctionalInterface)null); + setInterface((functionalarchitecture.FunctionalInterface)null); + return; + case FunctionalarchitecturePackage.FUNCTIONAL_DATA__VALUE: + setValue(VALUE_EDEFAULT); return; } super.eUnset(featureID); @@ -260,8 +308,26 @@ public abstract class FunctionalDataImpl extends MinimalEObjectImpl.Container im return terminator != null; case FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE: return getInterface() != null; + case FunctionalarchitecturePackage.FUNCTIONAL_DATA__VALUE: + return value != VALUE_EDEFAULT; } return super.eIsSet(featureID); } + /** + * + * + * @generated + */ + @Override + public String toString() { + if (eIsProxy()) return super.toString(); + + StringBuilder result = new StringBuilder(super.toString()); + result.append(" (value: "); + result.append(value); + result.append(')'); + return result.toString(); + } + } //FunctionalDataImpl diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalElementImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalElementImpl.java index 809e9ed5..090ccd32 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalElementImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalElementImpl.java @@ -5,7 +5,6 @@ package functionalarchitecture.impl; import functionalarchitecture.Function; import functionalarchitecture.FunctionalArchitectureModel; import functionalarchitecture.FunctionalElement; -import functionalarchitecture.FunctionalInterface; import functionalarchitecture.FunctionalarchitecturePackage; import org.eclipse.emf.common.notify.Notification; @@ -44,7 +43,7 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container * @generated * @ordered */ - protected FunctionalInterface interface_; + protected functionalarchitecture.FunctionalInterface interface_; /** * The cached setting delegate for the '{@link #getModel() Model}' reference. @@ -80,7 +79,7 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container * * @generated */ - public FunctionalInterface getInterface() { + public functionalarchitecture.FunctionalInterface getInterface() { return interface_; } @@ -89,8 +88,8 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container * * @generated */ - public NotificationChain basicSetInterface(FunctionalInterface newInterface, NotificationChain msgs) { - FunctionalInterface oldInterface = interface_; + public NotificationChain basicSetInterface(functionalarchitecture.FunctionalInterface newInterface, NotificationChain msgs) { + functionalarchitecture.FunctionalInterface oldInterface = interface_; interface_ = newInterface; if (eNotificationRequired()) { ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE, oldInterface, newInterface); @@ -104,13 +103,13 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container * * @generated */ - public void setInterface(FunctionalInterface newInterface) { + public void setInterface(functionalarchitecture.FunctionalInterface newInterface) { if (newInterface != interface_) { NotificationChain msgs = null; if (interface_ != null) - msgs = ((InternalEObject)interface_).eInverseRemove(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, FunctionalInterface.class, msgs); + msgs = ((InternalEObject)interface_).eInverseRemove(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, functionalarchitecture.FunctionalInterface.class, msgs); if (newInterface != null) - msgs = ((InternalEObject)newInterface).eInverseAdd(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, FunctionalInterface.class, msgs); + msgs = ((InternalEObject)newInterface).eInverseAdd(this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, functionalarchitecture.FunctionalInterface.class, msgs); msgs = basicSetInterface(newInterface, msgs); if (msgs != null) msgs.dispatch(); } @@ -197,7 +196,7 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE: if (interface_ != null) msgs = ((InternalEObject)interface_).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE, null, msgs); - return basicSetInterface((FunctionalInterface)otherEnd, msgs); + return basicSetInterface((functionalarchitecture.FunctionalInterface)otherEnd, msgs); case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__PARENT: if (eInternalContainer() != null) msgs = eBasicRemoveFromContainer(msgs); @@ -264,7 +263,7 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container public void eSet(int featureID, Object newValue) { switch (featureID) { case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE: - setInterface((FunctionalInterface)newValue); + setInterface((functionalarchitecture.FunctionalInterface)newValue); return; case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__MODEL: setModel((FunctionalArchitectureModel)newValue); @@ -285,7 +284,7 @@ public abstract class FunctionalElementImpl extends MinimalEObjectImpl.Container public void eUnset(int featureID) { switch (featureID) { case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE: - setInterface((FunctionalInterface)null); + setInterface((functionalarchitecture.FunctionalInterface)null); return; case FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__MODEL: setModel((FunctionalArchitectureModel)null); diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java index 20151886..be8f8700 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java @@ -4,7 +4,6 @@ package functionalarchitecture.impl; import functionalarchitecture.FunctionalData; import functionalarchitecture.FunctionalElement; -import functionalarchitecture.FunctionalInterface; import functionalarchitecture.FunctionalarchitecturePackage; import java.util.Collection; @@ -38,7 +37,7 @@ import org.eclipse.emf.ecore.util.InternalEList; * * @generated */ -public class FunctionalInterfaceImpl extends MinimalEObjectImpl.Container implements FunctionalInterface { +public class FunctionalInterfaceImpl extends MinimalEObjectImpl.Container implements functionalarchitecture.FunctionalInterface { /** * The cached value of the '{@link #getData() Data}' containment reference list. * diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitectureFactoryImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitectureFactoryImpl.java index 56ecfa25..726f7a32 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitectureFactoryImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitectureFactoryImpl.java @@ -2,9 +2,15 @@ */ package functionalarchitecture.impl; -import functionalarchitecture.*; -import functionalarchitecture.FunctionalInterface; - +import functionalarchitecture.FAMTerminator; +import functionalarchitecture.Function; +import functionalarchitecture.FunctionType; +import functionalarchitecture.FunctionalArchitectureModel; +import functionalarchitecture.FunctionalInput; +import functionalarchitecture.FunctionalOutput; +import functionalarchitecture.FunctionalarchitectureFactory; +import functionalarchitecture.FunctionalarchitecturePackage; +import functionalarchitecture.InformationLink; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.EDataType; import org.eclipse.emf.ecore.EObject; @@ -145,7 +151,7 @@ public class FunctionalarchitectureFactoryImpl extends EFactoryImpl implements F * * @generated */ - public FunctionalInterface createFunctionalInterface() { + public functionalarchitecture.FunctionalInterface createFunctionalInterface() { FunctionalInterfaceImpl functionalInterface = new FunctionalInterfaceImpl(); return functionalInterface; } diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitecturePackageImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitecturePackageImpl.java index 22c15533..110f3d6c 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitecturePackageImpl.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalarchitecturePackageImpl.java @@ -9,7 +9,6 @@ import functionalarchitecture.FunctionalArchitectureModel; import functionalarchitecture.FunctionalData; import functionalarchitecture.FunctionalElement; import functionalarchitecture.FunctionalInput; -import functionalarchitecture.FunctionalInterface; import functionalarchitecture.FunctionalOutput; import functionalarchitecture.FunctionalarchitectureFactory; import functionalarchitecture.FunctionalarchitecturePackage; @@ -128,7 +127,7 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F /** * Creates, registers, and initializes the Package for this model, and for any others upon which it depends. - * + * *

    This method is used to initialize {@link FunctionalarchitecturePackage#eINSTANCE} when that field is accessed. * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. * @@ -142,7 +141,8 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F if (isInited) return (FunctionalarchitecturePackage)EPackage.Registry.INSTANCE.getEPackage(FunctionalarchitecturePackage.eNS_URI); // Obtain or create and register package - FunctionalarchitecturePackageImpl theFunctionalarchitecturePackage = (FunctionalarchitecturePackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FunctionalarchitecturePackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FunctionalarchitecturePackageImpl()); + Object registeredFunctionalarchitecturePackage = EPackage.Registry.INSTANCE.get(eNS_URI); + FunctionalarchitecturePackageImpl theFunctionalarchitecturePackage = registeredFunctionalarchitecturePackage instanceof FunctionalarchitecturePackageImpl ? (FunctionalarchitecturePackageImpl)registeredFunctionalarchitecturePackage : new FunctionalarchitecturePackageImpl(); isInited = true; @@ -155,7 +155,6 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F // Mark meta-data to indicate it can't be changed theFunctionalarchitecturePackage.freeze(); - // Update the registry and return the package EPackage.Registry.INSTANCE.put(FunctionalarchitecturePackage.eNS_URI, theFunctionalarchitecturePackage); return theFunctionalarchitecturePackage; @@ -377,6 +376,15 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F return (EReference)functionalDataEClass.getEStructuralFeatures().get(1); } + /** + * + * + * @generated + */ + public EAttribute getFunctionalData_Value() { + return (EAttribute)functionalDataEClass.getEStructuralFeatures().get(2); + } + /** * * @@ -446,6 +454,7 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F functionalDataEClass = createEClass(FUNCTIONAL_DATA); createEReference(functionalDataEClass, FUNCTIONAL_DATA__TERMINATOR); createEReference(functionalDataEClass, FUNCTIONAL_DATA__INTERFACE); + createEAttribute(functionalDataEClass, FUNCTIONAL_DATA__VALUE); // Create enums functionTypeEEnum = createEEnum(FUNCTION_TYPE); @@ -486,7 +495,7 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F // Initialize classes, features, and operations; add parameters initEClass(functionalElementEClass, FunctionalElement.class, "FunctionalElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getFunctionalElement_Interface(), this.getFunctionalInterface(), this.getFunctionalInterface_Element(), "interface", null, 0, 1, FunctionalElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getFunctionalElement_Model(), this.getFunctionalArchitectureModel(), null, "model", null, 1, 1, FunctionalElement.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalElement_Model(), this.getFunctionalArchitectureModel(), null, "model", null, 1, 1, FunctionalElement.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getFunctionalElement_Parent(), this.getFunction(), this.getFunction_SubElements(), "parent", null, 0, 1, FunctionalElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(functionalArchitectureModelEClass, FunctionalArchitectureModel.class, "FunctionalArchitectureModel", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); @@ -494,7 +503,7 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F initEClass(functionEClass, Function.class, "Function", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getFunction_SubElements(), this.getFunctionalElement(), this.getFunctionalElement_Parent(), "subElements", null, 0, -1, Function.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEAttribute(getFunction_Type(), this.getFunctionType(), "type", null, 1, 1, Function.class, IS_TRANSIENT, IS_VOLATILE, !IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, IS_DERIVED, IS_ORDERED); + initEAttribute(getFunction_Type(), this.getFunctionType(), "type", null, 1, 1, Function.class, IS_TRANSIENT, IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(famTerminatorEClass, FAMTerminator.class, "FAMTerminator", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getFAMTerminator_Data(), this.getFunctionalData(), this.getFunctionalData_Terminator(), "data", null, 0, 1, FAMTerminator.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -503,9 +512,9 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F initEReference(getInformationLink_From(), this.getFunctionalOutput(), this.getFunctionalOutput_OutgoingLinks(), "from", null, 0, 1, InformationLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getInformationLink_To(), this.getFunctionalInput(), this.getFunctionalInput_IncomingLinks(), "to", null, 1, 1, InformationLink.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEClass(functionalInterfaceEClass, FunctionalInterface.class, "FunctionalInterface", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); - initEReference(getFunctionalInterface_Data(), this.getFunctionalData(), this.getFunctionalData_Interface(), "data", null, 0, -1, FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); - initEReference(getFunctionalInterface_Element(), this.getFunctionalElement(), this.getFunctionalElement_Interface(), "element", null, 0, 1, FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEClass(functionalInterfaceEClass, functionalarchitecture.FunctionalInterface.class, "FunctionalInterface", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); + initEReference(getFunctionalInterface_Data(), this.getFunctionalData(), this.getFunctionalData_Interface(), "data", null, 0, -1, functionalarchitecture.FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEReference(getFunctionalInterface_Element(), this.getFunctionalElement(), this.getFunctionalElement_Interface(), "element", null, 0, 1, functionalarchitecture.FunctionalInterface.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEClass(functionalInputEClass, FunctionalInput.class, "FunctionalInput", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getFunctionalInput_IncomingLinks(), this.getInformationLink(), this.getInformationLink_To(), "IncomingLinks", null, 0, -1, FunctionalInput.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); @@ -516,6 +525,7 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F initEClass(functionalDataEClass, FunctionalData.class, "FunctionalData", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); initEReference(getFunctionalData_Terminator(), this.getFAMTerminator(), this.getFAMTerminator_Data(), "terminator", null, 0, 1, FunctionalData.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); initEReference(getFunctionalData_Interface(), this.getFunctionalInterface(), this.getFunctionalInterface_Data(), "interface", null, 0, 1, FunctionalData.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); + initEAttribute(getFunctionalData_Value(), ecorePackage.getEInt(), "value", null, 1, 1, FunctionalData.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); // Initialize enums and add enum literals initEEnum(functionTypeEEnum, FunctionType.class, "FunctionType"); @@ -540,12 +550,12 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F * @generated */ protected void createEcoreAnnotations() { - String source = "http://www.eclipse.org/emf/2002/Ecore"; + String source = "http://www.eclipse.org/emf/2002/Ecore"; addAnnotation - (this, - source, + (this, + source, new String[] { - "settingDelegates", "org.eclipse.viatra.query.querybasedfeature" + "settingDelegates", "org.eclipse.viatra.query.querybasedfeature" }); } @@ -556,18 +566,18 @@ public class FunctionalarchitecturePackageImpl extends EPackageImpl implements F * @generated */ protected void createOrgAnnotations() { - String source = "org.eclipse.viatra.query.querybasedfeature"; + String source = "org.eclipse.viatra.query.querybasedfeature"; addAnnotation - (getFunctionalElement_Model(), - source, + (getFunctionalElement_Model(), + source, new String[] { - "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.transima.fam.model" - }); + "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.transima.fam.model" + }); addAnnotation - (getFunction_Type(), - source, + (getFunction_Type(), + source, new String[] { - "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.transima.fam.type" + "patternFQN", "hu.bme.mit.inf.dslreasoner.domains.transima.fam.type" }); } diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureAdapterFactory.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureAdapterFactory.java index f990a7a4..9846bd62 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureAdapterFactory.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureAdapterFactory.java @@ -2,9 +2,15 @@ */ package functionalarchitecture.util; -import functionalarchitecture.*; -import functionalarchitecture.FunctionalInterface; - +import functionalarchitecture.FAMTerminator; +import functionalarchitecture.Function; +import functionalarchitecture.FunctionalArchitectureModel; +import functionalarchitecture.FunctionalData; +import functionalarchitecture.FunctionalElement; +import functionalarchitecture.FunctionalInput; +import functionalarchitecture.FunctionalOutput; +import functionalarchitecture.FunctionalarchitecturePackage; +import functionalarchitecture.InformationLink; import org.eclipse.emf.common.notify.Adapter; import org.eclipse.emf.common.notify.Notifier; @@ -89,7 +95,7 @@ public class FunctionalarchitectureAdapterFactory extends AdapterFactoryImpl { return createInformationLinkAdapter(); } @Override - public Adapter caseFunctionalInterface(FunctionalInterface object) { + public Adapter caseFunctionalInterface(functionalarchitecture.FunctionalInterface object) { return createFunctionalInterfaceAdapter(); } @Override diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureSwitch.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureSwitch.java index b481a978..a1bbb480 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureSwitch.java +++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/util/FunctionalarchitectureSwitch.java @@ -2,9 +2,15 @@ */ package functionalarchitecture.util; -import functionalarchitecture.*; -import functionalarchitecture.FunctionalInterface; - +import functionalarchitecture.FAMTerminator; +import functionalarchitecture.Function; +import functionalarchitecture.FunctionalArchitectureModel; +import functionalarchitecture.FunctionalData; +import functionalarchitecture.FunctionalElement; +import functionalarchitecture.FunctionalInput; +import functionalarchitecture.FunctionalOutput; +import functionalarchitecture.FunctionalarchitecturePackage; +import functionalarchitecture.InformationLink; import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.EPackage; @@ -99,7 +105,7 @@ public class FunctionalarchitectureSwitch extends Switch { return result; } case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE: { - FunctionalInterface functionalInterface = (FunctionalInterface)theEObject; + functionalarchitecture.FunctionalInterface functionalInterface = (functionalarchitecture.FunctionalInterface)theEObject; T result = caseFunctionalInterface(functionalInterface); if (result == null) result = defaultCase(theEObject); return result; @@ -214,7 +220,7 @@ public class FunctionalarchitectureSwitch extends Switch { * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) * @generated */ - public T caseFunctionalInterface(FunctionalInterface object) { + public T caseFunctionalInterface(functionalarchitecture.FunctionalInterface object) { return null; } diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore index 3fab9a1d..720a9373 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore +++ b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.ecore @@ -60,6 +60,7 @@ containment="true" eOpposite="#//FAMTerminator/data"/> + diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.genmodel b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.genmodel index 9d89c145..bd428811 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.genmodel +++ b/Domains/Examples/ModelGenExampleFAM_plugin/model/FamMetamodel.genmodel @@ -43,6 +43,7 @@ + diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml index 07fd662c..3874e9f7 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml +++ b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml @@ -1,8 +1,11 @@ - - - - + + + + diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore index 5999c4c7..51b0ca5b 100644 --- a/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore +++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph/model/yakindu_simplified.ecore @@ -37,9 +37,4 @@ - - - - - diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.xtendbin new file mode 100644 index 00000000..0c2cbb6e Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.xtendbin new file mode 100644 index 00000000..056bbf88 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.xtendbin new file mode 100644 index 00000000..40092f54 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.xtendbin new file mode 100644 index 00000000..ae757bb6 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.xtendbin new file mode 100644 index 00000000..ed2b817f Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.xtendbin new file mode 100644 index 00000000..6d0da896 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.xtendbin new file mode 100644 index 00000000..a50e372c Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.xtendbin new file mode 100644 index 00000000..8d56931d Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.xtendbin new file mode 100644 index 00000000..0641ed7b Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.xtendbin new file mode 100644 index 00000000..99dd130b Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.xtendbin new file mode 100644 index 00000000..d397ff4c Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.gitignore b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.gitignore new file mode 100644 index 00000000..f2c394d6 --- /dev/null +++ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.gitignore @@ -0,0 +1,20 @@ +/.CalculationsNA.java._trace +/.CalcNA.java._trace +/.CalcMPC.java._trace +/.CalcMetric.java._trace +/.CalcNDA.java._trace +/.CalcNDC.java._trace +/.CalcEDA.java._trace +/.CalcC.java._trace +/.CalcSQR.java._trace +/.CalcSQRtot.java._trace +/.CalcSQRMAX.java._trace +/.CalcSQRTOT.java._trace +/.CalcSQROSZ.java._trace +/.CalcSQROSZ2.java._trace +/.CalcSQROCOOL.java._trace +/.CalcSQRCNT.java._trace +/.CalcSQRNUM.java._trace +/.SQROSZ.java._trace +/.CalcSQRCC.java._trace +/.CalcMetric2.java._trace diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQRMAX.xtend_ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQRMAX.xtend_ new file mode 100644 index 00000000..071abe38 --- /dev/null +++ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQRMAX.xtend_ @@ -0,0 +1,87 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculations + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.examples.Util +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.neighbourhood.PartialInterpretation2ImmutableTypeLattice +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialInterpretation +import java.util.HashMap +import java.util.Map +import java.util.Set +import org.eclipse.emf.ecore.EObject + +import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.* + +class CalcSQRMAX extends CalcMetric{ + + // /////////////////// + // SQRMAX(v) = # squares containing v / (# neighbours of v * max # of neeighbours of any neighbour of v) + // /////////////////// + static val neighbourhoodComputer = new PartialInterpretation2ImmutableTypeLattice + + override calcFromModel(EObject model) { + val nodes = model.eResource.allContents.toList + + // fill HashSet + var Map> node2Neighbours = new HashMap + Util.fillWithNodes(nodes, node2Neighbours) + + // iterate over nodes and add connected nodes + Util.getNeighboursList(nodes, node2Neighbours) + + // Measurements + var totalC = 0.0 + var max2ndNeighbours = 0.0 + var num1stNeighbours = 0.0 + for (node : nodes) { + val neighbours = node.lookup(node2Neighbours) + num1stNeighbours = neighbours.size + max2ndNeighbours = 0 + var numSquares = 0.0 + for (neighbour1 : neighbours) { + for (neighbour2 : neighbours) { + if (neighbour1 != neighbour2) { + val neighsOfNeigh = neighbour1.lookup(node2Neighbours) + if (max2ndNeighbours < neighsOfNeigh.size) { + max2ndNeighbours = neighsOfNeigh.size + } + for (neighOfNeigh1 : neighsOfNeigh) { + if (neighOfNeigh1 != node && neighOfNeigh1.lookup(node2Neighbours).contains(neighbour2)) { +// print(neighbour1) +// print(" ") +// print(neighbour2) +// print(" ") +// print(neighOfNeigh1) +// println() + numSquares++ + } + } + + } + } + } +// println(node) + val num2ndNeighbours = num1stNeighbours * max2ndNeighbours + +// print("(" + numSquares + "x" + num2ndNeighbours) + var sqr = 0.0 + if (num2ndNeighbours != 0) { + sqr = numSquares / num2ndNeighbours + } + +// println("=" + sqr + ")") + totalC += sqr + } + val numNodes = nodes.length + val avgC = totalC / numNodes + + return avgC + } + + override calcFromNHLattice(PartialInterpretation pm) { + return 0.0 +// return getCfromNHLattice(pm, 2, v) + } + + override calcFromNHLattice(PartialInterpretation pm, Integer depth) { + return 0.0 + } +} \ No newline at end of file diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQROSZ2.xtend_ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQROSZ2.xtend_ new file mode 100644 index 00000000..e999d62f --- /dev/null +++ b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/CalcSQROSZ2.xtend_ @@ -0,0 +1,69 @@ +package ca.mcgill.ecse.dslreasoner.realistic.metrics.calculations + +import ca.mcgill.ecse.dslreasoner.realistic.metrics.examples.Util +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.neighbourhood.PartialInterpretation2ImmutableTypeLattice +import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage.partialinterpretation.PartialInterpretation +import java.util.HashMap +import java.util.Map +import java.util.Set +import org.eclipse.emf.ecore.EObject + +import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.* + +class CalcSQROSZ2 extends CalcMetric { + + // /////////////////// + // SQROSZ2(v) = # depth-4 paths that lead to v / total # depth-4 paths + // /////////////////// + static val neighbourhoodComputer = new PartialInterpretation2ImmutableTypeLattice + + override calcFromModel(EObject model) { + val nodes = model.eResource.allContents.toList + + // fill HashSet + var Map> node2Neighbours = new HashMap + Util.fillWithNodes(nodes, node2Neighbours) + + // iterate over nodes and add connected nodes + Util.getNeighboursList(nodes, node2Neighbours) + + // Measurements + var totalSQR = 0.0 + var totalDenom = 0.0 + var num4thNeighbours = 0.0 + for (node : nodes) { + val neighbours = node.lookup(node2Neighbours) + + for (neighbour1 : neighbours) { + val neighbours1 = neighbour1.lookup(node2Neighbours) + + for (neighbour2 : neighbours1) { + val neighbours2 = neighbour2.lookup(node2Neighbours) + + for (neighbour3 : neighbours2) { + val neighbours3 = neighbour3.lookup(node2Neighbours) + num4thNeighbours = neighbours3.size + + if (neighbours3.contains(node)) { + totalSQR += 1 + } + totalDenom += num4thNeighbours + } + } + } + + } + val avgSQR = totalSQR / totalDenom + + return avgSQR + } + + override calcFromNHLattice(PartialInterpretation pm) { + return 0.0 +// return getCfromNHLattice(pm, 2, v) + } + + override calcFromNHLattice(PartialInterpretation pm, Integer depth) { + return 0.0 + } +} \ No newline at end of file diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.xtendbin new file mode 100644 index 00000000..ed4f8ad0 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.xtendbin new file mode 100644 index 00000000..c06ce100 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.xtendbin b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.xtendbin new file mode 100644 index 00000000..992d5b16 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/bin/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.xtendbin differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace new file mode 100644 index 00000000..5ab4c0fb Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace new file mode 100644 index 00000000..605b2480 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcEDA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace new file mode 100644 index 00000000..16ded94b Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMPC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace new file mode 100644 index 00000000..bd23cb35 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace new file mode 100644 index 00000000..71d80e38 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcMetric2.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace new file mode 100644 index 00000000..b423786d Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace new file mode 100644 index 00000000..cce23aec Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDA.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace new file mode 100644 index 00000000..e46f9600 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcNDC.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace new file mode 100644 index 00000000..9ce2edb2 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRCNT.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace new file mode 100644 index 00000000..cdfcef6e Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRNUM.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace new file mode 100644 index 00000000..0c8cc5d0 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/calculations/.CalcSQRTOT.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace new file mode 100644 index 00000000..edd88562 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.FixModelURIs.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace new file mode 100644 index 00000000..fc92b1d3 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.MetricsCalculationUsingShapes.java._trace differ diff --git a/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace new file mode 100644 index 00000000..306c1361 Binary files /dev/null and b/Metrics/ca.mcgill.ecse.dslreasoner.realistic.metrics/xtend-gen/ca/mcgill/ecse/dslreasoner/realistic/metrics/examples/.Util.java._trace differ diff --git a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF index 2abc6d50..fea5cc00 100644 --- a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF +++ b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.visualisation/META-INF/MANIFEST.MF @@ -28,7 +28,7 @@ Require-Bundle: com.google.guava, org.apache.xerces;bundle-version="2.9.0", org.w3c.dom.svg;bundle-version="1.1.0", org.w3c.css.sac;bundle-version="1.3.1", - org.eclipse.m2e.maven.runtime.slf4j.simple;bundle-version="1.10.0" + org.eclipse.m2e.maven.runtime.slf4j.simple Import-Package: com.eclipsesource.v8;version="4.6.0", com.eclipsesource.v8.debug;version="4.6.0", com.eclipsesource.v8.utils;version="4.6.0", diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 9ecc00be..313b9c2d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index c144df13..97ee1913 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 979c3c20..3424dc60 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index 804df64e..3b0345ce 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 50db435b..3a05d228 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 904ac639..418ee88d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index 082ca9ff..b4a32db5 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 5b68084b..89284901 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 7a054d7e..633cd134 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index fa4872a5..75f7c519 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index 7cf878e2..b9ec3204 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index 38132416..3052ed33 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index 2b223516..67b4ffcc 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 5cda3bdc..297a4f85 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index ec7ce5bf..d21e62df 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 4d0599ac..6fa1ad33 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 885e7af1..16598303 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 0793f3cb..760c5e1f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index 7fa7b29d..db66ddba 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index 9e37d9b8..d6fe4078 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 2cca61d2..81468f27 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index 20c757c7..d6924639 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 580ed0d8..9541df30 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index 108846a5..bb87d246 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index 9a04f61e..61879add 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 1d3166e7..1d6d6da8 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 002097ed..3a055e01 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index 769807cc..e7c2bd91 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig index e56cf30c..ca40f487 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/configs/fam.vsconfig @@ -1,10 +1,10 @@ import epackage "FamMetamodel" -import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns" +//import viatra "ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.FamPatterns" generate { metamodel = { package fam } - constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} - partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} +// constraints = { package ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries} +// partial-model = { "platform:/resource/ca.mcgill.ecse.dslreasoner.standalone.test/instanceModels/famInstance.xmi"} solver = ViatraSolver scope = { #node = 10 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt index 28b10066..d66c8df1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/errors.txt @@ -445,4 +445,109 @@ Error occured (UnsupportedOperationException): Can not transform pattern "ca.mcg hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:339) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:111) hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) - org.eclipse.core.internal.jobs.Worker.run(Worker.java:56) \ No newline at end of file + org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60)Error occured (NoSuchElementException): Cannot find entry with FQN ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries.model + org.eclipse.viatra.query.runtime.registry.impl.GlobalRegistryView.getEntry(GlobalRegistryView.java:56) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.findQuerySpecification(QueryBasedFeatureSettingDelegateFactory.java:152) + org.eclipse.viatra.addon.querybasedfeatures.runtime.QueryBasedFeatureSettingDelegateFactory.createSettingDelegate(QueryBasedFeatureSettingDelegateFactory.java:113) + org.eclipse.emf.ecore.impl.EStructuralFeatureImpl.getSettingDelegate(EStructuralFeatureImpl.java:854) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionalElementImpl.(FunctionalElementImpl.java:57) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.FunctionImpl.(FunctionImpl.java:64) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.createFunction(famFactoryImpl.java:125) + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl.famFactoryImpl.create(famFactoryImpl.java:68) + hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore.transformInterpretation(Logic2Ecore.java:75) + hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor.executeGenerationTask(GenerationTaskExecutor.java:359) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor._execute(ScriptExecutor.java:129) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.execute(ScriptExecutor.java:338) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor.executeScript(ScriptExecutor.java:110) + hu.bme.mit.inf.dslreasoner.application.execution.ScriptExecutor$1.run(ScriptExecutor.java:73) + org.eclipse.core.internal.jobs.Worker.run(Worker.java:60) \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated index b3223685..4ca1b4b0 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generated3valued.vql_deactivated @@ -55028,3 +55028,17614 @@ pattern refineRelation_type_attribute_Function( find mayInRelationtype_attribute_Function(problem,interpretation,from,to); neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); } +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class DefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class DefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class UndefinedPart"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class UndefinedPart". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class_UndefinedPart(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries terminatorAndInformation +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mayInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_I); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +}or{ + find interpretation(problem,interpretation); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mayInstanceOfInformationLink_class(problem,interpretation,var_I); + find mayInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_In); + find mayInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mayInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + find mayEquivalent(problem, interpretation, var_virtual1, var_T); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation( + problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,var_Out,var_virtual0); + find mustInstanceOfInformationLink_class(problem,interpretation,var_virtual0); + var_virtual0 == var_I; + find mustInstanceOfFunctionalOutput_class(problem,interpretation,var_Out); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_Out,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_T); + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + // T is exported + // I is exported + find mustInstanceOfInformationLink_class(problem,interpretation,var_I); + find mustInRelationto_reference_InformationLink(problem,interpretation,var_I,var_virtual0); + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_virtual0); + var_virtual0 == var_In; + find mustInstanceOfFunctionalInput_class(problem,interpretation,var_In); + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,var_In,var_virtual1); + find mustInstanceOfFAMTerminator_class(problem,interpretation,var_virtual1); + var_virtual1 == var_T; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries rootElements +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mayInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Root); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_rootElements( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Model, var_Root) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInstanceOfFunction_class(problem,interpretation,var_Root); + // Model is exported + // Root is exported + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,var_Model); + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,var_Model,var_virtual0); + find mustInstanceOfFunctionalElement_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Root; +} +// Must, May and Current queries for pattern ca mcgill ecse dslreasoner standalone test fam queries parent +private pattern mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} +private pattern mayInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mayInstanceOfFunction_class(problem,interpretation,var_Func); + find mayInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mayInstanceOfFunction_class(problem,interpretation,var_virtual0); + find mayEquivalent(problem, interpretation, var_virtual0, var_Par); +} +private pattern currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_parent( + problem:LogicProblem, interpretation:PartialInterpretation, + var_Func, var_Par) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInstanceOfFunction_class(problem,interpretation,var_Par); + // Func is exported + // Par is exported + find mustInstanceOfFunction_class(problem,interpretation,var_Func); + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,var_Func,var_virtual0); + find mustInstanceOfFunction_class(problem,interpretation,var_virtual0); + var_virtual0 == var_Par; +} + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// +pattern invalidatedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find mustInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// +pattern unfinishedBy_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem:LogicProblem, interpretation:PartialInterpretation, + var_T, var_I) +{ + find currentInRelation_pattern_ca_mcgill_ecse_dslreasoner_standalone_test_fam_queries_terminatorAndInformation(problem,interpretation,var_T,var_I); +} + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_DefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class_UndefinedPart( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class UndefinedPart"); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class_UndefinedPart(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class_UndefinedPart(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} +import epackage "http://www.bme.hu/mit/inf/dslreasoner/viatrasolver/partialinterpretationlanguage" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/problem" +import epackage "http://www.bme.hu/mit/inf/dslreasoner/logic/model/language" + +////////// +// 0. Util +////////// +private pattern interpretation(problem:LogicProblem, interpretation:PartialInterpretation) { + PartialInterpretation.problem(interpretation,problem); +} + +///////////////////////// +// 0.1 Existence +///////////////////////// +private pattern mustExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find interpretation(problem,interpretation); + LogicProblem.elements(problem,element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); +} + +private pattern mayExist(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + find mustExist(problem,interpretation,element); +} or { + find interpretation(problem,interpretation); + neg find elementCloseWorld(element); + PartialInterpretation.openWorldElements(interpretation,element); +} + +private pattern elementCloseWorld(element:DefinedElement) { + PartialInterpretation.openWorldElements(i,element); + PartialInterpretation.maxNewElements(i,0); +} or { + Scope.targetTypeInterpretation(scope,interpretation); + PartialTypeInterpratation.elements(interpretation,element); + Scope.maxNewElements(scope,0); +} + +//////////////////////// +// 0.2 Equivalence +//////////////////////// +pattern mayEquivalent(problem:LogicProblem, interpretation:PartialInterpretation, a: DefinedElement, b: DefinedElement) { + find mayExist(problem,interpretation,a); + find mayExist(problem,interpretation,b); + a == b; +} + +//////////////////////// +// 0.3 Required Patterns by TypeIndexer +//////////////////////// +private pattern typeInterpretation(problem:LogicProblem, interpretation:PartialInterpretation, type:TypeDeclaration, typeInterpretation:PartialComplexTypeInterpretation) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); +} + +private pattern directInstanceOf(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement, type:Type) { + find interpretation(problem,interpretation); + LogicProblem.types(problem,type); + TypeDefinition.elements(type,element); +} or { + find interpretation(problem,interpretation); + find typeInterpretation(problem,interpretation,type,typeInterpretation); + PartialComplexTypeInterpretation.elements(typeInterpretation,element); +} + +private pattern isPrimitive(element: PrimitiveElement) { + PrimitiveElement(element); +} + +////////// +// 1. Problem-Specific Base Indexers +////////// +// 1.1 Type Indexers +////////// +// 1.1.1 primitive Type Indexers +////////// + +////////// +// 1.1.2 domain-specific Type Indexers +////////// +/** + * An element must be an instance of type "FunctionalElement class". + */ +private pattern mustInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalElement class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalElement class"); +} + +/** + * An element may be an instance of type "FunctionalElement class". + */ +private pattern mayInstanceOfFunctionalElement_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalElement_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalElement_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mustInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalArchitectureModel class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalArchitectureModel class"); +} + +/** + * An element may be an instance of type "FunctionalArchitectureModel class". + */ +private pattern mayInstanceOfFunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalArchitectureModel_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); } +/** + * An element must be an instance of type "Function class". + */ +private pattern mustInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"Function class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunction_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"Function class"); +} + +/** + * An element may be an instance of type "Function class". + */ +private pattern mayInstanceOfFunction_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunction_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunction_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FAMTerminator class". + */ +private pattern mustInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FAMTerminator class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FAMTerminator class"); +} + +/** + * An element may be an instance of type "FAMTerminator class". + */ +private pattern mayInstanceOfFAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFAMTerminator_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFAMTerminator_class(problem,interpretation,element); } +/** + * An element must be an instance of type "InformationLink class". + */ +private pattern mustInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"InformationLink class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"InformationLink class"); +} + +/** + * An element may be an instance of type "InformationLink class". + */ +private pattern mayInstanceOfInformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewInformationLink_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfInformationLink_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInterface class". + */ +private pattern mustInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInterface class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInterface class"); +} + +/** + * An element may be an instance of type "FunctionalInterface class". + */ +private pattern mayInstanceOfFunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInterface_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalInput class". + */ +private pattern mustInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalInput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalInput class"); +} + +/** + * An element may be an instance of type "FunctionalInput class". + */ +private pattern mayInstanceOfFunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalInput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalInput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalOutput class". + */ +private pattern mustInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalOutput class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalOutput class"); +} + +/** + * An element may be an instance of type "FunctionalOutput class". + */ +private pattern mayInstanceOfFunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalOutput_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionalData class". + */ +private pattern mustInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionalData class"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionalData class"); +} + +/** + * An element may be an instance of type "FunctionalData class". + */ +private pattern mayInstanceOfFunctionalData_class(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or { + find interpretation(problem,interpretation); + PartialInterpretation.openWorldElements(interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find scopeDisallowsNewFunctionalData_class(problem, interpretation); + neg find isPrimitive(element); +} or +{ find mustInstanceOfFunctionalData_class(problem,interpretation,element); } +/** + * An element must be an instance of type "FunctionType enum". + */ +private pattern mustInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) { + Type.name(type,"FunctionType enum"); + find directInstanceOf(problem,interpretation,element,type); +} +private pattern scopeDisallowsNewFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation) { + find interpretation(problem,interpretation); + PartialInterpretation.scopes(interpretation,scope); + Scope.targetTypeInterpretation(scope,typeInterpretation); + Scope.maxNewElements(scope,0); + PartialComplexTypeInterpretation.interpretationOf(typeInterpretation,type); + Type.name(type,"FunctionType enum"); +} + +/** + * An element may be an instance of type "FunctionType enum". + */ +private pattern mayInstanceOfFunctionType_enum(problem:LogicProblem, interpretation:PartialInterpretation, element:DefinedElement) +{ find mustInstanceOfFunctionType_enum(problem,interpretation,element); } + +////////// +// 1.2 Relation Declaration Indexers +////////// +/** + * Matcher for detecting tuples t where []interface reference FunctionalElement(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalElement(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []model reference FunctionalElement(source,target) + */ +private pattern mustInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>model reference FunctionalElement(source,target) + */ +private pattern mayInRelationmodel_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []parent reference FunctionalElement(source,target) + */ +private pattern mustInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"parent reference FunctionalElement"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>parent reference FunctionalElement(source,target) + */ +private pattern mayInRelationparent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalElement_class(problem,interpretation,source); + find mayInstanceOfFunction_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationparent_reference_FunctionalElement(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mustInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"rootElements reference FunctionalArchitectureModel"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>rootElements reference FunctionalArchitectureModel(source,target) + */ +private pattern mayInRelationrootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []subElements reference Function(source,target) + */ +private pattern mustInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"subElements reference Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>subElements reference Function(source,target) + */ +private pattern mayInRelationsubElements_reference_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationparent_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FAMTerminator(source,target) + */ +private pattern mustInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FAMTerminator"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FAMTerminator(source,target) + */ +private pattern mayInRelationdata_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFAMTerminator_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FAMTerminator(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []from reference InformationLink(source,target) + */ +private pattern mustInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"from reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>from reference InformationLink(source,target) + */ +private pattern mayInRelationfrom_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationfrom_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []to reference InformationLink(source,target) + */ +private pattern mustInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>to reference InformationLink(source,target) + */ +private pattern mayInRelationto_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfInformationLink_class(problem,interpretation,source); + find mayInstanceOfFunctionalInput_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationto_reference_InformationLink(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []data reference FunctionalInterface(source,target) + */ +private pattern mustInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"data reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>data reference FunctionalInterface(source,target) + */ +private pattern mayInRelationdata_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalData_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []element reference FunctionalInterface(source,target) + */ +private pattern mustInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"element reference FunctionalInterface"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>element reference FunctionalInterface(source,target) + */ +private pattern mayInRelationelement_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInterface_class(problem,interpretation,source); + find mayInstanceOfFunctionalElement_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationelement_reference_FunctionalInterface(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mustInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>IncomingLinks reference FunctionalInput(source,target) + */ +private pattern mayInRelationIncomingLinks_reference_FunctionalInput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalInput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); +} or { + find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mustInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"outgoingLinks reference FunctionalOutput"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>outgoingLinks reference FunctionalOutput(source,target) + */ +private pattern mayInRelationoutgoingLinks_reference_FunctionalOutput( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalOutput_class(problem,interpretation,source); + find mayInstanceOfInformationLink_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationfrom_reference_InformationLink(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []terminator reference FunctionalData(source,target) + */ +private pattern mustInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"terminator reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>terminator reference FunctionalData(source,target) + */ +private pattern mayInRelationterminator_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFAMTerminator_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // There are "numberOfExistingReferences" currently existing instances of the reference to the target, + // the upper bound of the opposite reference multiplicity should be considered. + numberOfExistingOppositeReferences == count find mustInRelationdata_reference_FAMTerminator(problem,interpretation,target,_); + check(numberOfExistingOppositeReferences < 1); + // The reference is containment, then a new reference cannot be create if: + // 1. Multiple parents + neg find mustContains4(problem,interpretation,_,target); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []interface reference FunctionalData(source,target) + */ +private pattern mustInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"interface reference FunctionalData"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>interface reference FunctionalData(source,target) + */ +private pattern mayInRelationinterface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunctionalData_class(problem,interpretation,source); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); + // The eOpposite of the reference is containment, then a referene cannot be created if + // 1. Multiple parents + neg find mustContains4(problem,interpretation,source,_); + // 2. Circle in the containment hierarchy + neg find mustTransitiveContains(source,target); +} or { + find mustInRelationinterface_reference_FunctionalData(problem,interpretation,source,target); +} +/** + * Matcher for detecting tuples t where []type attribute Function(source,target) + */ +private pattern mustInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + PartialRelationInterpretation.relationlinks(relationIterpretation,link); + BinaryElementRelationLink.param1(link,source); + BinaryElementRelationLink.param2(link,target); +} +/** + * Matcher for detecting tuples t where <>type attribute Function(source,target) + */ +private pattern mayInRelationtype_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target:DefinedElement) +{ + find interpretation(problem,interpretation); + // The two endpoint of the link have to exist + find mayExist(problem, interpretation, source); + find mayExist(problem, interpretation, target); + // Type consistency + find mayInstanceOfFunction_class(problem,interpretation,source); + find mayInstanceOfFunctionType_enum(problem,interpretation,target); + // There are "numberOfExistingReferences" currently existing instances of the reference from the source, + // the upper bound of the multiplicity should be considered. + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,source,_); + check(numberOfExistingReferences < 1); +} or { + find mustInRelationtype_attribute_Function(problem,interpretation,source,target); +} + +////////// +// 1.3 Relation Definition Indexers +////////// + +////////// +// 1.4 Containment Indexer +////////// +private pattern mustContains2(source: DefinedElement, target: DefinedElement) { + find mustContains4(_,_,source,target); +} + +private pattern mustContains4(problem:LogicProblem, interpretation:PartialInterpretation, + source: DefinedElement, target: DefinedElement) + { find mustInRelationinterface_reference_FunctionalElement(problem,interpretation,source,target); }or + + { find mustInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,source,target); }or + + { find mustInRelationsubElements_reference_Function(problem,interpretation,source,target); }or + + { find mustInRelationdata_reference_FunctionalInterface(problem,interpretation,source,target); }or + + { find mustInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,source,target); }or + + { find mustInRelationterminator_reference_FunctionalData(problem,interpretation,source,target); } + +private pattern mustTransitiveContains(source,target) { + find mustContains2+(source,target); +} + +////////// +// 2. Invalidation Indexers +////////// +// 2.1 Invalidated by WF Queries +////////// + +////////// +// 3. Unfinishedness Indexers +////////// +// 3.1 Unfinishedness Measured by Multiplicity +////////// +pattern unfinishedLowerMultiplicity_model_reference_FunctionalElement(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_to_reference_InformationLink(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"to reference InformationLink"); + find mustInstanceOfInformationLink_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationto_reference_InformationLink(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} +pattern unfinishedLowerMultiplicity_type_attribute_Function(problem:LogicProblem, interpretation:PartialInterpretation, relationIterpretation:PartialRelationInterpretation, object:DefinedElement,missingMultiplicity) { + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustInstanceOfFunction_class(problem,interpretation,object); + numberOfExistingReferences == count find mustInRelationtype_attribute_Function(problem,interpretation,object,_); + check(numberOfExistingReferences < 1); + missingMultiplicity == eval(1-numberOfExistingReferences); +} + +////////// +// 3.2 Unfinishedness Measured by WF Queries +////////// + +////////// +// 4. Refinement Indexers +////////// +// 4.1 Object constructors +////////// +private pattern hasElementInContainment(problem:LogicProblem, interpretation:PartialInterpretation) +{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFAMTerminator_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunction_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfInformationLink_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalElement_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +}or{ + find interpretation(problem,interpretation); + find mustInstanceOfFunctionalData_class(problem,interpretation,root); + find mustExist(problem, interpretation, root); +} +pattern createObject_FunctionalInterface_class_by_interface_reference_FunctionalElement_with_element_reference_FunctionalInterface( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"interface reference FunctionalElement"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"element reference FunctionalInterface"); + find mustInstanceOfFunctionalElement_class(problem,interpretation,container); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayInRelationinterface_reference_FunctionalElement(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInterface_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInterface class"); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_rootElements_reference_FunctionalArchitectureModel( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"rootElements reference FunctionalArchitectureModel"); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationrootElements_reference_FunctionalArchitectureModel(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class_by_subElements_reference_Function_with_parent_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"subElements reference Function"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"parent reference FunctionalElement"); + find mustInstanceOfFunction_class(problem,interpretation,container); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayInRelationsubElements_reference_Function(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_Function_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"Function class"); + find mayInstanceOfFunction_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalOutput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalOutput class"); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class_by_terminator_reference_FunctionalData_with_data_reference_FAMTerminator( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"terminator reference FunctionalData"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"data reference FAMTerminator"); + find mustInstanceOfFunctionalData_class(problem,interpretation,container); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayInRelationterminator_reference_FunctionalData(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FAMTerminator_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FAMTerminator class"); + find mayInstanceOfFAMTerminator_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class_by_outgoingLinks_reference_FunctionalOutput_with_from_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"outgoingLinks reference FunctionalOutput"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"from reference InformationLink"); + find mustInstanceOfFunctionalOutput_class(problem,interpretation,container); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayInRelationoutgoingLinks_reference_FunctionalOutput(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_InformationLink_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"InformationLink class"); + find mayInstanceOfInformationLink_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class_by_data_reference_FunctionalInterface_with_interface_reference_FunctionalData( + problem:LogicProblem, interpretation:PartialInterpretation, + relationInterpretation:PartialRelationInterpretation, inverseInterpretation:PartialRelationInterpretation, typeInterpretation:PartialComplexTypeInterpretation, + container:DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + PartialInterpretation.partialrelationinterpretation(interpretation,relationInterpretation); + PartialRelationInterpretation.interpretationOf.name(relationInterpretation,"data reference FunctionalInterface"); + PartialInterpretation.partialrelationinterpretation(interpretation,inverseInterpretation); + PartialRelationInterpretation.interpretationOf.name(inverseInterpretation,"interface reference FunctionalData"); + find mustInstanceOfFunctionalInterface_class(problem,interpretation,container); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayInRelationdata_reference_FunctionalInterface(problem,interpretation,container,newObject); + find mustExist(problem, interpretation, container); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalInput_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalInput class"); + find mayInstanceOfFunctionalInput_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} +pattern createObject_FunctionalArchitectureModel_class( + problem:LogicProblem, interpretation:PartialInterpretation, + typeInterpretation:PartialComplexTypeInterpretation) +{ + find interpretation(problem,interpretation); + neg find hasElementInContainment(problem,interpretation); + PartialInterpretation.partialtypeinterpratation(interpretation,typeInterpretation); + PartialComplexTypeInterpretation.interpretationOf.name(typeInterpretation,"FunctionalArchitectureModel class"); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,newObject); + find mayExist(problem, interpretation, newObject); + neg find mustExist(problem, interpretation, newObject); +} + +////////// +// 4.2 Type refinement +////////// +pattern refineTypeTo_FunctionalInterface_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_Function_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunction_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalOutput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FAMTerminator_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_InformationLink_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalInput_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalOutput_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInput_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} +pattern refineTypeTo_FunctionalArchitectureModel_class(problem:LogicProblem, interpretation:PartialInterpretation, element: DefinedElement) { + find interpretation(problem,interpretation); + PartialInterpretation.newElements(interpretation,element); + find mayInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalInterface_class(problem,interpretation,element); + neg find mustInstanceOfFAMTerminator_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalData_class(problem,interpretation,element); + neg find mustInstanceOfInformationLink_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalElement_class(problem,interpretation,element); + neg find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,element); +} + +////////// +// 4.3 Relation refinement +////////// +pattern refineRelation_model_reference_FunctionalElement( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"model reference FunctionalElement"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalElement_class(problem,interpretation,from); + find mustInstanceOfFunctionalArchitectureModel_class(problem,interpretation,to); + find mayInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); + neg find mustInRelationmodel_reference_FunctionalElement(problem,interpretation,from,to); +} +pattern refineRelation_IncomingLinks_reference_FunctionalInput_and_to_reference_InformationLink( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, oppositeInterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"IncomingLinks reference FunctionalInput"); + PartialInterpretation.partialrelationinterpretation(interpretation,oppositeInterpretation); + PartialRelationInterpretation.interpretationOf.name(oppositeInterpretation,"to reference InformationLink"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunctionalInput_class(problem,interpretation,from); + find mustInstanceOfInformationLink_class(problem,interpretation,to); + find mayInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); + neg find mustInRelationIncomingLinks_reference_FunctionalInput(problem,interpretation,from,to); +} +pattern refineRelation_type_attribute_Function( + problem:LogicProblem, interpretation:PartialInterpretation, + relationIterpretation:PartialRelationInterpretation, + from: DefinedElement, to: DefinedElement) +{ + find interpretation(problem,interpretation); + PartialInterpretation.partialrelationinterpretation(interpretation,relationIterpretation); + PartialRelationInterpretation.interpretationOf.name(relationIterpretation,"type attribute Function"); + find mustExist(problem, interpretation, from); + find mustExist(problem, interpretation, to); + find mustInstanceOfFunction_class(problem,interpretation,from); + find mustInstanceOfFunctionType_enum(problem,interpretation,to); + find mayInRelationtype_attribute_Function(problem,interpretation,from,to); + neg find mustInRelationtype_attribute_Function(problem,interpretation,from,to); +} diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem index 061a233a..296c3a70 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/generation.logicproblem @@ -1,7 +1,7 @@ - + - + @@ -10,8 +10,6 @@ - - @@ -496,22 +494,6 @@ - - - - - - - - - - - - - - - - @@ -572,53 +554,10 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + @@ -638,6 +577,4 @@ - - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel index 3f2640d6..55020b90 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/debug/init.partialmodel @@ -1,5 +1,5 @@ - + @@ -86,7 +86,6 @@ - @@ -110,9 +109,6 @@ - - - @@ -126,5 +122,4 @@ - diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt index 6386e508..c7112d9d 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/log.txt @@ -1 +1 @@ -Model generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file +Model generation startedModel generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finishedModel generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Model generation startedProblem is consistent, 5 models are generated!Models: [1.xmi][2.xmi][3.xmi][4.xmi][5.xmi]Visualisations: [1.gml][2.gml][3.gml][4.gml][5.gml]Visualisations: [1.png][2.png][3.png][4.png][5.png]Model generation finished \ No newline at end of file diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml index b0a86a61..a40633d7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.gml @@ -11696,3 +11696,3432 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png index 158ebb0f..a5fb7f02 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi index 3dcec4a4..ec5dbad1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/1.xmi @@ -1,13 +1,11 @@ - - - - - - - - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml index 62441d63..e581a1a4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.gml @@ -11699,3 +11699,2509 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png index 0222b4b1..25c578df 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi index 144e4fc5..16f82b48 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/2.xmi @@ -1,12 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml index e046559b..9ae40173 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.gml @@ -11660,3 +11660,2472 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png index a551c9fc..61e37719 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi index 9e8efc63..fbbc6cb4 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/3.xmi @@ -1,12 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml index f41692fc..8b6731b7 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.gml @@ -11761,3 +11761,2508 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 10 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png index c58be27f..b63f378c 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi index c5049270..950fe6a2 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/4.xmi @@ -1,12 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml index 9bbf93f7..a31b5aea 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.gml @@ -11873,3 +11873,2508 @@ graph ] ] ] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 177.10000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + InformationLink class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 7 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "from reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "to reference InformationLink" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 11 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "IncomingLinks reference FunctionalInput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "outgoingLinks reference FunctionalOutput" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 8 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 7 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] +graph +[ + node + [ + id 0 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Root literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 1 + graphics + [ + w 297.0 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Intermediate literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 2 + graphics + [ + w 226.60000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "Leaf literal FunctionType" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionType enum + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 3 + graphics + [ + w 41.800000000000004 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "true" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 4 + graphics + [ + w 50.6 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "false" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 5 + graphics + [ + w 207.9 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInterface class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 6 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 7 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 8 + graphics + [ + w 177.10000000000002 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalInput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 9 + graphics + [ + w 184.8 + h 54 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FunctionalOutput class + FunctionalData class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 10 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 11 + graphics + [ + w 161.70000000000002 + h 40 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "null" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + FAMTerminator class + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 12 + graphics + [ + w 112.2 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Integers" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 13 + graphics + [ + w 85.80000000000001 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Reals" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 14 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Strings" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + + node + [ + id 15 + graphics + [ + w 103.4 + h 26 + type "rectangle" + fill "#FFFFFF" + fill2 "#FFFFFF" + outline "#000000" + ] + LabelGraphics + [ + text "New Objects" + outline "#000000" + fill "#FFFFFF" + fontSize 16 + fontName "Monospace" + autoSizePolicy "node_width" + anchor "t" + borderDistance 0.0 + ] + LabelGraphics + [ + text " + " + fontSize 14 + fontName "Consolas" + alignment "left" + anchor "tl" + borderDistance 6 + ] + ] + edge + [ + source 7 + target 6 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 10 + target 8 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 11 + target 9 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FAMTerminator" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 6 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 8 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 5 + target 9 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "data reference FunctionalInterface" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 7 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 10 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 11 + graphics + [ + fill "#000000" + width 3 + targetArrow "standard" + ] + LabelGraphics + [ + text "terminator reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 6 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 8 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] + edge + [ + source 9 + target 5 + graphics + [ + fill "#000000" + targetArrow "standard" + ] + LabelGraphics + [ + text "interface reference FunctionalData" + fontSize 14 + fontName "Consolas" + configuration "AutoFlippingLabel" + model "six_pos" + position "thead" + ] + ] +] diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png index a141edb0..c45fa07b 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png and b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.png differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi index c5049270..777693ab 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/models/5.xmi @@ -1,12 +1,12 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv index 9f61f0e9..71fff7c5 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/outputs/fam/statistics.csv @@ -26,3 +26,9 @@ Task;Run;Result;Domain to logic transformation time;Logic to solver transformati 1;1;ModelResultImpl;16;1673;1881;10488189500;142;240;275;311;375;191;21;7;0;5 Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime 1;1;ModelResultImpl;47;1835;2309;9517642900;281;405;544;574;580;325;17;13;0;6 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;1139;4621;3347;14457060200;924;988;1031;1071;1121;689;564;74;0;9 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;4;2111;1772;15065362500;113;152;185;238;303;159;18;7;0;5 +Task;Run;Result;Domain to logic transformation time;Logic to solver transformation time;Solver time;Postprocessing time;_Solution0FoundAt;_Solution1FoundAt;_Solution2FoundAt;_Solution3FoundAt;_Solution4FoundAt;TransformationExecutionTime;TypeAnalysisTime;StateCoderTime;StateCoderFailCount;SolutionCopyTime +1;1;ModelResultImpl;3;1388;1240;8813500300;67;71;96;122;145;86;7;3;0;3 diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem index f86a2f3c..48991faa 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/output/FAMTest/Fam.logicproblem @@ -1,7 +1,7 @@ - + @@ -10,8 +10,6 @@ - - @@ -496,6 +494,55 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -556,11 +603,14 @@ + + + + - - + @@ -580,4 +630,6 @@ + + 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 a7da818c..17f9ae5e 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 @@ -1,5 +1,6 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.BackendSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration import functionalarchitecture.FAMTerminator @@ -8,7 +9,6 @@ import functionalarchitecture.FunctionalArchitectureModel import functionalarchitecture.FunctionalInterface import functionalarchitecture.FunctionalOutput import functionalarchitecture.FunctionalarchitecturePackage -//import hu.bme.mit.inf.dslreasoner.domains.transima.fam.FamPatterns import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2Logic import hu.bme.mit.inf.dslreasoner.ecore2logic.Ecore2LogicConfiguration import hu.bme.mit.inf.dslreasoner.logic.model.builder.DocumentationLevel @@ -16,7 +16,6 @@ import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.LogicResult import hu.bme.mit.inf.dslreasoner.logic.model.logicresult.ModelResult import hu.bme.mit.inf.dslreasoner.logic2ecore.Logic2Ecore import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2Logic -import hu.bme.mit.inf.dslreasoner.viatra2logic.Viatra2LogicConfiguration import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2Logic import hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretation2logic.InstanceModel2PartialInterpretation import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace @@ -46,7 +45,7 @@ class FAMTest { // Load DSL val metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE) - val partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi") +// val partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi") // val queries = GeneralTest.loadQueries(metamodel, FamPatterns.instance) val queries = null @@ -54,7 +53,7 @@ class FAMTest { val modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, new Ecore2LogicConfiguration()) var problem = modelGenerationProblem.output - problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output +// problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).output // problem = viatra2Logic.transformQueries(queries, modelGenerationProblem, new Viatra2LogicConfiguration).output workspace.writeModel(problem, "Fam.logicproblem") @@ -96,6 +95,7 @@ class FAMTest { it.typeScopes.maxNewElements = 10//25 // if(typeMapMin.size != 0) it.typeScopes.minNewElementsByType = typeMapMin // if(typeMapMax.size != 0) it.typeScopes.maxNewElementsByType = typeMapMax + it.solver = BackendSolver::LOCVAMP it.contCycleLevel = 5 it.uniquenessDuplicates = false ] @@ -110,25 +110,25 @@ class FAMTest { // Literal(modelGenerationProblem.trace, ecore2Logic.allLiteralsInScope(modelGenerationProblem.trace).get(0) ) // ) // println((ecore2Logic.allAttributesInScope(modelGenerationProblem.trace)).get(0).EAttributeType) - print(interpretations.class) - for (interpretation : interpretations) { - val model = logic2Ecore.transformInterpretation(interpretation, modelGenerationProblem.trace) - workspace.writeModel(model, "model.xmi") - -// val representation = im2pi.transform(modelGenerationProblem, model.eAllContents.toList, false)//solution.representation.get(0) // TODO: fix for multiple represenations -// if (representation instanceof PartialInterpretation) { -// val vis1 = new PartialInterpretation2Gml -// val gml = vis1.transform(representation) -// workspace.writeText("model.gml", gml) +// print(interpretations.class) +// for (interpretation : interpretations) { +// val model = logic2Ecore.transformInterpretation(interpretation, modelGenerationProblem.trace) +// workspace.writeModel(model, "model.xmi") // -// val vis2 = new GraphvizVisualiser -// val dot = vis2.visualiseConcretization(representation) -// dot.writeToFile(workspace, "model.png") -// } else { -// println("ERROR") -// } -// look here: hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor - } +//// val representation = im2pi.transform(modelGenerationProblem, model.eAllContents.toList, false)//solution.representation.get(0) // TODO: fix for multiple represenations +//// if (representation instanceof PartialInterpretation) { +//// val vis1 = new PartialInterpretation2Gml +//// val gml = vis1.transform(representation) +//// workspace.writeText("model.gml", gml) +//// +//// val vis2 = new GraphvizVisualiser +//// val dot = vis2.visualiseConcretization(representation) +//// dot.writeToFile(workspace, "model.png") +//// } else { +//// println("ERROR") +//// } +//// look here: hu.bme.mit.inf.dslreasoner.application.execution.GenerationTaskExecutor +// } // transform interpretation to ecore, and it is easy from there /*/ @@ -147,7 +147,6 @@ class FAMTest { var totalTimeMin = (System.currentTimeMillis - startTime) / 60000 var totalTimeSec = ((System.currentTimeMillis - startTime) / 1000) % 60 - println("Problem solved") println("Time was: " + totalTimeMin + ":" + totalTimeSec) } diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 197ef5c9..7ccbe59f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index 52c819c4..b03f527f 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index b3b15fba..6bc303df 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index 03bcbad7..a34d7d3b 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index 0f06a39a..a8c5f173 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java index 8cd08fd8..cd9ba3c1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/FAMTest.java @@ -1,6 +1,7 @@ package ca.mcgill.ecse.dslreasoner.vampire.icse; import ca.mcgill.ecse.dslreasoner.vampire.icse.GeneralTest; +import ca.mcgill.ecse.dslreasoner.vampire.reasoner.BackendSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolver; import ca.mcgill.ecse.dslreasoner.vampire.reasoner.VampireSolverConfiguration; import functionalarchitecture.FAMTerminator; @@ -27,8 +28,6 @@ import hu.bme.mit.inf.dslreasoner.workspace.FileSystemWorkspace; import java.util.HashMap; import java.util.List; import java.util.Map; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; import org.eclipse.emf.ecore.resource.Resource; import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl; import org.eclipse.xtend2.lib.StringConcatenation; @@ -59,13 +58,11 @@ public class FAMTest { map.put("logicproblem", _xMIResourceFactoryImpl); InputOutput.println("Input and output workspaces are created"); final EcoreMetamodelDescriptor metamodel = GeneralTest.loadMetamodel(FunctionalarchitecturePackage.eINSTANCE); - final EList partialModel = GeneralTest.loadPartialModel(inputs, "FAM/FaModel.xmi"); final Object queries = null; InputOutput.println("DSL loaded"); Ecore2LogicConfiguration _ecore2LogicConfiguration = new Ecore2LogicConfiguration(); final TracedOutput modelGenerationProblem = ecore2Logic.transformMetamodel(metamodel, _ecore2LogicConfiguration); LogicProblem problem = modelGenerationProblem.getOutput(); - problem = instanceModel2Logic.transform(modelGenerationProblem, partialModel).getOutput(); workspace.writeModel(problem, "Fam.logicproblem"); InputOutput.println("Problem created"); long startTime = System.currentTimeMillis(); @@ -86,6 +83,7 @@ public class FAMTest { it.documentationLevel = DocumentationLevel.FULL; it.typeScopes.minNewElements = 8; it.typeScopes.maxNewElements = 10; + it.solver = BackendSolver.LOCVAMP; it.contCycleLevel = 5; it.uniquenessDuplicates = false; }; @@ -93,13 +91,6 @@ public class FAMTest { LogicResult solution = reasoner.solve(problem, vampireConfig, workspace); InputOutput.println("Problem solved"); List interpretations = reasoner.getInterpretations(((ModelResult) solution)); - InputOutput.>print(interpretations.getClass()); - for (final LogicModelInterpretation interpretation : interpretations) { - { - final EObject model = logic2Ecore.transformInterpretation(interpretation, modelGenerationProblem.getTrace()); - workspace.writeModel(model, "model.xmi"); - } - } long _currentTimeMillis = System.currentTimeMillis(); long _minus = (_currentTimeMillis - startTime); long totalTimeMin = (_minus / 60000); @@ -107,7 +98,6 @@ public class FAMTest { long _minus_1 = (_currentTimeMillis_1 - startTime); long _divide = (_minus_1 / 1000); long totalTimeSec = (_divide % 60); - InputOutput.println("Problem solved"); InputOutput.println(((("Time was: " + Long.valueOf(totalTimeMin)) + ":") + Long.valueOf(totalTimeSec))); } catch (Throwable _e) { throw Exceptions.sneakyThrow(_e); diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 5dcd3133..9a2c84d7 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index 68ade593..f39505b0 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 80e7ebe0..51d32da7 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin index 139dcdc7..0278755b 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin differ -- cgit v1.2.3-54-g00ecf From 8ecc73c4f8cd83d0ae807a55223f38a9b00505a9 Mon Sep 17 00:00:00 2001 From: ArenBabikian Date: Sat, 6 Jun 2020 19:19:18 -0400 Subject: VAMPIRE: Rebase on Master --- .../validation/QueryAndMetamodelValidator.java | 2 +- .../Examples/ModelGenExampleFAM_plugin/plugin.xml | 11 ++- .../META-INF/MANIFEST.MF | 44 ++++++------ .../META-INF/MANIFEST.MF | 24 +++---- .../META-INF/MANIFEST.MF | 32 ++++----- .../ide/.VampireLanguageIdeModule.xtendbin | Bin 1685 -> 1685 bytes .../ide/.VampireLanguageIdeSetup.xtendbin | Bin 2500 -> 2500 bytes .../ui/.VampireLanguageUiModule.xtendbin | Bin 2342 -> 2342 bytes .../.VampireLanguageProposalProvider.xtendbin | Bin 1792 -> 1792 bytes ...ampireLanguageDescriptionLabelProvider.xtendbin | Bin 1965 -> 1965 bytes .../.VampireLanguageLabelProvider.xtendbin | Bin 2405 -> 2405 bytes .../.VampireLanguageOutlineTreeProvider.xtendbin | Bin 1819 -> 1819 bytes .../.VampireLanguageQuickfixProvider.xtendbin | Bin 1786 -> 1786 bytes .../.VampireLanguageRuntimeModule.xtendbin | Bin 1706 -> 1706 bytes .../.VampireLanguageStandaloneSetup.xtendbin | Bin 1980 -> 1980 bytes .../formatting2/.VampireLanguageFormatter.xtendbin | Bin 3759 -> 3759 bytes .../generator/.VampireLanguageGenerator.xtendbin | Bin 2338 -> 2338 bytes .../scoping/.VampireLanguageScopeProvider.xtendbin | Bin 1751 -> 1751 bytes .../validation/.VampireLanguageValidator.xtendbin | Bin 1736 -> 1736 bytes .../META-INF/MANIFEST.MF | 10 +-- .../META-INF/MANIFEST.MF | 24 +++---- .../vampire/reasoner/queries/VLSAnd.java | 28 +++++--- .../vampire/reasoner/queries/VLSAnnotation.java | 28 +++++--- .../vampire/reasoner/queries/VLSComment.java | 28 +++++--- .../vampire/reasoner/queries/VLSEquivalent.java | 28 +++++--- .../reasoner/queries/VLSExistentialQuantifier.java | 28 +++++--- .../vampire/reasoner/queries/VLSFofFormula.java | 28 +++++--- .../vampire/reasoner/queries/VLSFunction.java | 28 +++++--- .../vampire/reasoner/queries/VLSFunctionFof.java | 28 +++++--- .../vampire/reasoner/queries/VLSInequality.java | 28 +++++--- .../vampire/reasoner/queries/VLSOr.java | 28 +++++--- .../vampire/reasoner/queries/VLSUnaryNegation.java | 28 +++++--- .../reasoner/queries/VLSUniversalQuantifier.java | 28 +++++--- .../.VampireAnalyzerConfiguration.xtendbin | Bin 3449 -> 3449 bytes .../vampire/reasoner/.VampireSolver.xtendbin | Bin 10104 -> 10104 bytes .../builder/.Logic2VampireLanguageMapper.xtendbin | Bin 19565 -> 19565 bytes .../.Logic2VampireLanguageMapperTrace.xtendbin | Bin 5080 -> 5080 bytes ...c2VampireLanguageMapper_ConstantMapper.xtendbin | Bin 3164 -> 3164 bytes ...ampireLanguageMapper_ContainmentMapper.xtendbin | Bin 11807 -> 11807 bytes ...c2VampireLanguageMapper_RelationMapper.xtendbin | Bin 7880 -> 7880 bytes ...ogic2VampireLanguageMapper_ScopeMapper.xtendbin | Bin 10684 -> 10684 bytes .../.Logic2VampireLanguageMapper_Support.xtendbin | Bin 17151 -> 17151 bytes ...Logic2VampireLanguageMapper_TypeMapper.xtendbin | Bin 11037 -> 11037 bytes .../reasoner/builder/.Vampire2LogicMapper.xtendbin | Bin 3998 -> 3998 bytes .../reasoner/builder/.VampireHandler.xtendbin | Bin 7743 -> 7743 bytes ...ModelInterpretation_TypeInterpretation.xtendbin | Bin 1491 -> 1491 bytes ...ation_TypeInterpretation_FilteredTypes.xtendbin | Bin 1688 -> 1688 bytes .../META-INF/MANIFEST.MF | 40 +++++------ .../META-INF/MANIFEST.MF | 76 ++++++++++----------- .../dslreasoner/vampire/icse/.EcoreTest.xtendbin | Bin 4545 -> 4545 bytes .../dslreasoner/vampire/icse/.FAMTest.xtendbin | Bin 6381 -> 6381 bytes .../vampire/icse/.FileSystemTest.xtendbin | Bin 6201 -> 6201 bytes .../dslreasoner/vampire/icse/.GeneralTest.xtendbin | Bin 6625 -> 6625 bytes .../dslreasoner/vampire/icse/.YakinduTest.xtendbin | Bin 9352 -> 9352 bytes .../vampire/test/.MedicalSystem.xtendbin | Bin 5003 -> 5003 bytes .../dslreasoner/vampire/test/.SimpleRun.xtendbin | Bin 687 -> 687 bytes .../dslreasoner/vampire/test/.VampireTest.xtendbin | Bin 6581 -> 6581 bytes .../ecse/dslreasoner/vampire/test/VampireTest.java | 2 +- .../dslreasoner/yakindu/test/.YakinduTest.xtendbin | Bin 8569 -> 8569 bytes 59 files changed, 359 insertions(+), 242 deletions(-) (limited to 'Tests/ca.mcgill.ecse.dslreasoner.standalone.test') diff --git a/Application/hu.bme.mit.inf.dslreasoner.application/xtend-gen/hu/bme/mit/inf/dslreasoner/application/validation/QueryAndMetamodelValidator.java b/Application/hu.bme.mit.inf.dslreasoner.application/xtend-gen/hu/bme/mit/inf/dslreasoner/application/validation/QueryAndMetamodelValidator.java index 3ed13964..567551f1 100644 --- a/Application/hu.bme.mit.inf.dslreasoner.application/xtend-gen/hu/bme/mit/inf/dslreasoner/application/validation/QueryAndMetamodelValidator.java +++ b/Application/hu.bme.mit.inf.dslreasoner.application/xtend-gen/hu/bme/mit/inf/dslreasoner/application/validation/QueryAndMetamodelValidator.java @@ -79,7 +79,7 @@ public class QueryAndMetamodelValidator { } } }; - return Iterables.filter(Iterables.concat(ListExtensions.>map(references, _function_1)), ENamedElement.class); + return Iterables.filter((Iterables.concat(ListExtensions.>map(references, _function_1))), ENamedElement.class); }; return Iterables.concat(ListExtensions.>map(elements, _function)); } diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml index 3874e9f7..07fd662c 100644 --- a/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml +++ b/Domains/Examples/ModelGenExampleFAM_plugin/plugin.xml @@ -1,11 +1,8 @@ - - - - + + + + diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF index 27b81f93..4c71a872 100644 --- a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/META-INF/MANIFEST.MF @@ -6,29 +6,29 @@ Bundle-Version: 1.0.0.qualifier Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: hu.bme.mit.inf.dslreasoner.logic.model.builder, - hu.bme.mit.inf.dslreasoner.logic.model.builder.consistencychecker, - hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage, - hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.impl, - hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.util, - hu.bme.mit.inf.dslreasoner.logic.model.logicproblem, - hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.impl, - hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.util, - hu.bme.mit.inf.dslreasoner.logic.model.logicresult, - hu.bme.mit.inf.dslreasoner.logic.model.logicresult.impl, - hu.bme.mit.inf.dslreasoner.logic.model.logicresult.util, - hu.bme.mit.inf.dslreasoner.logic.model.patterns, - hu.bme.mit.inf.dslreasoner.logic.model.statistics, - hu.bme.mit.inf.dslreasoner.util, - hu.bme.mit.inf.dslreasoner.workspace + hu.bme.mit.inf.dslreasoner.logic.model.builder.consistencychecker, + hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage, + hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.impl, + hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.util, + hu.bme.mit.inf.dslreasoner.logic.model.logicproblem, + hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.impl, + hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.util, + hu.bme.mit.inf.dslreasoner.logic.model.logicresult, + hu.bme.mit.inf.dslreasoner.logic.model.logicresult.impl, + hu.bme.mit.inf.dslreasoner.logic.model.logicresult.util, + hu.bme.mit.inf.dslreasoner.logic.model.patterns, + hu.bme.mit.inf.dslreasoner.logic.model.statistics, + hu.bme.mit.inf.dslreasoner.util, + hu.bme.mit.inf.dslreasoner.workspace Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - com.google.guava, - org.eclipse.xtend.lib, - org.eclipse.xtext.xbase.lib, - org.eclipse.core.resources;bundle-version="3.8.101", - org.eclipse.viatra.query.runtime;bundle-version="1.3.0", - org.apache.commons.lang;bundle-version="2.6.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.13.0" + org.eclipse.emf.ecore;visibility:=reexport, + com.google.guava, + org.eclipse.xtend.lib, + org.eclipse.xtext.xbase.lib, + org.eclipse.core.resources;bundle-version="3.8.101", + org.eclipse.viatra.query.runtime;bundle-version="1.3.0", + org.apache.commons.lang;bundle-version="2.6.0", + org.eclipse.emf.ecore.xmi;bundle-version="2.13.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Bundle-ActivationPolicy: lazy Import-Package: org.apache.log4j diff --git a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/META-INF/MANIFEST.MF b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/META-INF/MANIFEST.MF index 87ff7abc..b944302b 100644 --- a/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/META-INF/MANIFEST.MF +++ b/Solvers/Alloy-Solver/hu.bme.mit.inf.dlsreasoner.alloy.reasoner/META-INF/MANIFEST.MF @@ -4,22 +4,22 @@ Bundle-Name: %pluginName Bundle-SymbolicName: hu.bme.mit.inf.dlsreasoner.alloy.reasoner;singleton:=true Bundle-Version: 1.0.0.qualifier Bundle-ClassPath: lib/alloy4.2_2015-02-22.jar, - . + . Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: hu.bme.mit.inf.dlsreasoner.alloy.reasoner, - hu.bme.mit.inf.dlsreasoner.alloy.reasoner.builder, - hu.bme.mit.inf.dlsreasoner.alloy.reasoner.queries + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.builder, + hu.bme.mit.inf.dlsreasoner.alloy.reasoner.queries Require-Bundle: com.google.guava, - org.eclipse.xtend.lib, - org.eclipse.xtext.xbase.lib, - org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0";visibility:=reexport, - hu.bme.mit.inf.dslreasoner.alloy.language;bundle-version="1.0.0", - org.eclipse.viatra.query.runtime.base.itc;bundle-version="1.3.0", - hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", - org.eclipse.viatra.query.runtime;bundle-version="2.0.0" + org.eclipse.xtend.lib, + org.eclipse.xtext.xbase.lib, + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport, + hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0";visibility:=reexport, + hu.bme.mit.inf.dslreasoner.alloy.language;bundle-version="1.0.0", + org.eclipse.viatra.query.runtime.base.itc;bundle-version="1.3.0", + hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", + org.eclipse.viatra.query.runtime;bundle-version="2.0.0" Import-Package: org.apache.log4j;version="1.2.15" Automatic-Module-Name: hu.bme.mit.inf.dlsreasoner.alloy.reasoner Bundle-ActivationPolicy: lazy diff --git a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra/META-INF/MANIFEST.MF b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra/META-INF/MANIFEST.MF index acaf466f..23e3ad13 100644 --- a/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra/META-INF/MANIFEST.MF +++ b/Solvers/VIATRA-Solver/hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra/META-INF/MANIFEST.MF @@ -4,23 +4,23 @@ Bundle-Name: Logic2viatra Bundle-SymbolicName: hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatraquery;singleton:=true Bundle-Version: 1.0.0.qualifier Export-Package: hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra, - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns, - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.queries + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.patterns, + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatra.queries Require-Bundle: hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0", - com.google.guava, - org.eclipse.xtext.xbase.lib, - org.eclipse.xtend.lib, - org.eclipse.xtend.lib.macro, - org.eclipse.viatra.query.runtime;bundle-version="1.5.0", - org.eclipse.viatra.query.runtime.base.itc;bundle-version="1.5.0", - org.eclipse.viatra.query.patternlanguage.emf;bundle-version="1.5.0", - com.google.inject;bundle-version="3.0.0", - org.eclipse.xtext;bundle-version="2.10.0", - org.eclipse.viatra.transformation.runtime.emf;bundle-version="1.5.0", - org.eclipse.xtext.xbase;bundle-version="2.10.0" + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0", + com.google.guava, + org.eclipse.xtext.xbase.lib, + org.eclipse.xtend.lib, + org.eclipse.xtend.lib.macro, + org.eclipse.viatra.query.runtime;bundle-version="1.5.0", + org.eclipse.viatra.query.runtime.base.itc;bundle-version="1.5.0", + org.eclipse.viatra.query.patternlanguage.emf;bundle-version="1.5.0", + com.google.inject;bundle-version="3.0.0", + org.eclipse.xtext;bundle-version="2.10.0", + org.eclipse.viatra.transformation.runtime.emf;bundle-version="1.5.0", + org.eclipse.xtext.xbase;bundle-version="2.10.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Import-Package: org.apache.log4j Automatic-Module-Name: hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatraquery diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin index 313b9c2d..8e73c63a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin index 97ee1913..a5248945 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ide/xtend-gen/ca/mcgill/ecse/dslreasoner/ide/.VampireLanguageIdeSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin index 3424dc60..20e0c17a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/.VampireLanguageUiModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin index 3b0345ce..f3d2dece 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/contentassist/.VampireLanguageProposalProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin index 3a05d228..1d0354a7 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageDescriptionLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin index 418ee88d..c64b5e2f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/labeling/.VampireLanguageLabelProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin index b4a32db5..ef4b984c 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/outline/.VampireLanguageOutlineTreeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin index 89284901..38907aa5 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language.ui/xtend-gen/ca/mcgill/ecse/dslreasoner/ui/quickfix/.VampireLanguageQuickfixProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin index 633cd134..d1d2ff77 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageRuntimeModule.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin index 75f7c519..27afa8ba 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/.VampireLanguageStandaloneSetup.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin index b9ec3204..d1a3a13d 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/formatting2/.VampireLanguageFormatter.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin index 3052ed33..6d2a9063 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/generator/.VampireLanguageGenerator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin index 67b4ffcc..a9942913 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/scoping/.VampireLanguageScopeProvider.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin index 297a4f85..cd467bbd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.language/xtend-gen/ca/mcgill/ecse/dslreasoner/validation/.VampireLanguageValidator.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/META-INF/MANIFEST.MF b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/META-INF/MANIFEST.MF index 1c1d9dba..c1928ca0 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/META-INF/MANIFEST.MF +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.queries/META-INF/MANIFEST.MF @@ -5,11 +5,11 @@ Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.queries;singleton:=true Bundle-Version: 1.0.0.qualifier Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries Require-Bundle: org.eclipse.emf.ecore, - org.eclipse.viatra.query.runtime.rete, - org.eclipse.viatra.query.runtime.localsearch, - org.eclipse.xtext.xbase.lib, - ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", - org.eclipse.viatra.query.runtime;bundle-version="2.1.0" + org.eclipse.viatra.query.runtime.rete, + org.eclipse.viatra.query.runtime.localsearch, + org.eclipse.xtext.xbase.lib, + ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", + org.eclipse.viatra.query.runtime;bundle-version="2.1.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.vampire.queries diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/META-INF/MANIFEST.MF b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/META-INF/MANIFEST.MF index 6ed29084..31a52d09 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/META-INF/MANIFEST.MF +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/META-INF/MANIFEST.MF @@ -4,19 +4,19 @@ Bundle-Name: Reasoner Bundle-SymbolicName: ca.mcgill.ecse.dslreasoner.vampire.reasoner;singleton:=true Bundle-Version: 1.0.0.qualifier Export-Package: ca.mcgill.ecse.dslreasoner.vampire.reasoner, - ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder, - ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries + ca.mcgill.ecse.dslreasoner.vampire.reasoner.builder, + ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries Require-Bundle: org.eclipse.emf.ecore, - org.eclipse.viatra.query.runtime.rete, - org.eclipse.viatra.query.runtime.localsearch, - org.eclipse.xtext.xbase.lib, - org.eclipse.xtend.lib, - hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", - ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", - org.eclipse.viatra.query.runtime;bundle-version="2.1.0", - org.eclipse.viatra.query.runtime.base.itc;bundle-version="2.1.0", - org.apache.log4j;bundle-version="1.2.15" + org.eclipse.viatra.query.runtime.rete, + org.eclipse.viatra.query.runtime.localsearch, + org.eclipse.xtext.xbase.lib, + org.eclipse.xtend.lib, + hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", + ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", + org.eclipse.viatra.query.runtime;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.base.itc;bundle-version="2.1.0", + org.apache.log4j;bundle-version="1.2.15" Bundle-RequiredExecutionEnvironment: JavaSE-1.8 Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.vampire.reasoner diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSAnd.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSAnd.java index 68bebb93..553d455c 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSAnd.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSAnd.java @@ -74,8 +74,18 @@ public final class VLSAnd extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSAnd} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSAnd (visibility: PUBLIC, simpleName: VLSAnd, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSAnd, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSAnd#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSAnd INSTANCE = new VLSAnd(); + private static final VLSAnd INSTANCE = new VLSAnd(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSAnd extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSAnd extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSAnnotation} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSAnnotation (visibility: PUBLIC, simpleName: VLSAnnotation, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSAnnotation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSAnnotation#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSAnnotation INSTANCE = new VLSAnnotation(); + private static final VLSAnnotation INSTANCE = new VLSAnnotation(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSAnnotation extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSAnnotation extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSComment} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSComment (visibility: PUBLIC, simpleName: VLSComment, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSComment, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSComment#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSComment INSTANCE = new VLSComment(); + private static final VLSComment INSTANCE = new VLSComment(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSComment extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSComment extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSEquivalent} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSEquivalent (visibility: PUBLIC, simpleName: VLSEquivalent, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSEquivalent, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSEquivalent#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSEquivalent INSTANCE = new VLSEquivalent(); + private static final VLSEquivalent INSTANCE = new VLSEquivalent(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSEquivalent extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSEquivalent extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSExistentialQuantifier} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSExistentialQuantifier (visibility: PUBLIC, simpleName: VLSExistentialQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSExistentialQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSExistentialQuantifier#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSExistentialQuantifier INSTANCE = new VLSExistentialQuantifier(); + private static final VLSExistentialQuantifier INSTANCE = new VLSExistentialQuantifier(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSExistentialQuantifier extends BaseGeneratedEMFQuerySpecifi *

    The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSExistentialQuantifier extends BaseGeneratedEMFQuerySpecifi } private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSExistentialQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + private static final VLSExistentialQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSExistentialQuantifier", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSExistentialQuantifier")), PParameterDirection.INOUT); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSFofFormula.java b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSFofFormula.java index e35ffaa2..666795b5 100644 --- a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSFofFormula.java +++ b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/src-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/queries/VLSFofFormula.java @@ -74,8 +74,18 @@ public final class VLSFofFormula extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSFofFormula} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFofFormula (visibility: PUBLIC, simpleName: VLSFofFormula, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFofFormula, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSFofFormula#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSFofFormula INSTANCE = new VLSFofFormula(); + private static final VLSFofFormula INSTANCE = new VLSFofFormula(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSFofFormula extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSFofFormula extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSFunction} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFunction (visibility: PUBLIC, simpleName: VLSFunction, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFunction, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSFunction#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSFunction INSTANCE = new VLSFunction(); + private static final VLSFunction INSTANCE = new VLSFunction(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSFunction extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSFunction extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSFunctionFof} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFunctionFof (visibility: PUBLIC, simpleName: VLSFunctionFof, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSFunctionFof, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSFunctionFof#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSFunctionFof INSTANCE = new VLSFunctionFof(); + private static final VLSFunctionFof INSTANCE = new VLSFunctionFof(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -479,7 +489,7 @@ public final class VLSFunctionFof extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -488,7 +498,7 @@ public final class VLSFunctionFof extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSInequality} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSInequality (visibility: PUBLIC, simpleName: VLSInequality, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSInequality, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSInequality#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSInequality INSTANCE = new VLSInequality(); + private static final VLSInequality INSTANCE = new VLSInequality(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSInequality extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSInequality extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSOr} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSOr (visibility: PUBLIC, simpleName: VLSOr, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSOr, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSOr#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSOr INSTANCE = new VLSOr(); + private static final VLSOr INSTANCE = new VLSOr(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -480,7 +490,7 @@ public final class VLSOr extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -489,7 +499,7 @@ public final class VLSOr extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSUnaryNegation} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSUnaryNegation (visibility: PUBLIC, simpleName: VLSUnaryNegation, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSUnaryNegation, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSUnaryNegation#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSUnaryNegation INSTANCE = new VLSUnaryNegation(); + private static final VLSUnaryNegation INSTANCE = new VLSUnaryNegation(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSUnaryNegation extends BaseGeneratedEMFQuerySpecification The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSUnaryNegation extends BaseGeneratedEMFQuerySpecification) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)} to be created + * Inner class allowing the singleton instance of {@link VLSUniversalQuantifier} to be created * not at the class load time of the outer class, - * but rather at the first call to {@link JvmGenericType: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSUniversalQuantifier (visibility: PUBLIC, simpleName: VLSUniversalQuantifier, identifier: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries.VLSUniversalQuantifier, deprecated: ) (abstract: false, static: false, final: true, packageName: ca.mcgill.ecse.dslreasoner.vampire.reasoner.queries) (interface: false, strictFloatingPoint: false, anonymous: false)#instance()}. + * but rather at the first call to {@link VLSUniversalQuantifier#instance()}. * *

    This workaround is required e.g. to support recursion. * */ private static class LazyHolder { - private final static VLSUniversalQuantifier INSTANCE = new VLSUniversalQuantifier(); + private static final VLSUniversalQuantifier INSTANCE = new VLSUniversalQuantifier(); /** * Statically initializes the query specification after the field {@link #INSTANCE} is assigned. @@ -478,7 +488,7 @@ public final class VLSUniversalQuantifier extends BaseGeneratedEMFQuerySpecifica *

    The static initializer is defined using a helper field to work around limitations of the code generator. * */ - private final static Object STATIC_INITIALIZER = ensureInitialized(); + private static final Object STATIC_INITIALIZER = ensureInitialized(); public static Object ensureInitialized() { INSTANCE.ensureInitializedInternal(); @@ -487,7 +497,7 @@ public final class VLSUniversalQuantifier extends BaseGeneratedEMFQuerySpecifica } private static class GeneratedPQuery extends BaseGeneratedEMFPQuery { - private final static VLSUniversalQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); + private static final VLSUniversalQuantifier.GeneratedPQuery INSTANCE = new GeneratedPQuery(); private final PParameter parameter_term = new PParameter("term", "ca.mcgill.ecse.dslreasoner.vampireLanguage.VLSUniversalQuantifier", new EClassTransitiveInstancesKey((EClass)getClassifierLiteralSafe("http://www.mcgill.ca/ecse/dslreasoner/VampireLanguage", "VLSUniversalQuantifier")), PParameterDirection.INOUT); diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin index d21e62df..e999bce6 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireAnalyzerConfiguration.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin index 6fa1ad33..28154d14 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/.VampireSolver.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin index 16598303..18da19a9 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin index 760c5e1f..37c845cd 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapperTrace.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin index db66ddba..d8c61adc 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ConstantMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin index d6fe4078..1a86a55f 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ContainmentMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin index 81468f27..216b3a4b 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_RelationMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin index d6924639..8733e530 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_ScopeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin index 9541df30..634dab6a 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_Support.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin index bb87d246..28c93f34 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Logic2VampireLanguageMapper_TypeMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin index 61879add..faef07c1 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.Vampire2LogicMapper.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin index 1d6d6da8..3d96efbf 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireHandler.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin index 3a055e01..b3756706 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation.xtendbin differ diff --git a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin index e7c2bd91..f75b4eaf 100644 Binary files a/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin and b/Solvers/Vampire-Solver/ca.mcgill.ecse.dslreasoner.vampire.reasoner/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/reasoner/builder/.VampireModelInterpretation_TypeInterpretation_FilteredTypes.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF index bca8e840..25c8cbb9 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.standalone.test/META-INF/MANIFEST.MF @@ -7,27 +7,27 @@ Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: ca.mcgill.ecse.dslreasoner.standalone.test.ecore.queries, - ca.mcgill.ecse.dslreasoner.standalone.test.fam, - ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries, - ca.mcgill.ecse.dslreasoner.standalone.test.fam.util, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries, - ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries, - ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util + ca.mcgill.ecse.dslreasoner.standalone.test.fam, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.fam.util, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.filesystem.util, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.impl, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.queries, + ca.mcgill.ecse.dslreasoner.standalone.test.yakindu.util Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.core.runtime;bundle-version="3.13.0", - org.eclipse.emf.ecore;bundle-version="2.13.0";visibility:=reexport, - org.eclipse.viatra.query.runtime;bundle-version="2.1.0", - org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", - org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", - org.eclipse.xtext.xbase.lib;bundle-version="2.12.0", - hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph;bundle-version="1.0.0" + org.eclipse.core.runtime;bundle-version="3.13.0", + org.eclipse.emf.ecore;bundle-version="2.13.0";visibility:=reexport, + org.eclipse.viatra.query.runtime;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.rete;bundle-version="2.1.0", + org.eclipse.viatra.query.runtime.localsearch;bundle-version="2.1.0", + org.eclipse.xtext.xbase.lib;bundle-version="2.12.0", + hu.bme.mit.inf.dslreasoner.application;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph;bundle-version="1.0.0" Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.standalone.test Bundle-ActivationPolicy: lazy diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF index 6ab952ff..10da7ca1 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/META-INF/MANIFEST.MF @@ -7,45 +7,45 @@ Bundle-ClassPath: . Bundle-Vendor: %providerName Bundle-Localization: plugin Export-Package: ca.mcgill.ecse.dslreasoner.vampire.queries, - ca.mcgill.ecse.dslreasoner.vampire.yakindumm, - ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl, - ca.mcgill.ecse.dslreasoner.vampire.yakindumm.util + ca.mcgill.ecse.dslreasoner.vampire.yakindumm, + ca.mcgill.ecse.dslreasoner.vampire.yakindumm.impl, + ca.mcgill.ecse.dslreasoner.vampire.yakindumm.util Require-Bundle: org.eclipse.viatra.addon.querybasedfeatures.runtime, - org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - org.eclipse.viatra.query.runtime.rete, - org.eclipse.viatra.query.runtime.localsearch, - com.google.guava, - org.eclipse.xtext.xbase.lib, - org.eclipse.xtend.lib, - org.eclipse.xtend.lib.macro, - ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0", - ca.mcgill.ecse.dslreasoner.vampire.reasoner;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0", - org.eclipse.emf.ecore.xmi;bundle-version="2.13.0", - hu.bme.mit.inf.dlsreasoner.alloy.reasoner;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatraquery;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.logic2ecore;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.visualisation;bundle-version="1.0.0", - ModelGenExampleFAM_plugin;bundle-version="1.0.0", - ModelGenExampleFAM_plugin.validation;bundle-version="0.0.1", - hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.validation;bundle-version="0.0.1", - org.eclipse.viatra.query.runtime;bundle-version="2.1.0", - org.eclipse.collections;bundle-version="9.2.0", - hu.bme.mit.inf.dslreasoner.application.FAMTest;bundle-version="1.0.0", - ca.mcgill.ecse.dslreasoner.standalone.test;bundle-version="1.0.0", - org.apache.httpcomponents.httpcore;bundle-version="4.4.6", - org.apache.httpcomponents.httpclient;bundle-version="4.5.2", - org.apache.httpcomponents.httpclient.source;bundle-version="4.5.2", - org.apache.httpcomponents.httpclient.win;bundle-version="4.5.2", - org.apache.httpcomponents.httpcore.source;bundle-version="4.4.6", - hu.bme.mit.inf.dslreasoner.alloy.language;bundle-version="1.0.0", - hu.bme.mit.inf.dslreasoner.alloy.language.ui;bundle-version="1.0.0" + org.eclipse.core.runtime, + org.eclipse.emf.ecore;visibility:=reexport, + org.eclipse.viatra.query.runtime.rete, + org.eclipse.viatra.query.runtime.localsearch, + com.google.guava, + org.eclipse.xtext.xbase.lib, + org.eclipse.xtend.lib, + org.eclipse.xtend.lib.macro, + ca.mcgill.ecse.dslreasoner.vampire.language;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.logic.model;bundle-version="1.0.0", + ca.mcgill.ecse.dslreasoner.vampire.reasoner;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.ecore2logic;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.viatra2logic;bundle-version="1.0.0", + org.eclipse.emf.ecore.xmi;bundle-version="2.13.0", + hu.bme.mit.inf.dlsreasoner.alloy.reasoner;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.viatrasolver.partialinterpretationlanguage;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.viatrasolver.reasoner;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.viatrasolver.logic2viatraquery;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.logic2ecore;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.visualisation;bundle-version="1.0.0", + ModelGenExampleFAM_plugin;bundle-version="1.0.0", + ModelGenExampleFAM_plugin.validation;bundle-version="0.0.1", + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.domains.yakindu.sgraph.validation;bundle-version="0.0.1", + org.eclipse.viatra.query.runtime;bundle-version="2.1.0", + org.eclipse.collections;bundle-version="9.2.0", + hu.bme.mit.inf.dslreasoner.application.FAMTest;bundle-version="1.0.0", + ca.mcgill.ecse.dslreasoner.standalone.test;bundle-version="1.0.0", + org.apache.httpcomponents.httpcore;bundle-version="4.4.6", + org.apache.httpcomponents.httpclient;bundle-version="4.5.2", + org.apache.httpcomponents.httpclient.source;bundle-version="4.5.2", + org.apache.httpcomponents.httpclient.win;bundle-version="4.5.2", + org.apache.httpcomponents.httpcore.source;bundle-version="4.4.6", + hu.bme.mit.inf.dslreasoner.alloy.language;bundle-version="1.0.0", + hu.bme.mit.inf.dslreasoner.alloy.language.ui;bundle-version="1.0.0" Import-Package: org.apache.log4j Automatic-Module-Name: ca.mcgill.ecse.dslreasoner.vampire.test Bundle-ActivationPolicy: lazy diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin index 7ccbe59f..cb9eee35 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.EcoreTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin index b03f527f..22765580 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FAMTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin index 6bc303df..4870ad10 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.FileSystemTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin index a34d7d3b..424255f4 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.GeneralTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin index a8c5f173..aa2ddaf2 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/icse/.YakinduTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin index 9a2c84d7..dbe4f400 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.MedicalSystem.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin index f39505b0..4da01ec2 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.SimpleRun.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin index 51d32da7..9d323253 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/.VampireTest.xtendbin differ diff --git a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/VampireTest.java b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/VampireTest.java index 0c1b3fe9..2af5d456 100644 --- a/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/VampireTest.java +++ b/Tests/ca.mcgill.ecse.dslreasoner.vampire.test/xtend-gen/ca/mcgill/ecse/dslreasoner/vampire/test/VampireTest.java @@ -42,7 +42,7 @@ import org.eclipse.xtext.xbase.lib.Procedures.Procedure1; @SuppressWarnings("all") public class VampireTest { @Extension - private final static LogicProblemBuilder builder = new LogicProblemBuilder(); + private static final LogicProblemBuilder builder = new LogicProblemBuilder(); public static void main(final String[] args) { try { diff --git a/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin b/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin index 0278755b..d0f61cf1 100644 Binary files a/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin and b/Tests/ca.mcgill.ecse.dslreasoner.yakindu.test/xtend-gen/ca/mcgill/ecse/dslreasoner/yakindu/test/.YakinduTest.xtendbin differ -- cgit v1.2.3-54-g00ecf